Merge tag 'v3.10.23' into develop-3.10
[firefly-linux-kernel-4.4.55.git] / sound / soc / codecs / rt5512.h
1 #ifndef __SND_SOC_CODEC_RT5512_H
2 #define __SND_SOC_CODEC_RT5512_H
3
4 #define RT5512_CODEC_NAME "rt5512-codec"
5 #define RT5512_DRV_VER     "1.0.1_G"
6
7 #define RT5512_CLK_DIV_ID 1
8 #define FOR_MID 1
9
10
11 struct rt5512_codec_chip
12 {
13         struct device *dev;
14         struct i2c_client *client;
15         struct snd_soc_jack *rt_jack;
16         enum snd_soc_control_type control_type;
17         int curr_outpath;
18         int curr_inpath;
19 };
20
21 enum {
22         OFF,
23         RCV,
24         SPK_PATH,
25         HP_PATH,
26         HP_NO_MIC,
27         BT,
28         SPK_HP,
29         RING_SPK,
30         RING_HP,
31         RING_HP_NO_MIC,
32         RING_SPK_HP,
33 };
34
35 enum {
36         MIC_OFF,
37         Main_Mic,
38         Hands_Free_Mic,
39         BT_Sco_Mic,
40 };
41
42
43 #if 1
44 #define RT_DBG(format, args...) pr_info("%s:%s() line-%d: " format, RT5512_CODEC_NAME, __FUNCTION__, __LINE__, ##args)
45 #else
46 #define RT_DBG(format, args...)
47 #endif  /* #if 1 */
48
49 #endif /* #ifndef __SND_SOC_CODEC_RT5512_H */