tuner-xc2028.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. /* tuner-xc2028
  2. *
  3. * Copyright (c) 2007 Mauro Carvalho Chehab (mchehab@infradead.org)
  4. * This code is placed under the terms of the GNU General Public License v2
  5. */
  6. #ifndef __TUNER_XC2028_H__
  7. #define __TUNER_XC2028_H__
  8. #include "dvb_frontend.h"
  9. #define XC2028_DEFAULT_FIRMWARE "xc3028-v27.fw"
  10. enum xc2028_firm_type {
  11. XC2028_FIRM_NORMAL,
  12. XC2028_FIRM_MTS,
  13. };
  14. struct xc2028_ctrl {
  15. enum xc2028_firm_type type;
  16. char *fname;
  17. int max_len;
  18. };
  19. /* xc2028 commands for callback */
  20. #define XC2028_TUNER_RESET 0
  21. #define XC2028_RESET_CLK 1
  22. #if defined(CONFIG_TUNER_XC2028) || (defined(CONFIG_TUNER_XC2028_MODULE) && defined(MODULE))
  23. int xc2028_attach(struct dvb_frontend *fe, struct i2c_adapter *i2c_adap,
  24. u8 i2c_addr, struct device *dev, void *video_dev,
  25. int (*tuner_callback) (void *dev, int command, int arg));
  26. #else
  27. static inline int xc2028_attach(struct dvb_frontend *fe,
  28. struct i2c_adapter *i2c_adap,
  29. u8 i2c_addr, struct device *dev,
  30. void *video_dev,
  31. int (*tuner_callback) (void *dev, int command,
  32. int arg))
  33. {
  34. printk(KERN_INFO "%s: not probed - driver disabled by Kconfig\n",
  35. __FUNCTION__);
  36. return -EINVAL;
  37. }
  38. #endif
  39. #endif /* __TUNER_XC2028_H__ */