Commit Graph

282 Commits

Author SHA1 Message Date
Linux Build Service Account
0f70258551 Merge "msm: featurize support for 32channels from QDSP6" 2018-10-16 01:49:01 -07:00
Linux Build Service Account
1929529772 Merge "asoc: qcs405: Use changed clock for SPDIF interfaces" 2018-10-15 21:21:25 -07:00
Mangesh Kunchamwar
9f295c71fe msm: featurize support for 32channels from QDSP6
Add configuration flag to make use of 32channel support from
QDSP6.

Change-Id: I1e491b1ec870234140e914add4f177e5351b9953
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
2018-10-12 13:12:29 +05:30
Linux Build Service Account
38b030aa40 Merge "dsp: afe: Add support for sending aptx adaptive encoder mode" 2018-10-10 20:31:27 -07:00
Linux Build Service Account
0deaed530a Merge "soc: make snd_event stub functions as static inline" 2018-10-07 21:19:49 -07:00
Linux Build Service Account
fe905271a8 Merge "dsp: Update AFE driver to support 16 ch" 2018-10-07 21:19:44 -07:00
Linux Build Service Account
82cd1e425e Merge "asoc: add support for Slimbus 9 port" 2018-10-07 21:19:42 -07:00
Sharad Sangle
b7eba8f84a dsp: afe: Add support for sending aptx adaptive encoder mode
Add support for sending APTx Adaptive encoder mode,
High Quality or Low latency to LPASS.

CRs-Fixed: 2272343
Change-Id: Ibbe809d5ca4481d3e98931e40213dd16110f6a57
Signed-off-by: Sharad Sangle <assangle@codeaurora.org>
2018-10-05 12:22:19 +05:30
Ralf Herz
044e476310 dsp: Remove SPDIF format change detail info
Remove the detailed format information from each format change event as
sysfs interface is used now.

Change-Id: I6abd221e87b18c1f0e84e62db8076b8198e8ad24
Signed-off-by: Ralf Herz <rherz@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
2018-10-04 07:37:26 -07:00
Dieter Luecking
39b3e3cc9e dsp: Update ASM driver to support 32 ch
ASM supports now up to 32 channels. Extend
the ASM Channel map structures from 8 to 32
channels.

Change-Id: I958d15910785cf0c5707dec432b4dd3e272c3dc1
Signed-off-by: Dieter Luecking <dieterl@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
2018-10-04 07:13:39 -07:00
Dieter Luecking
50c5535991 dsp: Update ADM driver to support 32 ch
ADM supports now up to 32 channels. Extend the
ADM Channel map structures from 8 to 32
channels.

Change-Id: I87b3e4cce850af92467b139da9df67fcdafaf0b0
Signed-off-by: Dieter Luecking <dieterl@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
2018-10-04 16:11:59 +02:00
Dieter Luecking
fa7687b233 dsp: Update AFE driver to support 16 ch
AFE supports now MI2S interfaces with up to 16 channels.
Add new APR API functions to support this.
Add support for senary PCM/MI2S ports.

Change-Id: I18d48eed4e9a0476363220e959a0f254aa292056
Signed-off-by: Dieter Luecking <dieterl@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
2018-10-04 15:42:53 +02:00
Surendar Karka
b0dd21f1a3 dsp: add support for Slimbus 9 port in AFE
Add support for SLIMBUS_9 Rx and Tx ports in AFE
driver.

Change-Id: I7a21c06fd67984ef60e7d40b61a100ddc48371fc
Signed-off-by: Surendar Karka <skarka@codeaurora.org>
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
2018-10-03 03:47:47 -07:00
Vidyakumar Athota
8fb467f199 soc: make snd_event stub functions as static inline
Modify snd_event stub functions prototype as static inline
to make sure that there are no multiple definition errors
in the case of static compilation.

Change-Id: I0848be946b332df22c045b8e5fed4c39b7ee0fda
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
2018-10-02 14:32:52 -07:00
Ramprasad Katkam
62d6d76b81 soc: swr-mstr: Add logic to recursively trigger slave irq handler
Soundwire slave interrupt is only edge type, so any pending slave
side interrupts could not cause a new slave interrupt, if
they are triggered before clearing of existing interrupts.
Recursively trigger slave irq until there are no pending slave
interrupts to handle this issue.

Change-Id: I254f2467f09172490796114b48f1f0feb604ad17
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
2018-10-01 11:37:36 +05:30
Laxminath Kasam
1df09a82e5 soc: add SSR changes for swr mstr controller
Add changes to recover audio during SSR and PDR
in swr master controller driver.

Change-Id: Ibe3ae097b5f9d59b135d861c5f50f6bbc1c05af6
Signed-off-by: Rohit kumar <rohitkr@codeaurora.org>
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-09-25 11:32:40 +05:30
Linux Build Service Account
4c5c88d4f3 Merge "asoc: bolero: add support for native playback" 2018-09-17 05:14:38 -07:00
Linux Build Service Account
f4f71439c4 Merge "dsp: add support for mic break detection" 2018-09-17 05:14:36 -07:00
Laxminath Kasam
b0f27cd9f0 soc: swr-mstr: add changes to support native playback
For MCLK frequency switching to 11.2896 for native
playback support, frameshape also needs to be changed
accordingly. Add changes to support frameshape switch
based on mclk frequency for given master.

Change-Id: I0c4dd69b743f83b45eeed73f27ad10e878b9244b
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-09-11 15:52:47 +05:30
Vignesh Kulothungan
6905ecf027 dsp: add support for mic break detection
Add capability to receive notifications from voice service
when there is a change in mic break status during a voice call.
On receiving notification, send an uevent with mic status to userspace.

