AUX PCM interface is a bi-direction interface which RX and TX paths
share the clock and sync word. In current design, it is assumed
when TX path is activated, RX path was enabled beforehand. So the
AUX PCM clock and GPIO pin configuration is only tied to AUX PCM RX
path. There is use case that only AUX PCM TX path is activated by
application so the AUX PCM clock and GPIOs are never configured
in this case which causes recording from AUX PCM TX failed to
capture any audio sample.
The solution is to update the clock and GPIO pin configuration to
both RX and TX path and then use an atomic reference counter to
prevent them configured twice.
CRs-Fixed: 397095
Signed-off-by: Kuirong Wang <kuirongw@codeaurora.org>
(cherry picked from commit ae395b024194bf6ae633a67dd1c2a5b3c7f1e019)
Conflicts:
sound/soc/msm/msm8974.c
Change-Id: If7f044de3cc4819e61fe66cd865755dceb5c45eb
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
(cherry picked from commit eba5065dc6a84da68e5d9bcf6cb1934324698fec)
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
The minimum channel number supported by HDMI is 2.
Set the channel to STEREO if the channel is MONO in
fixup function.
CRs-fixed: 384324
Signed-off-by: Helen Zeng <xiaoyunz@codeaurora.org>
(cherry picked from commit 12123a1c21b2e9beb469e66cc66d7b5cdd13eb2a)
(cherry picked from commit cc72e236484f1fee01ecd9a6bdf06d7bc690dc9b)
Change-Id: I153e1e0fc73523b3a1e229bd6c8eff2b8ac6e8c1
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
QDSP6 can send out of sequence response and this breaks
the no wait command tracking logic. It results the wait
command response gets ignored and causes the wait time out.
To resolve the issue, each response needs to be checked
to determine if the response is for no wait or wait command.
CRs-Fixed: 402768
Signed-off-by: Jay Wang <jaywang@codeaurora.org>
(cherry picked from commit 186115970e3a1eb38a183fccce4668500f0a7edf)
(cherry picked from commit 605a4c7f220a135709dbb933a760c356cf082bc8)
Change-Id: Ia364fcbb4f093ba683a29f8f209e9318519c4f6c
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
CODEC has over current protection(OCP) finite state
machine for both left and right headphone while CODEC
driver tries to delay reporting of OCP event after
CODEC reporting OCP two times. Current CODEC driver
implementation results in unlocking one of headphone
power amplifier when OCP reported on both headphone.
Change the behavior to report OCP event for a give
headphone immediately if OCP already occurs on opposite
headphone.
CRs-fixed: 339620
Signed-off-by: Patrick Lai <plai@codeaurora.org>
(cherry picked from commit c2d833d524c1230c72f2d078b543baba7a8db26f)
(cherry picked from commit 6b8cacf2d5ed669048c3813b56851c10fe5c5af1)
Change-Id: Iea28c8baa1a6372dcb4c0214ec0e74bfc483f563
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
Fix memory leak by releasing the dynamically allocated memory for
DAPM widget list in case of playback.
CRs-fixed: 386917
Signed-off-by: Banajit Goswami <bgoswa@codeaurora.org>
(cherry picked from commit c2b059968770de6e0fd0e37bc7877b05e7e23368)
(cherry picked from commit af7a0215387c8a92dd51ebbd824f7e2444a84c77)
Change-Id: I57e9b5a4ffe0a2ba82280ab00d03b514fa8617be
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
- GPIOs 23, 35 are used for headset mic on msm8960
- Do not configure GPIOs 23, 35 on msm8960AB target
for headset mic, as these GIPOs are used for FAN
external VDD_CX regulator control
Signed-off-by: Jayasena Sangaraboina <jsanga@codeaurora.org>
(cherry picked from commit 21c9f483e14dbb5b54ac5bf63f7d8711a157ebcb)
(cherry picked from commit 404e6428e061d11581eb949ae13e53646e925294)
Change-Id: I652f0ee07365fddd31e157b68893bcb749dbc1d7
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
While playback and capture is done concurrently the dapm widget
data is accessed parallelly which results in data corruption and
kernel panic. Fix this problem by serializing the stream event
operation by adding lock
dapm_seq_run will invoke dapm power sequence for pre-sorted list
of widgets to be powered up. Kernel panic issue is observed
during stability runs with the above sequence caused by null
pointer dereference in dapm_seq_run_coalesced. Fix kernel panic
issue by checking for valid snd_soc_dapm_context pointer in
dapm_seq_run before invoking dapm_seq_run_coalesced
Widget list in dapm is getting corrupted during concurrent
use cases where dapm_power_widget is accessed. This corruption
is resulting in kernel crash in dapm. Fix the issue by adding
protection in dapm_power_widgets API.
CRs-Fixed: 388785
Signed-off-by: Sriranjan Srikantam <cssrika@codeaurora.org>
(cherry picked from commit fd7f1ad52d7f848073c90c6a79c1d9fce1ff4ee5)
(cherry picked from commit 343e95447979b2b5592b9523c4abc8422f149487)
Change-Id: I1c91d4a55d0918e36315b9afce367e2f453ea9a7
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
- After sub system restart ACDB cannot push data to Q6
- Memory map is not happening after sub system restart, because
the calibration block address is same as the cached address.
Without memory map calibration block is sent to DSP, where it is
failing with memory map error.
- Reset the calibration block after sub system restart, so that
memory map happens after sub system restart.
CRs-Fixed: 389214
Signed-off-by: Deepa Madiregama <dmadireg@codeaurora.org>
(cherry picked from commit b71818e0ee674b2357d419c6559b5aa009d96a14)
(cherry picked from commit 9bf11c66fb6ec7c39b7cef010b7db99a79ebb6a4)
Change-Id: I9ac78f92afae6711b6eb9604c54db6303199a910
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
This machine driver implements the topology which voice
downlink/uplink streams from/to MDM are received via primary
spkr/mic I2S interfaces and internally loop back within LPASS
to MI2S interface with the other end connected to wcd9310
CODEC.
Signed-off-by: Kuirong Wang <kuirongw@codeaurora.org>
(cherry picked from commit 80f8ec49294e9698751a5afd8c33fb327f8f5b6a)
(cherry picked from commit bf8f93bc69fb3e6a7333525249984212271ca3ad)
Change-Id: I2d9140c49d14f172ae402d738ab3b6b523250486
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
Turn on EAR DAC and EAR PA at the same time to avoid pop
at start of playback.
CRs-Fixed: 386288
Signed-off-by: Damir Didjusto <damird@codeaurora.org>
(cherry picked from commit 7c85d71830e1781c113cf1d69234169e8feb31c9)
(cherry picked from commit deb584f6a8788dcda97a9d83038103ebd2576771)
Change-Id: Ib50f6a488fe93595423bae30164073cc25b90076
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
Change the reset timeout form 100 jiffies to 1 jiffy which
is used for the PLL lock timeout for cs8427 chip
CRs-Fixed: 361937
Signed-off-by: Sharad Sangle <assangle@codeaurora.org>
(cherry picked from commit 1cbe87dd6ef07013dff2e58d6d75adc1d440fe24)
(cherry picked from commit fa5ec08bb0b19b3065b6b5c2db7bc8a13b7e01a2)
Change-Id: I95049ddae148ba951b06ae4fd96f4875d929ced1
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
Support 6 channels configuration in HDMI driver
and the ALSA framework to play 5.1 LPCM format
CRs-Fixed: 370096
Signed-off-by: Aviral Gupta <aviralg@codeaurora.org>
(cherry picked from commit fc3b780b571b62f302fe38c9faaa58508ad5464f)
(cherry picked from commit 7fd4b7af623ac3dfef0b23d4e68758b1a65941d6)
Change-Id: I091cd3187e9c68eb2589c9b3412b1d8a7bb59164
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
There can be a use case where HAL may request for
Smaller period size and corresponding buffer size for
A session, update compressed driver default period size
And buffer size based on the userspace configuration
Signed-off-by: Aviral Gupta <aviralg@codeaurora.org>
(cherry picked from commit d4e62aeb8839cf9accf2356568a14adb8d24152f)
(cherry picked from commit 462a09e10e32afb49ca50bdbfb8c4a4e13cc068a)
Change-Id: Id1aef6c71c5c71b269b6607816f7c3e5c4fd4314
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
When the Application pointer is same as hardware pointer, the dequeing
from DSP chain will be broken to start the session again there should
be trigger called explicitly from the user space, to avoid resending
the trigger command from the user space.
Signed-off-by: Santosh Mardi <gsantosh@codeaurora.org>
(cherry picked from commit 5bb19ee2b22ca42e708da052517853496fc5b98d)
(cherry picked from commit d5d591f945b25b82a7177a6b466387fbc9b1bf93)
Change-Id: I42bb47de76e3f9368188161b5a1a71734fec3b6e
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
Add Async write mechanism for multichannel PCM platform driver.
This will facilitate to have meta data information flow from apps
To DSP and vice versa.
Signed-off-by: Santosh Mardi <gsantosh@codeaurora.org>
(cherry picked from commit 69f2b8ac7106fe5d5fa19ee12131c27efc8e5ec1)
(cherry picked from commit 45e605da5fd57e07609657c0fac43853d3d0658e)
Change-Id: I6a931b4458f14b64040eb7502aee26250938ba9d
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
When 100KHz level shifter is enabled this is causing an i2c
Failures for the tuner chips sitting on the same bus, to avoid this
Errors the spdif 100KHz level shifter should be disabled when
The i2c read / write of cs8427 chip is not in use.
How 100KHz disabled is, as and when the driver tries to do I2C
Write / Read Level shifter is enabled and disabled after i2c
Read / Write is done, This is done for every read / write i2c
Transfers on cs8427 chip, though it adds and over head of enabling
And disabling level shifter every time, this is the only better way
To address this.
CRs-Fixed: 390239
Signed-off-by: Santosh Mardi <gsantosh@codeaurora.org>
(cherry picked from commit 3896ed363d0958bde89de2f31709616eb96cb489)
(cherry picked from commit a6fa21f13dac271fc6b9ba971f9746b5fe0d7093)
Change-Id: If0c953771295aac9ddfc2b72389ed30e94fedb9b
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
Setting the LPCM as default format for the compressed driver.
It is needed for the HDMI IN compressed use case, where we are
not aware of the format beforehand
Signed-off-by: Aviral Gupta <aviralg@codeaurora.org>
(Cherry picked from commit 7e259d841857f06951c41c1159e95bb4b343602f)
Conflicts:
sound/soc/msm/msm-compr-q6.c
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
(cherry picked from commit 390ef43a8103c52273614e09ed1e5e8ceab97f04)
Change-Id: I2d380e97e3225e1b6cb3250d10ca016f8fcc4b1e
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
Current GPIO debounce time is too long so it delays next button
press detection. Reduce this debounce time so driver can detect
next button press and release quickly.
Typically mic voltage ramps up within few milliseconds after button
release so 50ms is long enough.
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
(cherry picked from commit db606b0a39452c90e26692c22300c390f5822f29)
(cherry picked from commit 96e92e0a22a0c54f9cfda447d346c1a2dd9f4639)
Change-Id: Ibf0aa4d4c07fab9cd50021cb0e256ee23b320059
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
After the inserted accessory is detected as a valid headphone,
polling is performed on the microphone to correct the accessory
detection in case it was wrongly identified as a headphone.
It was observed that at the end of polling, headphone removal
interrupt was fired, causing headphone playback to stop. Fixed
by deferring the headphone removal setup until either polling is
complete or polling detects a removal
CRs-fixed: 384967
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
(cherry picked from commit afc86431f330ee51f7980b620bef75935422c764)
(cherry picked from commit f87a8b2658964249917c815719d15abedd03771e)
Change-Id: Ic2c04aa300fc029957c71294e153aef479967b84
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
Upadate the multichannel driver period size to accomodate the
8 channels with 1536 bytes for each channel in HDMI IN use case.
Update the channels of wma according to the structure populated
by the HAL
Signed-off-by: Aviral Gupta <aviralg@codeaurora.org>
(cherry picked from commit 572d504a7a57d521bd5a823a3bb8a443ac34842a)
(cherry picked from commit a955dd94918bc4241d28053d8f6587b1c055238a)
Change-Id: Id043cbf07ff1b8a80ac0961ddeff0c1d3ff1283b
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
While playing a file via tunnel mode, the timestamp was not getting
updated in the seekbar.
Provide a fix for this by parsing the lsw and msw timestamp
correctly before being sent to userspace.
Signed-off-by: Harmandeep Singh <hsingh@codeaurora.org>
(cherry picked from commit 3377a88c4b4e7b71abd09e2bf66c1844743c329f)
(cherry picked from commit 0c5d9b68488f318538caa7ada53ed6fbb1a2309f)
Change-Id: I0f94e07e43f922ceeb59a83c9628fa47cd17ef4e
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
Add the fixup function for the SEC I2S backend to
configure the number of channels to 2 and
sample rate to 48000Khz.
CRs-Fixed: 395160
Signed-off-by: Aviral Gupta <aviralg@codeaurora.org>
(cherry picked from commit 695c30beb5b12f7f4b1169e6c65a1c67bef03c19)
(cherry picked from commit cb3b26e043e1e32a543d799e1ba37a0e882f1aa6)
Change-Id: I670881282655e20059ed7fa039f575b6411366bc
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
All msm_ion clients need to use <linux/msm_ion.h> instead of
<linux/ion.h>
Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
(cherry picked from commit 71a6ac9d4fc5e88efd57c2077caaff34afa36603)
(cherry picked from commit 353fac8a22a0253e990c745232d45586adb0defb)
Change-Id: I26165047d3361802ff3957b54a645544a8e9c3b5
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
- Add the support to report lineout device when inserted plug
has high impedance on microphone line.
- This feature is enabled only with gpio headset detection.
Signed-off-by: Ravi Kumar Alamanda <ralama@codeaurora.org>
(cherry picked from commit 07b6bd6a9a1e431a86efa76b14030d882ee7771b)
(cherry picked from commit 39c0e134f67fcab824f1457a256c4fbf2525c347)
Change-Id: I6d4e3f147433ee9c0cc313118b540fee0b90f45f
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
Compressed data in HDMI IN or VCAP usecase is propagated with
timestamp from DSP with each buffer. For playback, the same or
interpolated timestamp is updated with the corresponding buffer.
DSP will render the buffer a) without any delay if timestamp mode is
synchronous to absolute timestamp b) with a delay if timestamp is more
than the absolute timestamp c) drop the buffer if the timestamp is
less than the absolute timestamp. Add support for the same.
Signed-off-by: Subhash Chandra Bose Naripeddy <snariped@codeaurora.org>
(cherry picked from commit aa1f5e51dbc251dc758a1f762802d87d4f2128b7)
(cherry picked from commit cb209b8f0bddcedaf26a181f20de696e4ad729bc)
Change-Id: I5b7b2cb405f72ea9afa4751c6a92cde09f40d69c
Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
With shared data channel architecture, SLIMBUS driver
only removes slimbus channel when all clients vote to
have channel removed. In case of subsystem restart,
client such as MDM can go down without withdrawing
vote. During CODEC path shutdown, CODEC driver will
receive slimbus slave interrupt in time indicating
port disconnection because slimbus channel has not
be been voted off. Then, CODEC driver blindly
shutdown rest of CODEC path. This results in
overflow error on Rx path and underflow error on
Tx path. In case of time out waiting for port disconnect
interrupts to arrive, force ports to disconnect
Signed-off-by: SathishKumar Mani <smani@codeaurora.org>
BUG-ID: 7313016
The shared channel number can be overwritten by front-end
DAI's channel setting. Add fixup function to set the correct
channel number based on recording mode in the machine driver.
Signed-off-by: SathishKumar Mani <smani@codeaurora.org>
BUG-ID: 7313016
- Kernel messages are getting flooded with warning
messages when no valid routing found from source
to sink
- Ratelimit the warning messages
Signed-off-by: SathishKumar Mani <smani@codeaurora.org>
- Current implementation supports only fixed buffer size
of 320 bytes only for audio recording. This results in
performance overhead for recording at higher sample rate.
- Added support for flexible period size so that user can
use larger buffers for recording at higher sample rates.
Signed-off-by: SathishKumar Mani<smani@codeaurora.org>
Signed-off-by: Iliyan Malchev <malchev@google.com>
With the recent change in tabla shutdown, turning off the clocks
were being taken care after all the slimbus ports are closed.
But, there are instants where tabla startup is being called
during bootup, which keeps the runtime PM votes running,
and as there are no ports open, clocks are on all the time,
due to one of the votes. Bringing back tabla shutdown, but
turn off the clocks only if there are no slimbus ports
open at the time of shutdown, else it will taken care when
the slimbus ports are getting closed
Change-Id: Iaa9378b171d7c169a0f3306d55698e18d28dd111
CRs-fixed: 390003
Signed-off-by: Swaminathan Sathappan <Swami@codeaurora.org>
Signed-off-by: Ajay Dudani <adudani@codeaurora.org>
- Increase default buffersize to 4k from 2k for audio playback
when HAL is configured with deep buffer output.
bug-id: 7129131
Signed-off-by: SathishKumar Mani <smani@codeaurora.org>
- Small buffersize is resulting in scheduling issues.
- Increase max buffer size so that user space can
configure large buffer size to avoid scheduling
issues.
bug-id: 6865729
Signed-off-by: SathishKumar Mani <smani@codeaurora.org>
- Speaker warm-up time is too long(over 100 ms) due to big delay
(16*2ms for mono and 16*4ms for stereo)after lineout PA enabled.
- Measured by "adb shell dumpsys media.audio_flinger |grep measuredWarmup",
speaker warm-up time is reduced to ~70-80ms
Signed-off-by: SathishKumar Mani <smani@codeaurora.org>
bug-id: 7022794
Update platform driver open function call to access
audio_client pointer only after allocation to avoid crash.
Signed-off-by: SathishKumar Mani <smani@codeaurora.org>
ALSA framework in kernel 3.4 requires all CPU DAIs to be routed to
the repective back-end input or output. Add the routing for STUB_1,
SLIMBUS_1, SLIMBUS_3, and SLIMBUS_4 CPU DAIs.
It is from QCT
Change-Id: Ia7b76ce04b4e19f2f0e9acf9886361e3d113cef6
- Add lowlatency pcm driver for Playback and Recording.
- Add support in target board files
- Add Recording Path to Multimedia5 FE DAI
- Add support in routing, platform, machine drivers
- Add low latency interfaces support in ASM and ADM drivers.
Change-Id: I1beb11db9010534e5aa91179ac6040a41622185d
Signed-off-by: Jayasena Sangaraboina <jsanga@codeaurora.org>
The source of input signal(ADC or DMIC) needs to configured correctly
in CDC_TXn_MUX_CTL registers for correct operation of Decimators.
Currently for DMIC's, this configuration is done in DMIC DAPM widget
power up/down call back creating dependency between DMIC number and
Decimator number (with current code, DMIC1 can send signal to only
DEC1, DMIC2 can send signal to only DEC2). Remove this dependency by
setting type of input signal when Decimator MUX input is set.
CRs-Fixed: 384279
Change-Id: Ic084bb892d663dea51ca5a5a95c6bdba30453744
Signed-off-by: Asish Bhattacharya <asishb@codeaurora.org>
The token field is for identification to determine response packet's
source. Fill this field correctly to address afe_loopback timeout.
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
If the vote for pm runtime is done while codec shutdown, it is possible
that the runtime pm vote occurs even before the slimbus port for tx/rx
audio channel is disconnected. This can cause problem in audio playback/
record. Fix by moving the vote for runtime pm after slimbus port has
been disconnected
Change-Id: I711bc5cfee5b832575ea0b91cf68e826f1a3c0f5
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
Headphone path can either be in CLASS G mode or CLASS AB mode.
The class G mode in the codec hardware is used to adjust the
supply voltage of the PA's according to the signal level. This
makes the system as efficient as possible. Fix the register
sequence to enable headphone in class G mode
CRs-fixed: 380598
Change-Id: I110c4e0ea958ef55c0b407c566deb7da58f4d99a
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
Upgrade the board file to change the microphone bias used by MBHC to
2.7 Volts. The button voltage ranges need to be updated accordingly
Change-Id: Ia2f91271864e0f8fe25b866bff8006af0dd6f20b
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
The debugfs TRRS entry is for overriding headset button polling.
Fix regression not to start button polling when this flag is set.
CRs-fixed: 386038
Change-Id: I469c366bc111f37ecbb46708d2800200dd3d7584
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
Some of accessories on the headset jack takes longer to settle down
voltage. Make adjust time to be configurable so those accessories can
be detected correctly.
Change-Id: I3c2f68c8a4bb1a8f94669bd910728f014ee39874
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
Read the codec specific data from device tree instead of board file.
Change-Id: Iad382b89692903d2434b63d34c7121fe0b4b9dda
Signed-off-by: Kiran Kandi <kkandi@codeaurora.org>
Resetting this channel actual flag without
checking whether the set of channels are already in
use, could cause failures in disconnecting those
set of ports associated with that channels.
Change-Id: If0b917023c8f6d11d6b5cd92708715e10a1408ab
CRs-fixed: 384055
Signed-off-by: Swaminathan Sathappan <Swami@codeaurora.org>
Update the number of supported voice networks
in the ACDB driver and change the voice driver
to support concurrent calibration for VOLTE,
VOIP & voice.
Change-Id: I945fa40cbb4ac079a79fa0cb829971f1aa9d07f6
Signed-off-by: Ben Romberger <bromberg@codeaurora.org>
When SRS Tru media topology is enabled the mixer controls set from
userspace are not sent to driver as the validation fails with
the missing field initialization in the structure. Update the same
to receive the SRS parameters from userspace
Change-Id: Ia2bf800a540adf3bcc2a99fc6e0d9b043c826272
Signed-off-by: Subhash Chandra Bose Naripeddy <snariped@codeaurora.org>
This change sets rate on pcm0 root clock (pcm0_src_clk)
and pcm out enable (PCM_OE) clock for AUX PCM CPU DAI.
Once the rate is set on the source clocks, corresponding
branch clocks get enabled.
Change-Id: I59bc339d69fe836f613c1bebf7561184dced2dcf
Signed-off-by: Phani Kumar Uppalapati <phanik@codeaurora.org>
After recent movement of afe_start to prepare the interrupts start
coming earlier from proxy port.
This results in proxy port driver not ready for interrupts. Start the
timer later to ensure processing of packet once trigger start happens.
Change-Id: Ie82d982b6c147afdef46a8c7bfe7234dd14486f1
Signed-off-by: Asish Bhattacharya <asishb@codeaurora.org>
If interrupt handler is not quicker than voltage ramp up by button
release, driver requested measurement won't see stable voltage.
Enhance button press detection performance by comparing voltage
measurements from codec hardware only.
CRs-fixed: 376825
Change-Id: I294239df02fb5afeb3527dda85924c06ab15e54c
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
Enhance button release detection performance by adopting dynamic release
threshold adjusting logic.
Button release is now detected more quickly.
Change-Id: I3a2379e10663cf91df671e8a3894b8805d1ccf9c
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
copy_to_user and copy_from_user can block(go to sleep). These two functions
should be removed from spinlock protection.
Change-Id: I0c10796ece4ac218600ef3b214c88a06004a0a0d
CRs-fixed: 381839
Signed-off-by: Helen Zeng <xiaoyunz@codeaurora.org>
If Mic Bias is high Z by default and when the LDOH is enabled,
the Mic Bias output can pull-up to a non-zero voltage if there
is no loading or if the load leakage is very small. Pulling
down the Mic Bias output so it is not in high Z to eliminate
the floating voltage.
Change-Id: I38e76a8c03107879727564f177b2713c9dfa4631
CRs-Fixed: 368898
Signed-off-by: Kuirong Wang <kuirongw@codeaurora.org>
The value for the amix command with the numeric strings is
the actual value not the order of the string in the array
of text so the put function has to be updated to handle it.
For example, the following amix comand:
amix 'Internal BTSCO SampleRatee' 16000'
The value passed from the alsa-lib is not 2, i.e., the 2nd
paramater in the command string:
static const char *btsco_rate_text[] = {"8000", "16000"};
Instead, it is 16000.
CRs-fixed: 364832
Change-Id: Ie7c83a460900b54e2b317e1c77a064efc22e6bcd
Signed-off-by: Kuirong Wang <kuirongw@codeaurora.org>
-Voice call recording is not working because of missing
backends configuration for incall record Tx/Rx.
Change-Id: Ie69112e2929ed98a5bc19164cf9a9c66d73cc8dc
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Update DAI link to connect slimbus RX/TX port 0 to CPU.
Change-Id: Id8aa2ca92ea9b1e0d51b6d3ccf113860a9147c44
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
Add audio OCMEM driver support to exercise On-Chip
Memory (OCMEM) for low power audio and voice. The
driver is implemented as standalone and it gets
exercised based on the usecase. Also, this design
reduces the latency associated with OCMEM handshaking
protocol. The audio OCMEM driver is enabled by default
with a Kconfig option using select. Add device tree node
for audio OCMEM to retrieve platform data.
Change-Id: Iba46ce675fc03843d88cd7cf2aa9bc92fe70a955
Signed-off-by: Phani Kumar Uppalapati <phanik@codeaurora.org>
Register slimbus CPU dai link to support slimbus data path.
Change-Id: I3584306ac1e0ad6561a19cecfe71f2a63aadafa9
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
During rapid open and close of slimbus ports, it may happen that when
port open is performed, the port is not disconnected from the previous
open. This will cause inconsistent state and may result in failure to
playback audio. Fix by waiting for the slimbus port disconnect to happen
before opening the port.
CRs-fixed: 375689
Change-Id: Id1303deae296eb6842074837183ab231aa2b4dad
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
In AFE-PCM RX and TX dai links of MPQ8064 machine driver there
was a conflict in codec dai name and codec name, with this ALSA
Framework is not creating the node in /dev/snd/
CRs-Fixed: 377509
Change-Id: I5337b216a3d0a2cdc36292ccdafe3e144e7f1d41
Signed-off-by: Santosh Mardi <gsantosh@codeaurora.org>
The wcd9310 codec driver already can detect and report unsupported headset
plugging. Create headset jack with unsupported headset mask to be able to
report via sound core.
Change-Id: I0119d01c039362cc7b185f9f3407d78c958bc49a
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
HDMI 1.3 supports Multi channel PCM up to 8 channels with sample
size of 16/20/24 bits and sample rate of 32, 44.1, 48, 96, 176.4,
192K. This patch add supports for 6 channel PCM at 48K sample rate
with sample size of 16 bits.
CRs-Fixed: 380370
Change-Id: I01cb7eb509a0d21072e2e8dcc63624384a1edb0d
Signed-off-by: Asish Bhattacharya <asishb@codeaurora.org>
Found that the register sequence for enabling recording on analog
microphone was updating a wrong register. Fix by correcting the
register sequence
CRs-fixed: 378189
Change-Id: I3598cbc77b279684b28677943ac13f446bc2f78e
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
When closing the slimbus ports, clear only the slimbus
ports which were active at the time of closing on that
slimbus interrupt, which will avoid clearing further
interrupts for other slimbus ports
Change-Id: I43ce9963c0ecb4b8fb79527b8a9c6b13d7780aad
CRs-fixed: 380535
Signed-off-by: Swaminathan Sathappan <Swami@codeaurora.org>
- Add a front end DAI link for compressed audio driver.
- Add device tree specific changes to sound soc compressed
drivers which will help the detection of sound card.
Change-Id: I4a8076df8c82cd4e444fc0d68e8f7a228bd1dc02
Signed-off-by: Harmandeep Singh <hsingh@codeaurora.org>
Some physical pools ids may become unsupported in future targets.
Remove target specific information from API to make it robust against
such architectural changes.
Also different platforms such as MDM, MSM might support some physical
pools but not the other, so choosing a generic name which will could be
mapped internally to different memory pools
Change-Id: I4f003662d9a2a28c17eefa5230530b8608b26c09
Signed-off-by: Harmandeep Singh <hsingh@codeaurora.org>
Volume and mute settings before voice call is started are cached
in the driver, apply the cached settings at call start.
Change-Id: Iabc1f47c46a8e986c79106545ac3ee977fbca99c
Signed-off-by: Neema Shetty <nshetty@codeaurora.org>
There is a usecase where compressed data is sent over HDMI IN to
ADSP. The format of compressed is detected in ADSP and sent through
the meta data to compressed driver. Add support for meta data in
compressed TX for this use case.
Change-Id: Idbb18fe4a0ad828e9c2e9d7beec048b3cedf002d
Signed-off-by: Subhash Chandra Bose Naripeddy <snariped@codeaurora.org>
QDSP6 AFE module produces error message whenever afe
loopback gain control command is issued. The reason is that
loopback gain control function sets wrong payload size.
Make change to set appropriate payload size for a given
SET_PARAM command
Change-Id: Ida2bf76baf56c35e89fe29f887f5b43af8bceabe
Signed-off-by: Patrick Lai <plai@codeaurora.org>
AV switch and US Euro headset switches are not supported
on apq8064 target. Hence removing unnecessary gpio pins
configuration.
Change-Id: Ia4747b59b63b0bf7c37054fb1bcebfc54079b481
Signed-off-by: Ravi Kumar Alamanda <ralama@codeaurora.org>
Add support for controlling pcm audio volume in DSP through
Multimedia5. Add TLV mixer control to set the pcm stream volume
Change-Id: Ie5f50c4f47ea57fe4be0aef1320c79a9d3fe7600
Signed-off-by: Subhash Chandra Bose Naripeddy <snariped@codeaurora.org>
If the vote for pm runtime is done while codec shutdown, it is possible
that the runtime pm vote occurs even before the slimbus port for tx/rx
audio channel is disconnected. This can cause problem in audio playback/
record. Fix by moving the vote for runtime pm after slimbus port has
been disconnected
Change-Id: I959a83be7bc381e80dfc0176c50cb60e59ce227b
Signed-off-by: Swaminathan Sathappan <Swami@codeaurora.org>
Signed-off-by: Patrick Lai <plai@codeaurora.org>
When session CLOSE command is sent right before session RUN command
is acknowledged, callback function can mistakenly think that
the next received acknowledgement is for CLOSE command instead of
RUN command. This triggers driver to send memory unmap command to
the Q6 while it is still processing the CLOSE command. Eventually,
this leads to an invalid memory access and causes Q6 crash.
Change-Id: Ib5d560fbcb7e8ced79cc1075a9f6bea3b55a86b6
CRs-Fixed: 377281
Signed-off-by: Jay Wang <jaywang@codeaurora.org>
ALSA framework in kernel 3.4 requires all CPU DAIs to be routed to
the repective back-end input or output. Add the routing for STUB_1,
SLIMBUS_1, SLIMBUS_3, and SLIMBUS_4 CPU DAIs.
CRs-Fixed: 376720
Change-Id: Ie7799777d500194c53520320302e667f2ed07480
Signed-off-by: Neema Shetty <nshetty@codeaurora.org>
Update the call sites of cpu_is_msm8960() to include an
additional check for the MSM8960AB target where
appropriate.
Change-Id: I54b1b9dccde2f21ada27bc64df02c2cb313ff1d1
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
Get session time command don't use the command state
value used for control commands. Don't set that state
value as it leads to volume command being timed out
which is waiting for this value to be reset.
Change-Id: I734a1ed7f4fda8d1367c27b71d7bfe5070f2ffc6
CRs-fixed: 377431
Signed-off-by: Swaminathan Sathappan <Swami@codeaurora.org>