]> Pileus Git - ~andy/linux/blobdiff - include/sound/tea575x-tuner.h
[media] snd_tea575x: Add support for tuning AM
[~andy/linux] / include / sound / tea575x-tuner.h
index 0c3c2fb0f9395be596699830a62939cc83dd1609..2a6953568554eff54cf534f45ff81b5ebf9fa44e 100644 (file)
@@ -28,6 +28,7 @@
 #include <media/v4l2-device.h>
 
 #define TEA575X_FMIF   10700
+#define TEA575X_AMIF     450
 
 #define TEA575X_DATA   (1 << 0)
 #define TEA575X_CLK    (1 << 1)
 struct snd_tea575x;
 
 struct snd_tea575x_ops {
+       /* Drivers using snd_tea575x must either define read_ and write_val */
+       void (*write_val)(struct snd_tea575x *tea, u32 val);
+       u32 (*read_val)(struct snd_tea575x *tea);
+       /* Or define the 3 pin functions */
        void (*set_pins)(struct snd_tea575x *tea, u8 pins);
        u8 (*get_pins)(struct snd_tea575x *tea);
        void (*set_direction)(struct snd_tea575x *tea, bool output);
@@ -48,11 +53,14 @@ struct snd_tea575x {
        struct video_device vd;         /* video device */
        int radio_nr;                   /* radio_nr */
        bool tea5759;                   /* 5759 chip is present */
+       bool has_am;                    /* Device can tune to AM freqs */
        bool cannot_read_data;          /* Device cannot read the data pin */
+       bool cannot_mute;               /* Device cannot mute */
        bool mute;                      /* Device is muted? */
        bool stereo;                    /* receiving stereo */
        bool tuned;                     /* tuned to a station */
        unsigned int val;               /* hw value */
+       u32 band;                       /* 0: FM, 1: FM-Japan, 2: AM */
        u32 freq;                       /* frequency */
        struct mutex mutex;
        struct snd_tea575x_ops *ops;