CRs-Fixed: 2211324
Change-Id: Ie55bd1490fd8cead7261b70169ae36eba95e4011
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-09-06 16:33:54 -07:00
Aniket Kumar Lata
9dce504834 dsp: Do not send ABR parameters if bitrate is fixed
ABR encoder config parameters should be sent to DSP
only when ABR is enabled. Do not send these parameters
for fixed bitrate.

Change-Id: Icf7e4feef65d01c8ae3f6c6123d490cadef46c97
Signed-off-by: Aniket Kumar Lata <alata@codeaurora.org>
2018-09-06 15:16:43 -07:00
Ramprasad Katkam
250075f808 dsp: afe: add support for swr wakeup irq events
Add support for soundwire wakeup irq registration and event
notification from afe.

Change-Id: I97abe0a8bb571b997a52f90e0a0f57a26c714251
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
2018-09-03 10:18:26 -07:00
Ramprasad Katkam
b5528d39f2 dsp: add blocking call support in event notifier
Add support for blocking call events in event notifier
to support functions which require waiting for events.

Change-Id: I255c19bc956506ea5076bb5fb1f09327141611a6
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
2018-09-03 10:06:31 -07:00
Linux Build Service Account
752c2f87d6 Merge "dsp: Add macro for packed 16B format" 2018-08-31 12:34:13 -07:00
Vatsal Bucha
e003f502de dsp: Add macro for packed 16B format
CDC DMA TX uses PACKED_16B format if speaker prot
is enabled. Add macro AFE_LINEAR_PCM_DATA_PACKED_16BIT
for proper value of format.

Change-Id: I1070e00d26a18c77e26ff2518ef4a1256a674e20
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
2018-08-31 12:38:57 +05:30
Banajit Goswami
06183689db soc: add support for SND event framework
Add support for SND event framework for helping with
notifications among different audio modules/drivers.
The SND event framework functions with a master/client
mechanism, where each client and the master register
with the framework, and then notifies its own status
(UP/DOWN). Each master will share a list of clients it
is interested in, and once all the clients are registered
and notified UP, the framework's state will be UP. On the
other hand, as and when any one of the client, or the master
reports its state as DOWN while the framework is UP, the
framework state would be changed to DOWN, and all clients
and the master would be let know about the change.

Change-Id: Ief6f26c5d5626c29246472ad71c247d71ee9e92f
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
2018-08-22 10:34:32 -07:00
Linux Build Service Account
b94000b1af Merge "asoc: swr: Add new parameters for swr port" 2018-08-10 13:24:08 -07:00
Ramprasad Katkam
9e90df7393 asoc: swr: Add new parameters for swr port
Add wordlength and lanectrl parameters for swr port.

Change-Id: Id36a1b0750b7e8f13e4d1eed6a9abaddc2f39a83
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
2018-08-10 16:11:08 +05:30
Linux Build Service Account
602e037449 Merge "asoc: enable MDF initialization in qcs405 target" 2018-08-08 23:32:09 -07:00
Linux Build Service Account
b7d3f59c2a Merge "asoc: codecs: Tanggu TX RX changes" 2018-08-07 10:00:30 -07:00
Linux Build Service Account
7c16441c93 Merge "Asoc: swr: Handle MBHC and IRQ interrupts from tx slave" 2018-08-07 08:53:13 -07:00
Linux Build Service Account
ed06521452 Merge "asoc: msm: update asm channel map for push pull mode" 2018-08-07 06:18:42 -07:00
Rohit kumar
759426ec4b ASoC: Add WCD937X slave and core driver
Add wcd937x swr slave and codec driver.
This adds only basic support for codec registration.

Change-Id: I87519a234f14d34a019c8f66652b7224759e639c
Signed-off-by: Rohit kumar <rohitkr@codeaurora.org>
2018-08-06 20:53:13 +05:30
Vatsal Bucha
6824cec26b Asoc: swr: Handle MBHC and IRQ interrupts from tx slave
Interrupts will be handled by slave driver. This
needs slave pointer to store virtual interrupt and
pass it as a parameter to handle_nested_irq.

Change-Id: I356102a04b4fda7e5863f809cd848d7a82b82f36
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
2018-08-06 07:16:23 -07:00
Aditya Bavanari
542582cba2 dsp: support mdf memory share cmd
Add support for MultiDSP framework (MDF) memory
share command in q6core driver.

Change-Id: Iff0da10fe835f1fce50d2725960ded5c96237955
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2018-08-06 19:45:45 +05:30
Linux Build Service Account
6baee220f0 Merge "asoc: Update mixer control for island mode setting" 2018-08-02 08:23:15 -07:00
Linux Build Service Account
c026f4c520 Merge "ASoC: codecs: Add IRQ utils support based on regmap" 2018-08-02 04:53:15 -07:00
Surendar Karka
5628e8bc98 asoc: msm: update asm channel map for push pull mode
In noirq push pull mode channel map needs to be set during
ASM open shared io stream. Add support for no irq driver to
set channel map during ASM shared io stream open.

CRs-Fixed: 2267809
Change-Id: Ic1abfe60bb54b6529fbb4cf999e50196befaba46
Signed-off-by: Surendar Karka <skarka@codeaurora.org>
2018-08-02 13:05:05 +05:30
Vatsal Bucha
485ec2c851 ASoC: codecs: Add IRQ utils support based on regmap
Add irq utils support for tanggu codec. It is
based on regmap-irq framework.

Change-Id: I93ad71f41a8bf62313bee5b6c374809c93219f5c
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
2018-07-31 03:44:52 -07:00
Aditya Bavanari
348a4a6d2a dsp: afe: Add support for Rx and TX codec dma interface
New codec dma interfaces have been introduced to connect
LPASS and Codec macros. This change is to add Rx and Tx
codec dma interface related updates to Q6 AFE native driver.

