m88rs2000.h 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. /*
  2. Driver for M88RS2000 demodulator
  3. This program is free software; you can redistribute it and/or modify
  4. it under the terms of the GNU General Public License as published by
  5. the Free Software Foundation; either version 2 of the License, or
  6. (at your option) any later version.
  7. This program is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  10. GNU General Public License for more details.
  11. You should have received a copy of the GNU General Public License
  12. along with this program; if not, write to the Free Software
  13. Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  14. */
  15. #ifndef M88RS2000_H
  16. #define M88RS2000_H
  17. #include <linux/dvb/frontend.h>
  18. #include "dvb_frontend.h"
  19. struct m88rs2000_config {
  20. /* Demodulator i2c address */
  21. u8 demod_addr;
  22. u8 *inittab;
  23. /* minimum delay before retuning */
  24. int min_delay_ms;
  25. int (*set_ts_params)(struct dvb_frontend *, int);
  26. };
  27. enum {
  28. CALL_IS_SET_FRONTEND = 0x0,
  29. CALL_IS_READ,
  30. };
  31. #if defined(CONFIG_DVB_M88RS2000) || (defined(CONFIG_DVB_M88RS2000_MODULE) && \
  32. defined(MODULE))
  33. extern struct dvb_frontend *m88rs2000_attach(
  34. const struct m88rs2000_config *config, struct i2c_adapter *i2c);
  35. #else
  36. static inline struct dvb_frontend *m88rs2000_attach(
  37. const struct m88rs2000_config *config, struct i2c_adapter *i2c)
  38. {
  39. printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
  40. return NULL;
  41. }
  42. #endif /* CONFIG_DVB_M88RS2000 */
  43. enum {
  44. DEMOD_WRITE = 0x1,
  45. WRITE_DELAY = 0x10,
  46. };
  47. #endif /* M88RS2000_H */