tea575x-tuner.h 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. #ifndef __SOUND_TEA575X_TUNER_H
  2. #define __SOUND_TEA575X_TUNER_H
  3. /*
  4. * ALSA driver for TEA5757/5759 Philips AM/FM tuner chips
  5. *
  6. * Copyright (c) 2004 Jaroslav Kysela <perex@suse.cz>
  7. *
  8. * This program is free software; you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License as published by
  10. * the Free Software Foundation; either version 2 of the License, or
  11. * (at your option) any later version.
  12. *
  13. * This program is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License
  19. * along with this program; if not, write to the Free Software
  20. * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  21. *
  22. */
  23. #include <linux/videodev.h>
  24. struct snd_tea575x;
  25. struct snd_tea575x_ops {
  26. void (*write)(struct snd_tea575x *tea, unsigned int val);
  27. unsigned int (*read)(struct snd_tea575x *tea);
  28. };
  29. struct snd_tea575x {
  30. struct snd_card *card;
  31. struct video_device vd; /* video device */
  32. struct file_operations fops;
  33. int dev_nr; /* requested device number + 1 */
  34. int vd_registered; /* video device is registered */
  35. int tea5759; /* 5759 chip is present */
  36. unsigned int freq_fixup; /* crystal onboard */
  37. unsigned int val; /* hw value */
  38. unsigned long freq; /* frequency */
  39. struct snd_tea575x_ops *ops;
  40. void *private_data;
  41. };
  42. void snd_tea575x_init(struct snd_tea575x *tea);
  43. void snd_tea575x_exit(struct snd_tea575x *tea);
  44. #endif /* __SOUND_TEA575X_TUNER_H */