Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0-or-later */
0002 /*
0003  *    Support for NXT2002 and NXT2004 - VSB/QAM
0004  *
0005  *    Copyright (C) 2005 Kirk Lapray (kirk.lapray@gmail.com)
0006  *    based on nxt2002 by Taylor Jacob <rtjacob@earthlink.net>
0007  *    and nxt2004 by Jean-Francois Thibert (jeanfrancois@sagetv.com)
0008 */
0009 
0010 #ifndef NXT200X_H
0011 #define NXT200X_H
0012 
0013 #include <linux/dvb/frontend.h>
0014 #include <linux/firmware.h>
0015 
0016 typedef enum nxt_chip_t {
0017         NXTUNDEFINED,
0018         NXT2002,
0019         NXT2004
0020 }nxt_chip_type;
0021 
0022 struct nxt200x_config
0023 {
0024     /* the demodulator's i2c address */
0025     u8 demod_address;
0026 
0027     /* need to set device param for start_dma */
0028     int (*set_ts_params)(struct dvb_frontend* fe, int is_punctured);
0029 };
0030 
0031 #if IS_REACHABLE(CONFIG_DVB_NXT200X)
0032 extern struct dvb_frontend* nxt200x_attach(const struct nxt200x_config* config,
0033                        struct i2c_adapter* i2c);
0034 #else
0035 static inline struct dvb_frontend* nxt200x_attach(const struct nxt200x_config* config,
0036                        struct i2c_adapter* i2c)
0037 {
0038     printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
0039     return NULL;
0040 }
0041 #endif // CONFIG_DVB_NXT200X
0042 
0043 #endif /* NXT200X_H */