CRs-Fixed: 2281591
Change-Id: I2edbe904cd4c13801f06cdd7bd226a82db5d6d51
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2018-07-31 11:22:48 +05:30
Mangesh Kunchamwar
07b8dc90a9 asoc: Update mixer control for island mode setting
Fix overwriting of port ID in island mode mixer control.

Change-Id: Ibf650e94519ffde7655e14a88ccc9042b3a3544b
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
2018-07-30 23:17:12 +05:30
Ralf Herz
cc29b9e839 dsp: support for AFE SPDIF input interface
Support two SPDIF input and two SPDIF output interfaces in AFE.
Support 61937 compressed capture.

Change-Id: Ie71434eb53be798567a6240e0f4bf171aee305b8
Signed-off-by: Ralf Herz <rherz@codeaurora.org>
2018-07-25 21:35:33 +05:30
Linux Build Service Account
1f7a9de956 Merge "soc: swr-ctrl: Update master controller for WSA mute issue" 2018-07-20 08:34:01 -07:00
Laxminath Kasam
fbcaf32428 soc: swr-ctrl: Update master controller for WSA mute issue
Add delay in master read/write fifo for slave register update.
Handle pm runtime for clock disable to happen after usecase.

Change-Id: Ia1abc4ee3db500cbc8f42b9f08760463fb77acef
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-07-20 10:48:35 +05:30
Sharad Sangle
82777e54d5 asoc: dsp: add support for aptX adaptive
Add support for new A2DP profile aptX adaptive.
This is just like any other A2DP profiles.

CRs-fixed: 2272343
Change-Id: I219dec038e84b7b98ebb2d5233ddf576c8bbe70a
Signed-off-by: Sharad Sangle <assangle@codeaurora.org>
2018-07-12 22:26:40 -07:00
David Ng
5873163b9d audio: uapi: Add kernel symlink dependency make-style
Add kernel symlink creation $(KERNEL_USR) as make-style
dependency.  The LOCAL_ADDITIONAL_DEPENDENCIES flag in
place is not active for the generated-source mechanism.

Change-Id: I9b93679bf73cf28c244119ec34a440775579b18a
2018-07-11 13:56:22 -07:00
Banajit Goswami
f1f4a2982f include: dsp: avoid returning error code from stubbed function
If MSM_QDSP6_NOTIFIER is not enabled for a target, audio_notifier
feature will not be available for that target. Whenever a call is
made to audio_notifier when its not supported, returning error from
stubbed function may confuse the error with real failure (even though
the feature is not enabled on the target). Avoid returning error code
from stubbed function, when feature is disabled.

Change-Id: I37eb2e25e45b25948aff55f2a231195a22b16f05
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
2018-07-05 11:09:56 -07:00
Linux Build Service Account
ec7e65b420 Merge "dsp: preload voice and copp topologies" 2018-07-01 10:20:31 -07:00
Vikram Panduranga
6e55ad86b2 dsp: preload voice and copp topologies
Set topology info to q6core service in ADSP so that the
modules in a topology can be loaded before the usecase starts,
thus reducing usecase setup latency. The same topology is
unloaded before vocproc or copp is destroyed or replaced.

Change-Id: I5f8872130fb09f049e080c61edb8bb0b05e5e2de
Signed-off-by: Vikram Panduranga <vpandura@codeaurora.org>
2018-06-28 11:05:25 -07:00
Dhananjay Kumar
ce6ec5fcf2 lsm: add support for ADSP multi stage VA
Enhance APIs to get instance id and stage info from userspace,
required for multi-stage Voice Activation in ADSP.

Change-Id: Ie39a3d002a56fb8df0c241089a50d55ef700a538
Signed-off-by: Dhananjay Kumar <dhakumar@codeaurora.org>
2018-06-27 23:39:17 +05:30
Linux Build Service Account
d5b870939d Merge "uapi: lsm_params: add support for ADSP multi stage VA" 2018-06-26 18:40:21 -07:00
Linux Build Service Account
625fa8af6a Merge "dsp: q6afe: Add support to control AANC noise level" 2018-06-26 10:45:10 -07:00
Dhananjay Kumar
f7b5f39f74 uapi: lsm_params: add support for ADSP multi stage VA
Enhance APIs to get instance id and stage info from userspace,
required for multi-stage Voice Activation in ADSP.

Change-Id: I82703c63214925173f3f978339188ccddff8ba91
Signed-off-by: Dhananjay Kumar <dhakumar@codeaurora.org>
2018-06-26 15:58:44 +05:30
Sudheer Papothi
af431ad7c9 dsp: q6afe: Add support to control AANC noise level
Existing software supports only high AANC level with minimum noise.
Requirement is to support different noise levels when AANC is
enabled for better AANC effect.

Change-Id: I343d00473937f68eb86533e88b25083d554b79b1
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2018-06-23 01:53:02 +05:30
Vignesh Kulothungan
6f75e7b369 dsp: adm: Update module id for sound focus and source tracking
Update module id used in get/set for sound focus and source tracking.

CRs-Fixed: 2262638
Change-Id: Ieb35c12b8f6ec8a5db6f699f70bf85ef29b29178
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-06-21 18:18:48 -07:00
Bhalchandra Gajare
eed46bd521 ASoC: msm: qdsp6v2: Add dynamic chmix config support
Add support to dynamically configure channel mixing weightage
coefficients for both ASM and LSM sessions.
Currently the code is executed only for LSM session and can be
extended to ASM as well.

