tea5761.h 866 B

1234567891011121314151617181920212223242526272829303132333435
  1. /* SPDX-License-Identifier: GPL-2.0-or-later */
  2. /*
  3. */
  4. #ifndef __TEA5761_H__
  5. #define __TEA5761_H__
  6. #include <linux/i2c.h>
  7. #include <media/dvb_frontend.h>
  8. #if IS_REACHABLE(CONFIG_MEDIA_TUNER_TEA5761)
  9. extern int tea5761_autodetection(struct i2c_adapter* i2c_adap, u8 i2c_addr);
  10. extern struct dvb_frontend *tea5761_attach(struct dvb_frontend *fe,
  11. struct i2c_adapter* i2c_adap,
  12. u8 i2c_addr);
  13. #else
  14. static inline int tea5761_autodetection(struct i2c_adapter* i2c_adap,
  15. u8 i2c_addr)
  16. {
  17. printk(KERN_INFO "%s: not probed - driver disabled by Kconfig\n",
  18. __func__);
  19. return -EINVAL;
  20. }
  21. static inline struct dvb_frontend *tea5761_attach(struct dvb_frontend *fe,
  22. struct i2c_adapter* i2c_adap,
  23. u8 i2c_addr)
  24. {
  25. printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
  26. return NULL;
  27. }
  28. #endif
  29. #endif /* __TEA5761_H__ */