Commit graph

18 commits

Author SHA1 Message Date
Vidyakumar Athota
63cd5102a4 drivers: mfd: fix audio mute issue after ADSP SSR
Native audio playback is muted after adsp subsystem restart,
because codec device_reset() API is called even before device_down()
API finishes execution. This causes audio to mute, as codec is not
in proper reset state. Add new lock to synchronize codec subsystem
restart APIs.

Change-Id: I2366f8b04fc6cb7d874661b948c3e9af10470107
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
2017-01-17 16:39:36 -08:00
Linux Build Service Account
504c6dd5d1 Merge "drivers: mfd: set IIR and ANC registers as volatile" 2016-09-16 09:22:00 -07:00
Yeleswarapu Nagaradhesh
971aeb6add ASoC: wcd: modify tasha version check macros
TASHA_IS_1_1 macro checks only for version number.
This macro returns true for tavil codec. So modify
tasha macros to check for codec and version.

CRs-Fixed: 1066331
Change-Id: I5240e0ee888187a8185974ea288ce2cad62bd776
Signed-off-by: Yeleswarapu Nagaradhesh <nagaradh@codeaurora.org>
2016-09-15 09:10:08 -07:00
Walter Yang
24bf042aef ASoC: wcd934x: Add codec version check for wcd934x
As there are many hardware version of wcd934x codec. Add version
check in the code so that userspace can get the version info.

CRs-Fixed: 1063367
Change-Id: Ia320380d568426c2d7a414a832980a556ff27f0f
Signed-off-by: Walter Yang <yandongy@codeaurora.org>
2016-09-14 08:11:38 +08:00
Phani Kumar Uppalapati
8ebf9b4780 mfd: wcd9xxx: Reduce irqsoff latency
WCD9XXX irq driver uses device tree APIs in the
IRQ handler. Device tree APIs disable interrupts
for the duration of their execution. Do not use
these APIs in the wcd9xxx irq handler to reduce
the interrupt off (irqsoff) latency.

CRs-fixed: 1055867
Change-Id: I3ec0b8dce2b2bb1ccbcb5bdd7cd6621a5f9513f8
Signed-off-by: Phani Kumar Uppalapati <phaniu@codeaurora.org>
2016-08-25 11:39:05 -07:00
Linux Build Service Account
fb6752ab65 Merge "ASoC: wcd: change classh settings as per impedance value" 2016-08-13 23:13:04 -07:00
Neema Shetty
2f2c350993 ASoC: wcd: change classh settings as per impedance value
Depending on the impedance across HPHL and HPHR, set classh
configurations so as to avoid false OCP events.
Move wcd9xxx_registers.h to uapi folder, as this header
file is used by userspace for wdc9330 codec.

CRs-Fixed: 963843
Change-Id: Ie2fb4b75b7f74013580bd3912372c64ddefc734e
Signed-off-by: Yeleswarapu Nagaradhesh <nagaradh@codeaurora.org>
Signed-off-by: Neema Shetty <nshetty@codeaurora.org>
2016-08-08 23:53:01 +05:30
Sudheer Papothi
c5ee57ee2b drivers: mfd: wcd9xxx: Add support to configure dmic clock
DMIC clock on ECPP(Echo Cancellation Ping-Pong) path can be set to
lower clock rate to avoid power consumption. Change configures the
DMIC clock rate on ECPP path based on device tree settings.

CRs-fixed: 1022917
Change-Id: I03e1a7f5ef3cf1b1907c03a3d38965ce3a611bc4
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
2016-08-04 11:05:31 -07:00
Yeleswarapu Nagaradhesh
c404b25ea3 ASoC: wcd9xxx: add support for wcd934x codec
Add wcd934x as a mfd child and configure regmap.
Configure MCLK as per the HW sequence.

CRs-Fixed: 1041199
Change-Id: I9e2dbb0f0acaa1442c1624556bc52abf98158c92
Signed-off-by: Yeleswarapu Nagaradhesh <nagaradh@codeaurora.org>
2016-07-15 17:01:55 -07:00
Yeleswarapu Nagaradhesh
eb8519c0af drivers: mfd: do not modify reset gpio if codec is identified
If target can support multiple codecs, only one of the
codecs will be enumerated. Do not clean up common resources
when other codec fails to enumerate.