Change-Id: I727ea6fa2d3a99bbf6811005c5733535f680891b
Signed-off-by: Chaithanya Krishna Bacharaju <chaithan@codeaurora.org>
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
2018-06-19 18:45:52 -07:00
Bhalchandra Gajare
bbb641427b dsp: q6adm: add ADM_LSM_AUDPROC_PERSISTENT cal type
ADM supports certain modules that can have very large calibration sizes,
in such cases the calibration is expected to be persistent in memory.
Add new cal type for this purpose.

Change-Id: Ieb2e941036595b7dff4b8bfb341f2ec152cf648a
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
2018-06-19 15:50:19 -07:00
Bhalchandra Gajare
54b7fb7bce uapi: msm_audio_calibration: add new cal type for ADM_LSM
New cal type ADM_LSM_AUDPROC_PERSISTENT is added to enable
the larger calibration sizes for ADM that need to be kept
persistent in memory.

Change-Id: Ie23f52d6aad45dc1133a4a6fa692c1331b93d3e8
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
2018-06-19 15:49:23 -07:00
Bhalchandra Gajare
6ee5b50fd4 msm-lsm-client: decouple input and output hardware parameters
With multichannel voice activation support in LSM, it could be possible
that the input media format/hw_params to LSM would be different than
the output media format/hw_params. This change decouples the input
and output hw_params for LSM. The output hw_params are obtained through
ALSA pcm_hw_params operation, whereas the input hw_params are obtained
though the LSM_SET_INPUT_HW_PARAMS ioctl to LSM.

At the same time, the below parameter IDs are added to send the channel
information to LSM service:
	- LSM_PARAM_ID_MEDIA_FMT_V2
	- LSM_PARAM_ID_LAB_OUTPUT_CHANNEL_CONFIG

Change-Id: Ie53a087b0ec54e83c4eba93a0828f9bdd6cc147d
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
2018-06-19 15:10:18 -07:00
Bhalchandra Gajare
1f6b04af93 uapi: lsm_params: add support for lsm version 3.0
Listen v3.0 adds new algorithm and multichannel support. The
input and output of LSM could have different media format,
especially number of channels. Add required support to obtain
input hardware params from userspace. Existing pcm_hw_params
operations will be used to obtain the lsm output hw params.

Change-Id: I3feca50b4b13ece59ceb39787199e2cec17b3cae
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
2018-06-18 18:36:16 -07:00
Ramprasad Katkam
e38aed40db Asoc: swr: Bus Driver changes to support new master driver
soundwire bus driver changes to support new soundwire
master driver for Talos/vipertooth.

Change-Id: I70e52a72edd80abc72ccb99b29b1a642debec257
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
2018-06-14 00:39:50 +05:30
Mangesh Kunchamwar
4e1e71885e dsp: afe: Add support for VAD in AFE native driver
Update to AFE native driver to send VAD calibration
to DSP. Add support for per service API version query
in q6core driver.

Change-Id: I6234879054e7b5622a40912da16072fd8dbd83fe
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
2018-06-12 19:18:35 +05:30
Mangesh Kunchamwar
8c706aba34 dsp: afe: Add support for codec dma interface
New codec dma interfaces have been introduced to connect LPASS and
Codec macros. This change is to add codec dma interface related
updates to Q6 AFE native driver.

Change-Id: Ia3d1e5e80c694c8c4a7f904151adfcb504964b08
Signed-off-by: Mangesh Kunchamwar <mangeshk@codeaurora.org>
2018-06-10 22:46:57 -07:00
Vignesh Kulothungan
cf6a1215b9 dsp: add support to send uevents
Add a common function handle to send uevents from q6 layer.
Add functions to initialize and cleanup the kernel object required
to send uevents.

CRs-Fixed: 2211324
Change-Id: I9dceb4eb16d6941600455602f78f4f1498171d19
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-06-07 09:01:13 -07:00
Vidyakumar Athota
94bd8731ae dsp: add support for DC detection event in afe
Add support to register with ADSP for DC detection event
in speaker protection module.
Add support to notify audio driver clients when DC detection occurs.

CRs-Fixed: 2244131
Change-Id: Ieb467f62207546a785eac2e9b96ca677e0b10565
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-06-07 08:53:00 -07:00
Linux Build Service Account
4cc52a2bed Merge "dsp: add audio event notifier support" into audio-drivers.lnx.3.0 2018-06-06 21:05:04 -07:00
Vikram Panduranga
c712c17ab0 dsp: Add support for custom encoder
Add support to set custom encoder in ASM which
can be enabled through compress capture path.

Change-Id: I563c59eb3a0213c26ce69d3c2f8d650cf3c7d32d
Signed-off-by: Vikram Panduranga <vpandura@codeaurora.org>
2018-06-05 12:57:23 -07:00
Vidyakumar Athota
f1cba4d4b2 dsp: add audio event notifier support
Add support for audio event notifier framework to
send/receive events across audio drivers.

CRs-Fixed: 2244131
Change-Id: I1e36703a91625cd52333596d66dc21a0e8876738
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-06-01 16:09:22 -07:00
Garmond Leung
6b3f418d7e dsp: Add support for setting USB packet service interval
Add support for setting packet service interval for usb
AFE Port.

Change-Id: I2221c659f967deaccb9031a9a61b51fd475a0e22
2018-05-31 17:56:21 -07:00
Xiaoyu Ye
f0ec686d3b asoc: msm-lsm-client: add support for ADSP Generic Detection Event
ADSP detection engine module can raise Generic Detection Event to
provide variable payload data based on the information requested by
userspace. Adding new API/interface to provide support for Generic
Detection Event in LSM drivers.

