zl10036.h 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. /**
  2. * Driver for Zarlink ZL10036 DVB-S silicon tuner
  3. *
  4. * Copyright (C) 2006 Tino Reichardt
  5. * Copyright (C) 2007-2009 Matthias Schwarzott <zzam@gentoo.de>
  6. *
  7. * This program is free software; you can redistribute it and/or modify
  8. * it under the terms of the GNU General Public License Version 2, as
  9. * published by the Free Software Foundation.
  10. *
  11. * This program is distributed in the hope that it will be useful,
  12. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. * GNU General Public License for more details.
  15. */
  16. #ifndef DVB_ZL10036_H
  17. #define DVB_ZL10036_H
  18. #include <linux/i2c.h>
  19. #include <media/dvb_frontend.h>
  20. struct zl10036_config {
  21. u8 tuner_address;
  22. int rf_loop_enable;
  23. };
  24. #if IS_REACHABLE(CONFIG_DVB_ZL10036)
  25. /**
  26. * Attach a zl10036 tuner to the supplied frontend structure.
  27. *
  28. * @fe: Frontend to attach to.
  29. * @config: zl10036_config structure.
  30. * @i2c: pointer to struct i2c_adapter.
  31. * return: FE pointer on success, NULL on failure.
  32. */
  33. extern struct dvb_frontend *zl10036_attach(struct dvb_frontend *fe,
  34. const struct zl10036_config *config, struct i2c_adapter *i2c);
  35. #else
  36. static inline struct dvb_frontend *zl10036_attach(struct dvb_frontend *fe,
  37. const struct zl10036_config *config, struct i2c_adapter *i2c)
  38. {
  39. printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
  40. return NULL;
  41. }
  42. #endif
  43. #endif /* DVB_ZL10036_H */