blob: e7f06b53ac84bb506ea36f20f5bb3db6c3e7940b [file] [log] [blame]
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -07001#ifndef __MSM_AUDIO_ACDB_H
2#define __MSM_AUDIO_ACDB_H
3
4#include <linux/msm_audio.h>
5
6#define AUDIO_SET_VOCPROC_CAL _IOW(AUDIO_IOCTL_MAGIC, \
7 (AUDIO_MAX_COMMON_IOCTL_NUM+0), unsigned)
8#define AUDIO_SET_VOCPROC_STREAM_CAL _IOW(AUDIO_IOCTL_MAGIC, \
9 (AUDIO_MAX_COMMON_IOCTL_NUM+1), unsigned)
10#define AUDIO_SET_VOCPROC_VOL_CAL _IOW(AUDIO_IOCTL_MAGIC, \
11 (AUDIO_MAX_COMMON_IOCTL_NUM+2), unsigned)
12#define AUDIO_SET_AUDPROC_RX_CAL _IOW(AUDIO_IOCTL_MAGIC, \
13 (AUDIO_MAX_COMMON_IOCTL_NUM+3), unsigned)
14#define AUDIO_SET_AUDPROC_RX_STREAM_CAL _IOW(AUDIO_IOCTL_MAGIC, \
15 (AUDIO_MAX_COMMON_IOCTL_NUM+4), unsigned)
16#define AUDIO_SET_AUDPROC_RX_VOL_CAL _IOW(AUDIO_IOCTL_MAGIC, \
17 (AUDIO_MAX_COMMON_IOCTL_NUM+5), unsigned)
18#define AUDIO_SET_AUDPROC_TX_CAL _IOW(AUDIO_IOCTL_MAGIC, \
19 (AUDIO_MAX_COMMON_IOCTL_NUM+6), unsigned)
20#define AUDIO_SET_AUDPROC_TX_STREAM_CAL _IOW(AUDIO_IOCTL_MAGIC, \
21 (AUDIO_MAX_COMMON_IOCTL_NUM+7), unsigned)
22#define AUDIO_SET_AUDPROC_TX_VOL_CAL _IOW(AUDIO_IOCTL_MAGIC, \
23 (AUDIO_MAX_COMMON_IOCTL_NUM+8), unsigned)
24#define AUDIO_SET_SIDETONE_CAL _IOW(AUDIO_IOCTL_MAGIC, \
25 (AUDIO_MAX_COMMON_IOCTL_NUM+9), unsigned)
26#define AUDIO_SET_ANC_CAL _IOW(AUDIO_IOCTL_MAGIC, \
27 (AUDIO_MAX_COMMON_IOCTL_NUM+10), unsigned)
28#define AUDIO_SET_VOICE_RX_TOPOLOGY _IOW(AUDIO_IOCTL_MAGIC, \
29 (AUDIO_MAX_COMMON_IOCTL_NUM+11), unsigned)
30#define AUDIO_SET_VOICE_TX_TOPOLOGY _IOW(AUDIO_IOCTL_MAGIC, \
31 (AUDIO_MAX_COMMON_IOCTL_NUM+12), unsigned)
Ben Rombergerc49b85d2011-07-15 18:55:34 -070032#define AUDIO_SET_ADM_RX_TOPOLOGY _IOW(AUDIO_IOCTL_MAGIC, \
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070033 (AUDIO_MAX_COMMON_IOCTL_NUM+13), unsigned)
Ben Rombergerc49b85d2011-07-15 18:55:34 -070034#define AUDIO_SET_ADM_TX_TOPOLOGY _IOW(AUDIO_IOCTL_MAGIC, \
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070035 (AUDIO_MAX_COMMON_IOCTL_NUM+14), unsigned)
Ben Rombergerc49b85d2011-07-15 18:55:34 -070036#define AUDIO_SET_ASM_TOPOLOGY _IOW(AUDIO_IOCTL_MAGIC, \
37 (AUDIO_MAX_COMMON_IOCTL_NUM+15), unsigned)
Ben Rombergerb7603232011-11-23 17:16:27 -080038#define AUDIO_SET_AFE_TX_CAL _IOW(AUDIO_IOCTL_MAGIC, \
39 (AUDIO_MAX_COMMON_IOCTL_NUM+16), unsigned)
40#define AUDIO_SET_AFE_RX_CAL _IOW(AUDIO_IOCTL_MAGIC, \
41 (AUDIO_MAX_COMMON_IOCTL_NUM+17), unsigned)
42
43
44#define AUDIO_MAX_ACDB_IOCTL (AUDIO_MAX_COMMON_IOCTL_NUM+30)
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070045
46/* ACDB structures */
47struct cal_block {
48 uint32_t cal_size; /* Size of Cal Data */
49 uint32_t cal_offset; /* offset pointer to Cal Data */
50};
51
52struct sidetone_cal {
53 uint16_t enable;
54 uint16_t gain;
55};
56
57/* For Real-Time Audio Calibration */
Ben Rombergerc49b85d2011-07-15 18:55:34 -070058#define AUDIO_GET_RTAC_ADM_INFO _IOR(AUDIO_IOCTL_MAGIC, \
Ben Rombergerb7603232011-11-23 17:16:27 -080059 (AUDIO_MAX_ACDB_IOCTL+1), unsigned)
Ben Rombergerc49b85d2011-07-15 18:55:34 -070060#define AUDIO_GET_RTAC_VOICE_INFO _IOR(AUDIO_IOCTL_MAGIC, \
Ben Rombergerb7603232011-11-23 17:16:27 -080061 (AUDIO_MAX_ACDB_IOCTL+2), unsigned)
Ben Rombergerc49b85d2011-07-15 18:55:34 -070062#define AUDIO_GET_RTAC_ADM_CAL _IOWR(AUDIO_IOCTL_MAGIC, \
Ben Rombergerb7603232011-11-23 17:16:27 -080063 (AUDIO_MAX_ACDB_IOCTL+3), unsigned)
Ben Rombergerc49b85d2011-07-15 18:55:34 -070064#define AUDIO_SET_RTAC_ADM_CAL _IOWR(AUDIO_IOCTL_MAGIC, \
Ben Rombergerb7603232011-11-23 17:16:27 -080065 (AUDIO_MAX_ACDB_IOCTL+4), unsigned)
Ben Rombergerc49b85d2011-07-15 18:55:34 -070066#define AUDIO_GET_RTAC_ASM_CAL _IOWR(AUDIO_IOCTL_MAGIC, \
Ben Rombergerb7603232011-11-23 17:16:27 -080067 (AUDIO_MAX_ACDB_IOCTL+5), unsigned)
Ben Rombergerc49b85d2011-07-15 18:55:34 -070068#define AUDIO_SET_RTAC_ASM_CAL _IOWR(AUDIO_IOCTL_MAGIC, \
Ben Rombergerb7603232011-11-23 17:16:27 -080069 (AUDIO_MAX_ACDB_IOCTL+6), unsigned)
Ben Rombergerc49b85d2011-07-15 18:55:34 -070070#define AUDIO_GET_RTAC_CVS_CAL _IOWR(AUDIO_IOCTL_MAGIC, \
Ben Rombergerb7603232011-11-23 17:16:27 -080071 (AUDIO_MAX_ACDB_IOCTL+7), unsigned)
Ben Rombergerc49b85d2011-07-15 18:55:34 -070072#define AUDIO_SET_RTAC_CVS_CAL _IOWR(AUDIO_IOCTL_MAGIC, \
Ben Rombergerb7603232011-11-23 17:16:27 -080073 (AUDIO_MAX_ACDB_IOCTL+8), unsigned)
Ben Rombergerc49b85d2011-07-15 18:55:34 -070074#define AUDIO_GET_RTAC_CVP_CAL _IOWR(AUDIO_IOCTL_MAGIC, \
Ben Rombergerb7603232011-11-23 17:16:27 -080075 (AUDIO_MAX_ACDB_IOCTL+9), unsigned)
Ben Rombergerc49b85d2011-07-15 18:55:34 -070076#define AUDIO_SET_RTAC_CVP_CAL _IOWR(AUDIO_IOCTL_MAGIC, \
Ben Rombergerb7603232011-11-23 17:16:27 -080077 (AUDIO_MAX_ACDB_IOCTL+10), unsigned)
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070078
Ben Rombergerb7603232011-11-23 17:16:27 -080079#define AUDIO_MAX_RTAC_IOCTL (AUDIO_MAX_ACDB_IOCTL+20)
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070080
81#endif /* __MSM_AUDIO_ACDB_H */