Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0-or-later */
0002 /*
0003  *  Driver for Zarlink DVB-T ZL10353 demodulator
0004  *
0005  *  Copyright (C) 2006, 2007 Christopher Pascoe <c.pascoe@itee.uq.edu.au>
0006  */
0007 
0008 #ifndef ZL10353_H
0009 #define ZL10353_H
0010 
0011 #include <linux/dvb/frontend.h>
0012 
0013 struct zl10353_config
0014 {
0015     /* demodulator's I2C address */
0016     u8 demod_address;
0017 
0018     /* frequencies in units of 0.1kHz */
0019     int adc_clock;  /* default: 450560 (45.056  MHz) */
0020     int if2;    /* default: 361667 (36.1667 MHz) */
0021 
0022     /* set if no pll is connected to the secondary i2c bus */
0023     int no_tuner;
0024 
0025     /* set if parallel ts output is required */
0026     int parallel_ts;
0027 
0028     /* set if i2c_gate_ctrl disable is required */
0029     u8 disable_i2c_gate_ctrl:1;
0030 
0031     /* clock control registers (0x51-0x54) */
0032     u8 clock_ctl_1;  /* default: 0x46 */
0033     u8 pll_0;        /* default: 0x15 */
0034 };
0035 
0036 #if IS_REACHABLE(CONFIG_DVB_ZL10353)
0037 extern struct dvb_frontend* zl10353_attach(const struct zl10353_config *config,
0038                        struct i2c_adapter *i2c);
0039 #else
0040 static inline struct dvb_frontend* zl10353_attach(const struct zl10353_config *config,
0041                        struct i2c_adapter *i2c)
0042 {
0043     printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
0044     return NULL;
0045 }
0046 #endif /* CONFIG_DVB_ZL10353 */
0047 
0048 #endif /* ZL10353_H */