Change-Id: Id5541f959ecdcf862dcfa1de1c1a1b3a796f260c
Signed-off-by: Xiaoyu Ye <benyxy@codeaurora.org>
2018-05-22 23:36:37 -07:00
Linux Build Service Account
65049fbf9d Merge "uapi: add support for ADSP Generic Detection Event" into audio-drivers.lnx.3.0 2018-05-22 20:47:44 -07:00
Karthikeyan Mani
16b697200c dsp: afe: add interface to update dp audio stream index
For DP audio Multi Stream Transport, add an interface
to set DP controller and DP stream index for display
port audio AFE port.

Change-Id: I6efbb6937a7849e5840a93541961414eb9049863
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
2018-05-10 13:43:23 -07:00
Xiaoyu Ye
7f3f59a70a uapi: add support for ADSP Generic Detection Event
ADSP detection engine module can raise Generic Detection Event to
provide variable payload data based on the information requested by
userspace. Adding required structs and macros in the LSM UAPI header
file to expose them to userspace.

Change-Id: I454fb26b53f821310b5138a0ed9f1cbe516e63c3
Signed-off-by: Xiaoyu Ye <benyxy@codeaurora.org>
2018-05-08 14:39:58 -07:00
Linux Build Service Account
40bf8e8940 Merge "asoc: dsp: Add support for adaptive bitrate" 2018-05-01 13:18:05 -07:00
Vidyakumar Athota
ddd20a414f uapi: audio: update maximum number of channels supported
Audio calibration data supports 32 channels now so update
maximum number of channels supported to 32.

Change-Id: I0b94e23fe88c4382d78db85014a81e440f720660
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
2018-04-29 19:30:03 -07:00
Aniket Kumar Lata
c0c314765f asoc: dsp: Add support for adaptive bitrate
Add support for adaptive bitrate with A2DP offload.
Set up Tx feedback path on SLIMBUS_7_TX from BT SoC
to LPASS. Configure AFE encoder and decoder for ABR.
Add bit width support to configure AFE port with
32bit for BT A2DP.

Change-Id: I8e0afaf52561e5dc70318240ba238fc42844501f
Signed-off-by: Aniket Kumar Lata <alata@codeaurora.org>
2018-04-29 15:59:32 -07:00
Vikram Panduranga
770b8383d2 dsp: Mark cal block after use
After applying calibration on DSP, cal block
is marked stale to ensure same calibration is not
reused for future usecase.

Change-Id: I9f446c0602f4ab34ca71b9d2611319624fb19cd2
Signed-off-by: Vikram Panduranga <vpandura@codeaurora.org>
2018-03-16 17:54:53 -07:00
Vignesh Kulothungan
fa497d2051 ASoC: dsp: Update audio effects driver to support Instance ID
Add support to set and get audio effects module params with
Instance ID support. Maintain support for non
Instance ID set and get param structures as well.
Use common pack and set param functions to set and
get parameters to DSP instead of handling them at an
individual module level.

CRs-Fixed: 2151551
Change-Id: I0fdba2560950c931a2ec6f152499fd4bb9f59086
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-03-04 23:22:34 -08:00
Vignesh Kulothungan
f20d5b7ea5 ASoC: dsp: Update ASM driver to support Instance ID
Add support to set and get ASM module params with
Instance ID support. Maintain support for non
Instance ID set and get param structures as well.
Use common pack and set param functions to set and
get parameters to DSP instead of handling them at an
individual module level.

CRs-Fixed: 2151551
Change-Id: I633ce10a83d9033d42fadb7bad0b26842459df84
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-03-04 23:22:19 -08:00
Vignesh Kulothungan
916967ba22 ASoC: dsp: Update dap driver to support Instance ID
Add support to set and get dap modules params with
Instance ID support for both Dolby and DS2.
Maintain support for non Instance ID set and get param
structures as well. Use common pack and set param
functions to set and get parameters to DSP instead of
handling them at an individual module level.

CRs-Fixed: 2151551
Change-Id: I1633b63a1a598c0e4ea874d00655b09a240a47e3
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-03-04 23:21:47 -08:00
Vignesh Kulothungan
60cc03517f ASoC: dsp: Update ADM driver to support Instance ID
Add support to set and get ADM module params with
Instance ID support. Maintain support for non
Instance ID set and get param structures as well.
Use common pack and set param functions to set and
get parameters to DSP instead of handling them at an
individual module level.

CRs-Fixed: 2151551
Change-Id: I5ef920448dd827d8a315e248087997f703061263
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-03-04 23:21:10 -08:00
Vignesh Kulothungan
1ccc875287 ASoC: dsp: Update rtac driver to support Instance ID
Add support to set and get rtac params with
Instance ID support. Maintain support for non
Instance ID set and get param structures as well.
Use common pack and set param functions to set and
get parameters to DSP instead of handling them at an
individual module level.

CRs-Fixed: 2151551
Change-Id: Ic96e83477e72dc5ffa4d87a1e98c34814bbd0b8d
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-03-04 23:07:03 -08:00
Vignesh Kulothungan
85073c0432 ASoC: dsp: Update AFE driver to support Instance ID
Add support to set and get AFE module params with
Instance ID support. Maintain support for non
Instance ID set and get param structures as well.
Use common pack and set param functions to set and
get parameters to DSP instead of handling them at an
individual module level.

CRs-Fixed: 2151551
Change-Id: I15dac800bdf7f860d0fbeeff86f986c42a9eae34
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-03-04 23:06:32 -08:00
Vignesh Kulothungan
cc3ff17850 ASoC: dsp: Update voice driver to support Instance ID
Add support to set and get voice module params with
Instance ID support. Maintain support for non
Instance ID set and get param structures as well.
Use common pack and set param functions to set and
get parameters to DSP instead of handling them at an
individual module level.

