1 /*
2  * da7213.h - DA7213 ASoC Codec Driver Platform Data
3  *
4  * Copyright (c) 2013 Dialog Semiconductor
5  *
6  * Author: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
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 version 2 as
10  * published by the Free Software Foundation.
11  */
12 
13 #ifndef _DA7213_PDATA_H
14 #define _DA7213_PDATA_H
15 
16 enum da7213_micbias_voltage {
17 	DA7213_MICBIAS_1_6V = 0,
18 	DA7213_MICBIAS_2_2V = 1,
19 	DA7213_MICBIAS_2_5V = 2,
20 	DA7213_MICBIAS_3_0V = 3,
21 };
22 
23 enum da7213_dmic_data_sel {
24 	DA7213_DMIC_DATA_LRISE_RFALL = 0,
25 	DA7213_DMIC_DATA_LFALL_RRISE = 1,
26 };
27 
28 enum da7213_dmic_samplephase {
29 	DA7213_DMIC_SAMPLE_ON_CLKEDGE = 0,
30 	DA7213_DMIC_SAMPLE_BETWEEN_CLKEDGE = 1,
31 };
32 
33 enum da7213_dmic_clk_rate {
34 	DA7213_DMIC_CLK_3_0MHZ = 0,
35 	DA7213_DMIC_CLK_1_5MHZ = 1,
36 };
37 
38 struct da7213_platform_data {
39 	/* Mic Bias voltage */
40 	enum da7213_micbias_voltage micbias1_lvl;
41 	enum da7213_micbias_voltage micbias2_lvl;
42 
43 	/* DMIC config */
44 	enum da7213_dmic_data_sel dmic_data_sel;
45 	enum da7213_dmic_samplephase dmic_samplephase;
46 	enum da7213_dmic_clk_rate dmic_clk_rate;
47 };
48 
49 #endif /* _DA7213_PDATA_H */
50