2 * Copyright (C) 2017 The LineageOS Project
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
8 * http://www.apache.org/licenses/LICENSE-2.0
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.
17 #include <telephony/ril.h>
19 #ifndef SAMSUNG_AUDIO_H
20 #define SAMSUNG_AUDIO_H
26 #define SOUND_DEEP_BUFFER_DEVICE 1
27 #define SOUND_PLAYBACK_DEVICE 5
28 #define SOUND_PLAYBACK_SCO_DEVICE 3
31 #define SOUND_CAPTURE_DEVICE 0
32 #define SOUND_CAPTURE_SCO_DEVICE 3
35 #define SOUND_PLAYBACK_VOICE_DEVICE 2
36 #define SOUND_CAPTURE_VOICE_DEVICE 2
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
43 #define RIL_UNSOL_SNDMGR_WB_AMR_REPORT 0
48 #define SOUND_CAPTURE_LOOPBACK_AEC_DEVICE 1
49 #define SOUND_CAPTURE_HOTWORD_DEVICE 0
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
57 #define SWAP_SPEAKER_ON_SCREEN_ROTATION 0
60 * You can that this to 1 if your kernel supports irq affinity for
61 * fast mode. See /proc/asound/irq_affinity
63 #define SUPPORTS_IRQ_AFFINITY 0
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.
70 * A good value to start with is 10ms:
72 * #define DSP_POWEROFF_DELAY 10 * 1000
74 /* #define DSP_POWEROFF_DELAY 0 */
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.
82 /* #define AUDIENCE_EARSMART_IC */
84 #endif // SAMSUNG_AUDIO_H