CRs-Fixed: 2151551
Change-Id: I045e27710d69304f234ace1ff6c80afdd4a4041c
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-03-03 15:16:04 -08:00
Vignesh Kulothungan
a65e3010a2 ASoC: dsp: Update LSM driver to support Instance ID
Add support to set and get LSM module params with
Instance ID support. Maintain support for non
Instance ID set and get param structures as well.

CRs-Fixed: 2151551
Change-Id: Id9aa5ee89bab1a4e15ff1f7868bceb42d6c25d19
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-03-03 15:14:56 -08:00
Vignesh Kulothungan
13d0d3561f ASoC: dsp: Add utility function needed for Instance ID
Add common structures and definitions used to support
instance ID.
Add helper function to populate header based on instance ID
support and pack it with payload data.

CRs-Fixed: 2151551
Change-Id: If9b7e497d0e8fdfed7d62a1ee34c415baabdda07
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-03-03 15:14:32 -08:00
Vignesh Kulothungan
5c10992ad9 ASoC: Expose APIs to get and set Instance ID support
Expose APIs to get and set instance ID support by exposing a
mixer control for userspace to set the support status as well
as APIs for kernel components to querry for instance ID support.

CRs-Fixed: 2151551
Change-Id: I3b462a4c0f31152a2865af8f4e9664a6c4d324c3
Signed-off-by: Vignesh Kulothungan <vigneshk@codeaurora.org>
2018-03-03 15:14:11 -08:00
Banajit Goswami
65b73c8f02 audio: uapi: create audio_kernel_headers target
Create a audio_kernel_headers target so that all audio UAPI
header files can be copied to the right target specific OUT
directory and make it easy for clients to mark dependency on
the header files.

Change-Id: I09ca422cbdd067e6e56fff13deaa4e92de3de1fc
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
2018-02-22 21:57:01 -08:00
Linux Build Service Account
b51bf58343 Merge "ASoC: AQT1000: add codec entry for AQT1000 codec" 2018-02-16 03:33:39 -08:00
Linux Build Service Account
bbb2154a37 Merge "ASoC: change OUT_DIR to PRODUCT_OUT for wcd9360" 2018-02-15 17:52:22 -08:00
Linux Build Service Account
ec22137f6c Merge "dsp: add cache operations for dma_buf" 2018-02-15 17:52:20 -08:00
Linux Build Service Account
95e93157f4 Merge "dsp: update MSM Audio ION wrappers to align with upstream" 2018-02-15 17:52:20 -08:00
Linux Build Service Account
6fb217c329 Merge "ASoC: uapi: Export the audio header file to userspace" 2018-02-15 17:52:19 -08:00
Linux Build Service Account
632032dd78 Merge "SoC: msm: add machine driver for SDM855" 2018-02-15 17:52:16 -08:00
Linux Build Service Account
89e0000fa2 Merge "dsp: fix low volume in audio recording" 2018-02-15 17:52:15 -08:00
Meng Wang
08d48d49eb ASoC: AQT1000: add codec entry for AQT1000 codec
Add codec entry for AQT1000 codec to support ADIE calibration.
Add new hwdep node AQT1000_CODEC_HWDEP_NODE to store ANC/MBHC
calibration data.

Change-Id: I8b5ff9a2cfe2a0a8ac593b63b20b28697dc975bf
Signed-off-by: Meng Wang <mwang@codeaurora.org>
2018-02-07 16:05:30 +08:00
Banajit Goswami
0f1f3f6d04 dsp: add cache operations for dma_buf
Add support for querying ION flags for dma_buf and for cache ops
on dma_buf with CACHED Flag on.

Change-Id: I219e564c477af8ba3b8676db1c9555a2b5b9ebab
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
2018-02-04 03:43:17 -08:00
Banajit Goswami
08bb73698a dsp: update MSM Audio ION wrappers to align with upstream
Between Linux-4.9 and Linux-4.14, upstream has updated the
ION APIs significantly to make ION ready to bring out of
staging folder. This has changed the way ION and dma_buf
APIs used to work together for allocating, mapping and
deallocating ION buffers.
Update MSM Audio ION wrapper functions used by audio drivers
to reflect these ION API changes as per upstream ION.

Change-Id: I63097e147a397aa3a538f69ac88b6fb10871c3dc
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
2018-02-04 03:41:06 -08:00
Vidyakumar Athota
9cbeb97832 codecs: add wcd9360 audio codec driver
Initial commit to add wcd9360 audio codec driver.

Change-Id: Ib4e5e41ce7e540e4426c9ca26db8e834edc3d4da
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
2018-02-02 17:24:19 -08:00
Aditya Bavanari
5106b5627c dsp: fix low volume in audio recording
ADM calibration is not sent in audio recording
use case which leads to low volume issue.
Since the LSM port ID is same as audio recording
port ID in case of internal codec, driver tries to
send LSM calibration for non LSM use case in which case
no calibration will be sent.
Instead of using port ID, use the pass_thr mode to
differentiate between LSM and non LSM use cases.

CRs-Fixed: 2167317
Change-Id: I1b6ea51d83330f6439791cf1bb6170306f6895b0
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2018-01-29 21:36:26 -08:00
Meng Wang
9bc1532306 ASoC: uapi: Export the audio header file to userspace
Audio driver requires that exported header files should
be placed in uapi folder. Change adds the audio header
files to uapi folder.

Change-Id: Ifb47492507a482b1b2f5caa00af4268e08e64803
Signed-off-by: Meng Wang <mwang@codeaurora.org>
2018-01-29 17:50:11 +08:00
Shiv Maliyappanahalli
723548296f ipc: Add support for apr over rpmsg
Add support for apr communication over rpmsg to enable
inter processor comuunication b/w APPS and ADSP for
audio usecases.

