blob: 7dacebcc37108d74c044e343a641deb22624637b [file] [log] [blame]
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -07001/* Copyright (c) 2011, Code Aurora Forum. All rights reserved.
2 *
3 * This program is free software; you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License version 2 and
5 * only version 2 as published by the Free Software Foundation.
6 *
7 * This program is distributed in the hope that it will be useful,
8 * but WITHOUT ANY WARRANTY; without even the implied warranty of
9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10 * GNU General Public License for more details.
11 */
12#ifndef _MSM_PCM_ROUTING_H
13#define _MSM_PCM_ROUTING_H
14#include <sound/apr_audio.h>
15
16#define LPASS_BE_PRI_I2S_RX "(Backend) PRIMARY_I2S_RX"
17#define LPASS_BE_PRI_I2S_TX "(Backend) PRIMARY_I2S_TX"
18#define LPASS_BE_SLIMBUS_0_RX "(Backend) SLIMBUS_0_RX"
19#define LPASS_BE_SLIMBUS_0_TX "(Backend) SLIMBUS_0_TX"
20#define LPASS_BE_HDMI "(Backend) HDMI"
21#define LPASS_BE_INT_BT_SCO_RX "(Backend) INT_BT_SCO_RX"
22#define LPASS_BE_INT_BT_SCO_TX "(Backend) INT_BT_SCO_TX"
23#define LPASS_BE_INT_FM_RX "(Backend) INT_FM_RX"
24#define LPASS_BE_INT_FM_TX "(Backend) INT_FM_TX"
25
26enum {
27 MSM_FRONTEND_DAI_MULTIMEDIA1 = 0,
28 MSM_FRONTEND_DAI_MULTIMEDIA2,
29 MSM_FRONTEND_DAI_CS_VOICE,
30 MSM_FRONTEND_DAI_VOIP,
31 MSM_FRONTEND_DAI_MULTIMEDIA3,
32 MSM_FRONTEND_DAI_MAX,
33};
34
35enum {
36 MSM_BACKEND_DAI_PRI_I2S_RX = 0,
37 MSM_BACKEND_DAI_PRI_I2S_TX,
38 MSM_BACKEND_DAI_SLIMBUS_0_RX,
39 MSM_BACKEND_DAI_SLIMBUS_0_TX,
40 MSM_BACKEND_DAI_HDMI_RX,
41 MSM_BACKEND_DAI_INT_BT_SCO_RX,
42 MSM_BACKEND_DAI_INT_BT_SCO_TX,
43 MSM_BACKEND_DAI_INT_FM_RX,
44 MSM_BACKEND_DAI_INT_FM_TX,
45 MSM_BACKEND_DAI_MAX,
46};
47
48struct voice_mixer_data {
49 u32 port_id;
50 unsigned long dai_sessions;
51 u32 mixer_type;
52};
53
54enum {
55 VOICE_MIXER_PRI_I2S_RX = 0,
56 VOICE_MIXER_SLIMBUS_0_RX,
57 VOICE_MIXER_PRI_I2S_TX,
58 VOICE_MIXER_SLIMBUS_0_TX,
59 VOICE_MIXER_INT_BT_SCO_RX,
60 VOICE_MIXER_INT_BT_SCO_TX,
61 VOICE_MIXER_MAX,
62};
63
64enum {
65 VOICE_PRI_I2S_RX = 0,
66 VOICE_PRI_I2S_TX,
67 VOICE_SLIMBUS_0_RX,
68 VOICE_SLIMBUS_0_TX,
69 VOICE_INT_BT_SCO_RX = 5,
70 VOICE_INT_BT_SCO_TX,
71};
72
73/* dai_id: front-end ID,
74 * dspst_id: DSP audio stream ID
75 * stream_type: playback or capture
76 */
77void msm_pcm_routing_reg_phy_stream(int fedai_id, int dspst_id,
78 int stream_type);
79void msm_pcm_routing_dereg_phy_stream(int fedai_id, int stream_type);
80
Asish Bhattacharya0ec76182011-07-29 16:58:11 +053081int lpa_set_volume(unsigned volume);
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070082#endif /*_MSM_PCM_H*/