universal7580: add hardware/samsung/nfc to lineage.dependencies
[GitHub/LineageOS/android_device_samsung_universal7580-common.git] / include / samsung_audio.h
1 /*
2 * Copyright (C) 2017 The LineageOS Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17 #include <telephony/ril.h>
18
19 #ifndef SAMSUNG_AUDIO_H
20 #define SAMSUNG_AUDIO_H
21
22 #define MIXER_CARD 0
23 #define SOUND_CARD 0
24
25 /* Playback */
26 #define SOUND_DEEP_BUFFER_DEVICE 1
27 #define SOUND_PLAYBACK_DEVICE 5
28 #define SOUND_PLAYBACK_SCO_DEVICE 3
29
30 /* Capture */
31 #define SOUND_CAPTURE_DEVICE 0
32 #define SOUND_CAPTURE_SCO_DEVICE 3
33
34 /* Voice calls */
35 #define SOUND_PLAYBACK_VOICE_DEVICE 2
36 #define SOUND_CAPTURE_VOICE_DEVICE 2
37
38 /* Wideband AMR callback */
39 #ifndef RIL_UNSOL_SNDMGR_WB_AMR_REPORT
40 #ifdef RIL_UNSOL_WB_AMR_STATE
41 #define RIL_UNSOL_SNDMGR_WB_AMR_REPORT RIL_UNSOL_WB_AMR_STATE
42 #else
43 #define RIL_UNSOL_SNDMGR_WB_AMR_REPORT 0
44 #endif
45 #endif
46
47 /* Unusupported
48 #define SOUND_CAPTURE_LOOPBACK_AEC_DEVICE 1
49 #define SOUND_CAPTURE_HOTWORD_DEVICE 0
50 */
51
52 /*
53 * If the device has stereo speakers and the speakers are arranged on
54 * different sides of the device you can activate this feature by
55 * setting it to 1.
56 */
57 #define SWAP_SPEAKER_ON_SCREEN_ROTATION 0
58
59 /*
60 * You can that this to 1 if your kernel supports irq affinity for
61 * fast mode. See /proc/asound/irq_affinity
62 */
63 #define SUPPORTS_IRQ_AFFINITY 0
64
65 /*
66 * The Wolfson/Cirruslogic chips need to shutdown the DAPM route completely
67 * to be able to load a new firmware. Some of these chips need a delay after
68 * shutodown to full poweroff the DSPs.
69 *
70 * A good value to start with is 10ms:
71 *
72 * #define DSP_POWEROFF_DELAY 10 * 1000
73 */
74 /* #define DSP_POWEROFF_DELAY 0 */
75
76 /*
77 * Some device variants (often T-Mobile) have a separate voice processing IC
78 * (Audience EarSmart xxx).
79 * This hooks into the voice call session and enables, configures and disables
80 * this extra firmware so RX/TX streams can be routed by the driver.
81 */
82 /* #define AUDIENCE_EARSMART_IC */
83
84 #endif // SAMSUNG_AUDIO_H