CRs-Fixed: 1041199
Change-Id: I74a298739925b5763458c2e637372aa8f2c2aa55
Signed-off-by: Yeleswarapu Nagaradhesh <nagaradh@codeaurora.org>
2016-07-15 05:59:14 +05:30
Yeleswarapu Nagaradhesh
5eaa7f688f wcd9xxx: refactor wcd9xxx audio codec drivers
Refactor wcd9xxx audio codec driver for better handling
of codec specific functionalities.

CRs-fixed: 1028800
Change-Id: I229ee4a741c5a606e2eb045940f5ee3c4eabf512
Signed-off-by: Phani Kumar Uppalapati <phaniu@codeaurora.org>
Signed-off-by: Yeleswarapu Nagaradhesh <nagaradh@codeaurora.org>
2016-06-17 15:18:27 -07:00
Sudheer Papothi
b9990820a6 drivers: mfd: Allocate and register irq domain for codec interrupts
During codec interrupt controller probe, allocate and register
irq domain for codec interrupts for mapping between hwirq and
irq numbers.

Change-Id: I3e32043499f2b1e2616cf74864969815e626a23b
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2016-04-22 11:57:40 -07:00
Phani Kumar Uppalapati
e5998b6308 drivers: mfd: Move codec reset gpio config to early boot
Codec reset gpio configuration needs to be updated
before slimbus master component is initialized otherwise
codec cannot be enumerated on the bus. Add a new platform
device driver to update the codec reset gpio configuration
to valid state (output, drive-strength) before slimbus
is initialized.

CRs-Fixed: 968161
Change-Id: I7227212e6b846d58196718255aa4b0923352d120
Signed-off-by: Phani Kumar Uppalapati <phaniu@codeaurora.org>
2016-03-23 21:20:53 -07:00
Banajit Goswami
1f1fb7752f mfd: wcd9xxx: avoid slimbus read/write during ADSP reset
During ADSP subsystem restart, all slimbus read/write would fail
as the bus is not available. Avoid codec read/write, until the
slimbus master in ADSP is up.

Change-Id: Iec1933d2625c1cd3dd700b2b3e2ffc7eae64880b
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
2016-03-23 21:16:50 -07:00
Bhalchandra Gajare
b5f150167a mfd: wcd9xxx: Make DMIC clock drive strength platform dependent
Digital microphone clock drive strength setting in the codec could
be platform dependent based on the type of microphone, etc. Add support
to make the DMIC clock drive strength configurable through device tree.

CRs-fixed: 938006
Change-Id: I8b17d985052098b56d012081a77b6dfc94553eca
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
2016-03-23 21:16:35 -07:00
Yeleswarapu Nagaradhesh
2b7260c155 ASoC: wcd: add support for wcd9326 codec
Use efuse register values, to differentiate between
wcd9326 and wcd9335 codecs.

Change-Id: I68e7ae5eb1717dccd0af975670ac3644304996b9
Signed-off-by: Yeleswarapu Nagaradhesh <nagaradh@codeaurora.org>
Signed-off-by: Simmi Pateriya <simmip@codeaurora.org>
2016-03-23 21:12:50 -07:00
Phani Kumar Uppalapati
2f3bde0fa0 ASoC: wcd9335: Update low hifi and low power modes for headphones
Update register sequence for low hifi and low power modes
for headphones on wcd9335 codec to achieve better performance.

Change-Id: Icf543df7c4e8ab4cc9222a39bf1df4e6af4ab8ec
Signed-off-by: Phani Kumar Uppalapati <phaniu@codeaurora.org>
2016-03-23 21:12:25 -07:00
Sudheer Papothi
03f5d7efe2 ASoC: wcd: Add Audio codec drivers for MSM targets
Add snapshot of audio codec drivers for MSM targets. The
code is migrated from msm-3.18 kernel at the below commit/AU level-

AU_LINUX_ANDROID_LA.HB.1.3.1.06.00.00.187.056
(e70ad0cd5efdd9dc91a77dcdac31d6132e1315c1)
(Promotion of kernel.lnx.3.18-151201.)

Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2016-03-23 20:11:28 -07:00