Change-Id: I834ded7f1dd709e1d9e835b852c2edc25e8607e0
Signed-off-by: Shiv Maliyappanahalli <smaliyap@codeaurora.org>
2018-01-24 21:38:06 -08:00
Meng Wang
3c88f61439 ASoC: update softlink for internal.h, core.h and pinctrl-utils.h
update softlink for internal.h, core.h and pinctrl-utils.h for sdm855

Change-Id: I3e92e8da1ab1bbfce7fbb92c6997af22777925dc
Signed-off-by: Meng Wang <mwang@codeaurora.org>
2018-01-23 14:39:15 +08:00
Linux Build Service Account
8640fa521a Merge "ipc: add api to vote for upgrading thread priority" 2017-12-20 00:31:37 -08:00
Linux Build Service Account
9c81253780 Merge "dsp: add support for new ADM LSM cal types" 2017-12-16 03:09:26 -08:00
Linux Build Service Account
7bae55be7c Merge "dsp: add LDAC encoder support" 2017-12-16 03:09:23 -08:00
Banajit Goswami
8832732009 ipc: add api to vote for upgrading thread priority
For some time critical tasks, the thread priority
might need to be upgraded to Real-Time Thread
priority level. Expose an interface from APR layer
so that clients can vote for a priority upgrade
whenever needed.

Change-Id: Ieb4afa914905750eccdf7672020a8751fdcf6462
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
2017-12-14 12:10:42 -08:00
Aditya Bavanari
2a627ae4bb dsp: add support for new ADM LSM cal types
Add support for new ADM LSM cal types in order
to avoid topology and cal block overriding during
concurrent use cases like SVA with speaker
protection.

CRs-Fixed: 2085865
Change-Id: I155d29ff0b77b069aa5970408332064c5c2aebd7
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2017-12-12 12:22:09 +05:30
Aditya Bavanari
3889b4aebb dsp: add support for new AFE LSM cal types
Add support for new AFE LSM cal types in order
to avoid topology and cal block overriding during
concurrent use cases like SVA with speaker
protection.

CRs-Fixed: 2085865
Change-Id: I9af5c34ea7ad9403b9e6d63ac5d3e73e708a320e
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2017-12-11 21:06:17 -08:00
Preetam Singh Ranawat
0a087aff7b dsp: add LDAC encoder support
Add support for LDAC encoding in dsp to
enable LDAC encoder over split a2dp path.

CRs-Fixed: 2143086
Change-Id: Ia5ed981f5cd9cc61621d667362585ec7a7e64fa1
Signed-off-by: Preetam Singh Ranawat <apranawat@codeaurora.org>
2017-12-11 21:01:26 -08:00
Preetam Singh Ranawat
f746a87965 dsp: add scrambler support in DSP over split a2dp
Add support to enable scrambler in COP Packetizer module
over split A2DP path to fix 44.1Khz playback.

CRs-Fixed: 2143142
Change-Id: I52fec39e10a1c0939fd49d1e1303b03312544abf
Signed-off-by: Preetam Singh Ranawat <apranawat@codeaurora.org>
2017-12-11 21:00:31 -08:00
Xiaojun Sang
12120ab1ad ASoC: add support for speaker protection 3.0
Add a new AFE API to send limiter threshold to ADSP.

Change-Id: Ibcd795d7c0edb4f081636c621e51e5a1eaa036b1
Signed-off-by: Xiaojun Sang <xsang@codeaurora.org>
2017-11-07 01:36:20 -08:00
Xiaojun Sang
b5321975e7 uapi: extend struct of spk prot for ADSP SPv3
To support speaker protection v3, add sp version and
limiter threshold in spk_prot_cfg struct.

Change-Id: Ia4c89934e00bfa8c0e0c6823f48d56baf6759f14
Signed-off-by: Xiaojun Sang <xsang@codeaurora.org>
2017-11-07 01:35:50 -08:00
Laxminath Kasam
8b1366a648 Audio: DLKM support for all audio modules
Switch to DLKM for all audio kernel modules.

Change-Id: I6a96023a21f655f873531af9ace81f2b01eb0f58
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2017-11-02 13:42:09 +05:30
Linux Build Service Account
953c2b88b1 Merge "dsp: add support for aptX dual mono" 2017-10-25 09:56:58 -07:00
Linux Build Service Account
22f45372f5 Merge "dsp: add support to set topology specific info in voice usecases" 2017-10-18 04:49:39 -07:00
Aditya Bavanari
88513a31e5 dsp: add support to set topology specific info in voice usecases
Add support to set number of channels and channel mapping to DSP
as per the info received from ACDB files along with topology
for a device in voice usecases instead of reading from
backend configuration. When topology specific channel info is
not supported, send the default no of channels and
channel mapping as per backend to support backward compatibility.

CRs-Fixed: 2110934
Change-Id: Iad512474fc25c906d97513f6648cd8ba6244eda1
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2017-10-14 11:51:35 +05:30
Preetam Singh Ranawat
899b78bd18 dsp: add support for aptX dual mono
Send sync mode parameter to DSP for supporting aptX dual mono.

Change-Id: I1c43b0dec6661a77644e28df45ca6c1a182745de
Signed-off-by: Aniket Kumar Lata <alata@codeaurora.org>
2017-10-11 13:43:44 -07:00
Linux Build Service Account
21d942b0f4 Merge "soc: define dummy function for swrm_wcd_notify" 2017-10-10 11:39:20 -07:00
Rohit Kumar
c08b14f78c dsp: add quinary interface support in q6afe
Add support for quinary interfaces in q6afe. Also,
fix routing for quinary tdm rx port.

