cx24116.h 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /* SPDX-License-Identifier: GPL-2.0-or-later */
  2. /*
  3. Conexant cx24116/cx24118 - DVBS/S2 Satellite demod/tuner driver
  4. Copyright (C) 2006 Steven Toth <stoth@linuxtv.com>
  5. */
  6. #ifndef CX24116_H
  7. #define CX24116_H
  8. #include <linux/dvb/frontend.h>
  9. struct cx24116_config {
  10. /* the demodulator's i2c address */
  11. u8 demod_address;
  12. /* Need to set device param for start_dma */
  13. int (*set_ts_params)(struct dvb_frontend *fe, int is_punctured);
  14. /* Need to reset device during firmware loading */
  15. int (*reset_device)(struct dvb_frontend *fe);
  16. /* Need to set MPEG parameters */
  17. u8 mpg_clk_pos_pol:0x02;
  18. /* max bytes I2C provider can write at once */
  19. u16 i2c_wr_max;
  20. };
  21. #if IS_REACHABLE(CONFIG_DVB_CX24116)
  22. extern struct dvb_frontend *cx24116_attach(
  23. const struct cx24116_config *config,
  24. struct i2c_adapter *i2c);
  25. #else
  26. static inline struct dvb_frontend *cx24116_attach(
  27. const struct cx24116_config *config,
  28. struct i2c_adapter *i2c)
  29. {
  30. printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
  31. return NULL;
  32. }
  33. #endif
  34. #endif /* CX24116_H */