ds3000.h 991 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. /* SPDX-License-Identifier: GPL-2.0-or-later */
  2. /*
  3. Montage Technology DS3000 - DVBS/S2 Demodulator driver
  4. Copyright (C) 2009-2012 Konstantin Dimitrov <kosio.dimitrov@gmail.com>
  5. Copyright (C) 2009-2012 TurboSight.com
  6. */
  7. #ifndef DS3000_H
  8. #define DS3000_H
  9. #include <linux/dvb/frontend.h>
  10. struct ds3000_config {
  11. /* the demodulator's i2c address */
  12. u8 demod_address;
  13. u8 ci_mode;
  14. /* Set device param to start dma */
  15. int (*set_ts_params)(struct dvb_frontend *fe, int is_punctured);
  16. /* Hook for Lock LED */
  17. void (*set_lock_led)(struct dvb_frontend *fe, int offon);
  18. };
  19. #if IS_REACHABLE(CONFIG_DVB_DS3000)
  20. extern struct dvb_frontend *ds3000_attach(const struct ds3000_config *config,
  21. struct i2c_adapter *i2c);
  22. #else
  23. static inline
  24. struct dvb_frontend *ds3000_attach(const struct ds3000_config *config,
  25. struct i2c_adapter *i2c)
  26. {
  27. printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
  28. return NULL;
  29. }
  30. #endif /* CONFIG_DVB_DS3000 */
  31. #endif /* DS3000_H */