Change-Id: I5db68da1cc8bc17bc5e7b743282abf83fb100bbc
Signed-off-by: Rohit Kumar <rohitkr@codeaurora.org>
2017-10-06 10:52:17 +05:30
Xiaoyu Ye
0cf63fe351 soc: define dummy function for swrm_wcd_notify
Add dummy function for swrm_wcd_notify to avoid
compilation errors when configuration options
'CONFIG_SOUNDWIRE' and 'CONFIG_SOUNDWIRE_WCD_CTRL'
are not selected for a target.

Change-Id: Ie12d2df8777934494f0f8607d846e2d1ec49f2a6
Signed-off-by: Xiaoyu Ye <benyxy@codeaurora.org>
2017-10-05 12:49:54 -07:00
Rohit Kumar
a507793028 asoc: msm: add support for quinary interfaces in dai and routing driver
Add support for dais and routing for Quinary MI2S, AUXPCM and TDM
interfaces.

Change-Id: I50c3099a658998bab805c4c6a5aa447e85f3e7c6
Signed-off-by: Rohit Kumar <rohitkr@codeaurora.org>
2017-09-26 01:37:41 -07:00
Linux Build Service Account
19d7949681 Merge "dsp: allocate contiguous memory for version information" 2017-09-20 17:55:21 -07:00
Linux Build Service Account
4b813164fc Merge "dsp: add CELT encoder support" 2017-09-14 04:20:54 -07:00
Siena Richard
2d0102dd44 dsp: allocate contiguous memory for version information
Allocate contiguous memory for version information instead of splitting
it across the stack and heap to centralize memory and improve
readability.

CRs-Fixed: 2104576
Signed-off-by: Siena Richard <sienar@codeaurora.org>
Change-Id: Id7b5942522da6312da57bfef3d3c0b55934fe1d7
2017-09-13 11:15:43 -07:00
Aditya Bavanari
245361df38 dsp: fix 2nd channel mute in VPRx out for Stereo EC ref
In Stereo EC reference, mute is observed in VPRx output
of 2nd channel when only speaker device uses custom MFC topology.

When handset and speaker use the same custom topology, issue is not
observed. Because when DSP VPRx module creates the
custom topology with handset configuration (1 channel and
center channel mapping) and device switch to speaker occurs
MFC conversion from center to left and right channels is successful.

But in case where handset uses default topology, when device
switch to speaker occurs, VPRx creates the custom topology
with speaker configuration(2 channels and left mapping). So,
when MFC config is received, only left->left mapping is done which
leads to mute in right channel.

Fix is to send the channel mixer configuration to MFC module
so that both left->left and left->right mapping is done.

CRs-Fixed: 2102374
Change-Id: If9be09866615e6623e78f48b9841eb068c825992
Signed-off-by: Aditya Bavanari <abavanar@codeaurora.org>
2017-09-11 23:02:33 +05:30
Preetam Singh Ranawat
5402849018 dsp: add CELT encoder support
Add CELT encoder support to enable audio broadcast over split a2dp.

Change-Id: If0d927913c5e525ff1cebf857323ab70be2122a1
Signed-off-by: Preetam Singh Ranawat <apranawat@codeaurora.org>
2017-09-06 03:58:45 -07:00
Laxminath Kasam
8f7ccc2e6f audio-lnx: Add latest snapshot for audio drivers.
Propagate the changes based on latest snapshot
for audio kernel source tree at below cutoff of
kernel msm-4.9 -
(040750bfa78 -
 "Revert "ARM: dts: msm: Add DT node for aop-qmp
  clock controller on SDM845 v2"")

CRs-Fixed: 2104096
Change-Id: I0927c40b3a188dbf892e7ec4c1c7810953724929
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2017-09-04 20:12:56 +05:30
Laxminath Kasam
38070be30b audio-lnx: Add latest snapshot for audio drivers.
Propagate the changes based on latest snapshot
for audio kernel source tree at below cutoff of
kernel msm-4.9 -

(aed56b2df75 - "drm/msm/sde: update te vsync enable sequence change")

Change-Id: I7ed5102146986b81e5cb9ca55432360b3549b60c
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2017-08-24 03:53:42 -07:00
Laxminath Kasam
605b42f92c audio-lnx: Rename folders to new flat structure.
Kernel audio drivers can be categorised into below folders.
asoc - ALSA based drivers,
asoc/codecs - codec drivers,
ipc - APR IPC communication drivers,
dsp - DSP low level drivers/Audio ION/ADSP Loader,
dsp/codecs - Native encoders and decoders,
soc - SoC based drivers(pinctrl/regmap/soundwire)

Restructure drivers to above folder format.
Include directories also follow above format.

Change-Id: I8fa0857baaacd47db126fb5c1f1f5ed7e886dbc0
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2017-08-18 16:56:12 -06:00
Asish Bhattacharya
84f7f73144 audio-lnx: Add latest snapshot for audio drivers.
Propagate the changes based on latest snapshot
for audio kernel source tree.

Change-Id: I15cdbf2651ee8bf70a56b08013e1fbce16859d9b
Signed-off-by: Asish Bhattacharya <asishb@codeaurora.org>
2017-08-18 16:56:09 -06:00
Asish Bhattacharya
8e2277f79f audio-lnx: Initial change for techpack of audio drivers.
Add snapshot for audio drivers for SDM targets. The code is
migrated from msm-4.9 kernel at the below cutoff -

(74ff856e8d6: "net: ipc_router: Add dynamic enable/disable
wakeup source feature")

This changes are done for new techpack addition
for audio kernel. Migrate all audio kernel drivers
to this techpack.

Change-Id: I33d580af3ba86a5cb777583efc5d4cdaf2882d93
Signed-off-by: Asish Bhattacharya <asishb@codeaurora.org>
2017-08-18 16:56:08 -06:00