Commit Graph

113 Commits

Author SHA1 Message Date
LuK1337 18aceede84 Merge tag 'LA.BR.1.3.6-03910-8976.0' of https://source.codeaurora.org/quic/la/kernel/msm-3.10 into HEAD
"LA.BR.1.3.6-03910-8976.0"

Change-Id: I16643fc055aa2965fe5903396a8e5158c42cf1bc
2017-05-26 13:28:48 +02:00
LuK1337 4e71469c73 Merge tag 'LA.BR.1.3.6-03510-8976.0' into HEAD
Change-Id: Ie506850703bf9550ede802c13ba5f8c2ce723fa3
2017-04-18 12:11:50 +02:00
LuK1337 fc9499e55a Import latest Samsung release
* Package version: T713XXU2BQCO

Change-Id: I293d9e7f2df458c512d59b7a06f8ca6add610c99
2017-04-18 03:43:52 +02:00
Alexy Joseph 367fab472d ASoC: qdsp6v2: Remove Eagle code
Eagle driver is not in use any more.
Remove the code and associated calls
to it.

CRs-Fixed: 1103106
Change-Id: Ice5333861beda9538f0783b70b3267523d16fd2b
Signed-off-by: Alexy Joseph <alexyj@codeaurora.org>
2017-04-11 19:13:47 +05:30
Karthik Reddy Katta e023a636d2 drivers: soc: qcom: Add overflow check in ADM driver
Add overflow check for param length to prevent
heap overflow while allocating memory for
ADM parameters.

CRs-Fixed: 1103334
Change-Id: I1163aeaabbc84dba4cd0739a35ecbdee18b42717
Signed-off-by: Karthik Reddy Katta <a_katta@codeaurora.org>
2017-01-30 13:55:16 +05:30
Karthik Reddy Katta 51464dccb7 ASoC: msm: qdsp6v2: Fix timeout error in ADM_CMD_SET_PP_PARAMS_V5
Timeout error is observed  while waiting for
ADM_CMD_SET_PP_PARAMS_V5 command's response.
Fix the condition logic in wait_event_timeout()
to match the value set in adm_callback() when
response to ADM_CMD_SET_PP_PARAMS_V5 is received.

CRs-Fixed: 1030674
Change-Id: I711c860dc3de479eec0d22369d19615aef572ea1
Signed-off-by: Karthik Reddy Katta <a_katta@codeaurora.org>
2016-11-04 00:05:38 -07:00
Shiv Maliyappanahalli a712ad950d ASoC: msm: qdsp6v2: set token for stereo_to_custom_stereo command
Set token value with port index and copp id so that
correct wait queue handle can be deduced in the
callback of adm_set_stereo_to_custom_stereo command.

Change-Id: Ica4c1442c1143f46de2baa6eaf1890ad0cb4b742
Signed-off-by: Shiv Maliyappanahalli <smaliyap@codeaurora.org>
2016-10-02 23:43:02 -07:00
Ben Romberger bccff9608d ASoC: msm: qdsp6v2: Change audio drivers to use %pK
Change all qdsp6v2 audio driver to use %pK instead
of %p. %pK hides addresses when the users doesn't
have kernel permissions. If address information
is needed echo 0 > /proc/sys/kernel/kptr_restrict.

Change-Id: I7baa9f127266726fecf9238167a1e0128a258847
Signed-off-by: Ben Romberger <bromberg@codeaurora.org>
Signed-off-by: Surendar karka <sukark@codeaurora.org>
2016-06-28 00:42:15 -07:00
Fred Oh d0c3b150a1 ASoC: msm: qdsp6v2: fix incorrect packet size calculation
The header size included twice which cause memory out of bounds.

Change-Id: I3a6f429283cfa28a1f3761f655c00b154e25f8ce
Signed-off-by: Fred Oh <fred@codeaurora.org>
2015-07-29 11:49:05 +05:30
Fred Oh 3fd0e29c71 ASoC: msm: qdsp6v2: fix incorrect packet size calculation
APR header size is included twice which cause memory out of bounds. So
remove adding the header size again.

Change-Id: I059aaa8ff77dc32431fe5b52ad27f90df890c979
Signed-off-by: Fred Oh <fred@codeaurora.org>
2015-07-23 01:22:43 -07:00
Laxminath Kasam d12e2ff436 ASoC: audio: add rate limit for prints to avoid excessive logging
In stability runs for 8952, observe excessive logging result
in watchdog bite due to audio prints. Add rate limit check
for prints in failure cases while SSR with 500ms duration.

CRs-Fixed: 842762
Change-Id: I4dc6b5c383b2478b73027557cd30eb1b47389961
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2015-06-30 12:15:36 +05:30
Linux Build Service Account 1431bdd625 Merge "ASoC: msm: qdsp6v2: return specific adsp error code in q6adm" 2015-06-24 01:47:06 -07:00
Walter Yang 173c8c6eb6 ASoC: msm: qdsp6v2: return specific adsp error code in q6adm
Currently the error codes from adsp via apr are only printed in
logs. So it's necessary to propagate the specific adsp error
to the caller as return value. And the mapping from adsp error
to linux error is conducted during the propagation. The detailed
message associated with the error code will also be printed in
the log.

Change-Id: If703806f438c4648b91fe78d67cba8bfe9c08d35
Signed-off-by: Walter Yang <yandongy@codeaurora.org>
2015-06-17 13:52:24 +08:00
Aravind Kumar a312bc3d61 ASoC: msm: qdsp6v2: fix crash issue on playback
Crash is observed on playback in adm open while checking for set
bit. Enumerator takes the size sufficient enough to hold the values
and the set_bit api expects unsigned long and manipulates bits. So
when we pass enum type of variable it crashes. Changing it to
unsigned long fixes the issue.

Change-Id: I22fefed6e719dd95719fd0f1363ba382c94c7de6
Signed-off-by: Aravind Kumar <akumark@codeaurora.org>
2015-06-10 13:56:29 +05:30
Fred Oh 89dbf1d866 ASoC: msm: qdsp6v2: add adm status variable
adm status supports bitwise setting. Its first bit is used for ADM COPP
calibration required or not. adm_status can be extended for future flags.

Change-Id: Ib65271fcfbd3a22f2e87472e8db609a349dc9e20
Signed-off-by: Fred Oh <fred@codeaurora.org>
2015-06-04 15:05:49 +05:30
Alexy Joseph 7ec6118467 ASoC: msm: qdsp6v2: force open ADM in 24-bit for DTS HPX CoPP
Always open ADM in 24 bit depth when opening with DTS HPX
postmix topology as HPX requires 24-bit processing.

Change-Id: Iccd2dde26c919e16144d35679f5ae361f7548392
Signed-off-by: Alexy Joseph <alexyj@codeaurora.org>
2015-05-21 11:52:22 -07:00
Linux Build Service Account 857019feb7 Merge "ASoC: msm: qdsp6v2: Query Cal data for correct path type" 2015-05-06 06:47:08 -07:00
Ashish Jain cab8f84f5c ASoC: msm: qdsp6v2: Query Cal data for correct path type
-DAP stores cal data by querying the same from ACDB
-Use correct path value to query ACDB data.

Change-Id: Id44f730875219641ead458cd95cc5607319bad40
Signed-off-by: Ashish Jain <ashishj@codeaurora.org>
2015-05-05 19:42:49 +05:30
Dhananjay Kumar 4956cb3609 ASoC: msm: add support for AudioSphere effects
Add interface to support AudioSphere post
processing commands in DSP.
AudioSphere post processing is supported on
stereo speakers to provide virtualization
effect to audio playback.

Change-Id: I9bb17c220066fca5694079f8c9b5bd6b31efb14c
Signed-off-by: Dhananjay Kumar <dhakumar@codeaurora.org>
2015-05-01 20:24:17 +05:30
Laxminath Kasam d11c6a5da7 ASoC: change audio drivers to accomodate sid 33bit in 32-mode
In kernel 32-mode, SID address being 33bit is truncated.
To address this issue, update audio drivers to fetch
SMMU SID info from audio ion driver and fill the upper 32 bits
accordingly for 32-bit mode.

Change-Id: Ie2fa573def36d7b346d6a96249239ef1ecc7f8e0
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2015-04-27 17:24:51 +05:30
Linux Build Service Account 1d0c1d58ed Merge "ASoC: msm: qdsp6v2: add support for source tracking feature" 2015-04-23 06:58:58 -07:00
Narsinga Rao Chella 2de73ba105 ASoC: msm: qdsp6v2: add support for source tracking feature
Fluence module on ADSP is upgraded to support source
tracking, sound focus and audio zoom features. This
change adds support for the same on kernel and is
needed to support the features end-to-end.

Source Tracking is the capability to identify the source of
speech. Sound Focus is the capability to configure which
sectors in the 360 degrees plane to listen to. Audio Zoom
is the capability to combine the sound focus with other
technologies so that a user can listen in on a particular
source in a scene.

Change-Id: Id62ddd3b00eb212969eaf7a0fd7ead690c59137e
Signed-off-by: Narsinga Rao Chella <nrchella@codeaurora.org>
2015-04-15 22:34:45 -07:00
Banajit Goswami 7e23c247e6 ASoC: msm: qdsp6v2: avoid returning 0-size cal block
When looking for calibration data blocks, check for size being
non-zero before returning to the caller.

Change-Id: I8f94d17455000c0f15e53bf7685b21a7b1c1955e
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
2015-03-17 22:12:12 -07:00
Linux Build Service Account d006fcf455 Merge "ASoC: msm: qdsp6v2: improve DTS Eagle driver for all possible i/p" 2015-03-15 20:59:12 -07:00
Linux Build Service Account 95128c130d Merge "ASoC: msm: qdsp6v2: fix adm rx direction as 0" 2015-03-13 01:52:10 -07:00
Alexy Joseph 35ebbf19be ASoC: msm: qdsp6v2: improve DTS Eagle driver for all possible i/p
Improve DTS Eagle driver to handle all possible inputs during
communications from user space.

CRs-fixed: 791160, 791162
Change-Id: I0d051b8439d85cf6b59d3e245b30051711cda84e
Signed-off-by: Alexy Joseph <alexyj@codeaurora.org>
2015-03-10 11:26:34 -07:00
Patrick Lai 0bf3f41a07 ASoC: msm: qdsp6v2: separate multi channel map for playback and record
During concurrency testing scenario which starting multi channel playback
followed by multi channel recording, it was found that channel map of
recording is over written by channel map of playback. This results in
failure to open ADM COPP as wrong channel mapping is being passed.

Separate multi channel map to playback and recording and make explicit
check to decide on which channel map to use during adm open call.

Change-Id: Ib355b95632f0f20b2062eb38b906c9d17aa827e5
CRs-fixed: 799164
Signed-off-by: Patrick Lai <plai@codeaurora.org>
Signed-off-by: Phani Kumar Uppalapati <phaniu@codeaurora.org>
2015-03-06 11:40:14 -08:00
Fred Oh ea75438a81 ASoC: msm: qdsp6v2: fix adm rx direction as 0
This is bug fix, matrix expect rx direction as 0.

Change-Id: I812d611bbb978124fffa5b0bc008961dea1dc7c9
Signed-off-by: Fred Oh <fred@codeaurora.org>
2015-03-05 12:09:59 -08:00
Alexy Joseph cafc2fcd13 ASoC: msm: qdsp6v2: avoid setting DTS HPX param on invalid copp
Check for copp index validity before setting DTS HPX param
on it.

Change-Id: Ied811e4a6bdaa88147c118201b77a90666bda9e3
Signed-off-by: Alexy Joseph <alexyj@codeaurora.org>
2015-02-19 15:11:22 -08:00
Linux Build Service Account cf1e19ab6e Merge "ASoC: msm: Add support to enable DTS HPX and SA+ exclusively" 2014-12-06 14:37:45 -08:00
Alexy Joseph e6f5c00aa6 ASoC: msm: Add support to enable DTS HPX and SA+ exclusively
Add support to enable DTS HPX and SA+ modules exclusively when
both the modules are part of a single ASM topology in NT mode.

Change-Id: I2a90e9e1cd6e2f4d915d0c55a5a67a7abc19f503
Signed-off-by: Alexy Joseph <alexyj@codeaurora.org>
2014-12-05 12:53:34 -08:00
Alexy Joseph 6762d3aa28 ASoC: msm: qdsp6v2: Fix DTS HPX Audio Effects Get Param
Handle DTS HPX get param for parameters of all data types and
check for overflow in get param compressed mixer kcontrol.

Change-Id: I12ed549e2d8187def2d33ca7aef24e2658b198e0
Signed-off-by: Alexy Joseph <alexyj@codeaurora.org>
2014-12-04 12:23:11 -08:00
Jitendra Naruka 2b822911df ASoC: msm: Integrate Eagle framework to support HeadphoneX 1.1
Add support to integrate the Eagle framework for DTS Headphone:X
audio post processing feature v1.1. Include DTS_EAGLE config for
8994 target to build the feature. It uses hwdep node to receive
required processing parameters from userspace.

Change-Id: I07cea22aa0324b0042353174a7c96e2b98a37b4b
Signed-off-by: Jitendra Naruka <jitendra.naruka@dts.com>
[alexyj@codeaurora.org: fix inclusion of header file
 msm-dts-eagle.h in msm-dts-srs-tm-config.c, resolving
 trivial merge conflicts]
Signed-off-by: Alexy Joseph <alexyj@codeaurora.org>
2014-11-30 01:03:59 -08:00
Srikanth Uyyala 99e27cef01 ASoC: msm: Fix DTS TRUMEDIA cal type initialization
Integration of DTS trumedia causes ADM cal types to not
initialize properly. Correct initialization of
cal types add in ADM.

Change-Id: I096d9bd456cd95e243fb616fa6d037dd2eeccde1
Signed-off-by: Srikanth Uyyala <suyyala@codeaurora.org>
2014-11-28 20:36:22 -08:00
Alexy Joseph caeb66d19f ASoC: msm: DTS: integrate DTS TM changes for version 3.1.2.0
Integrate the kernel changes shared by DTS  for the
latest DTS TM release 3.1.2.0. Include DTS_SRS_TM
config for 8994 target to build the feature.

Change-Id: I8d8e28486abac8e40741d7fee98d99dadaf12745
Signed-off-by: Sharad Sangle <assangle@codeaurora.org>
Signed-off-by: Alexy Joseph <alexyj@codeaurora.org>
2014-11-28 20:08:04 -08:00
Linux Build Service Account dfc27c61e3 Merge "ASoC: msm: fix bounds checking for ADM get params" 2014-11-23 21:37:32 -08:00
Linux Build Service Account 895f71d709 Merge "ASoC: msm: qdsp6v2: Fix input and output channel mapping" 2014-11-21 04:29:28 -08:00
Alexy Joseph 74ca83a95d ASoC: msm: qdsp6v2: Fix input and output channel mapping
For multichannel playback, fix default input and output channel
map to the ch mixer and add compressed driver mixer ctl to
receive the input stream channel map

Change-Id: I56d4da70274625304ba21a10b588d2f0869ca667
Signed-off-by: Alexy Joseph <alexyj@codeaurora.org>
2014-11-19 15:16:51 -08:00
Ashish Jain 9c847cc68f ASoC: msm: fix bounds checking for ADM get params
Update boundary check in ADM_GET_PARAM response,
the param_size returned from DSP is in number
of bytes, update the same in GET_PARAM_CDM_RSP.

Change-Id: Iac0f0c070a021618499bf8545c455885f2346d6a
Signed-off-by: Ashish Jain <ashishj@codeaurora.org>
2014-11-19 15:10:09 +05:30
Ben Romberger 024e49b0a0 AsoC: msm: Add App type and ACDB ID to RTAC
Add App type and ACDB ID from ADM to the audio
RTAC structure.

Change-Id: I3f7d48c8f7a0ed3c22c455465923d76ba179b971
Signed-off-by: Ben Romberger <bromberg@codeaurora.org>
2014-11-12 14:36:02 -08:00
Linux Build Service Account d2da986dfc Merge "ASoC: msm: Add bounds checking to ADM get params" 2014-11-01 15:54:36 -07:00
Ben Romberger 1fa0d0ca50 ASoC: msm: Add bounds checking to ADM get params
Add additional bounds checking to ADM get params.
Validate that all buffer sizes are valid before
dereferencing.

Change-Id: If7c7a5ae6a56812e9c4a11a38c9bdc78f42d09f3
Signed-off-by: Ben Romberger <bromberg@codeaurora.org>
2014-10-27 17:10:08 -07:00
Pradnya Chaphekar 2264651509 ASoC: msm: qdsp6v2: Add support for mute/latency on passthrough stream
Add support for setting mute/latency on passthrough stream. The latency
and mute value is set on the latency and volume modules present on the
passthrough copp topology.

Change-Id: I06f1bdfb7e943822ec51282b7868cf0f777bb716
Signed-off-by: Krishnankutty Kolathappilly <kkolat@codeaurora.org>
Signed-off-by: Pradnya Chaphekar <pradnyac@codeaurora.org>
2014-10-23 16:35:09 -07:00
Krishnankutty Kolathappilly 8cc69987dc ASoC: msm: qdsp6v2: Add support for HDMI passthrough
Add support for compressed bitstream passthrough over HDMI
for DD/DDP contents. Use compressed driver to support
passthrough.

Change-Id: I01f9e4fa984a1f45d1f4de5250bed8f95d2a2dd0
Signed-off-by: Krishnankutty Kolathappilly <kkolat@codeaurora.org>
2014-10-20 12:15:38 -07:00
Ben Romberger edb0779668 ASoC: msm: Fix misleading prints in ADM
Change misleading print statments to mention
ADM calibration instead of topology on failure.

Change-Id: I6aaed6891d6c893749a27569b12c6010132a8a16
Signed-off-by: Ben Romberger <bromberg@codeaurora.org>
2014-10-03 13:32:22 -07:00
Amit Shekhar 5eda6fe5c5 ASoC: msm: qdsp6v2: Support adm open at multiple sample rate
Currently, "Audio Stream NN App type Cfg" mixer control receives
acdb id and app type only. Using these info, adm opens at only one
fixed sample rate. By receiving sample rate in mixer control
command, adm topology selection and adm open is done at appropriate
sample rate along with other parameters. Audio calibration is also
sent and queried for the given sample rate.

Change-Id: I51784270c58c881a75e584eb454c8a3317144ace
Signed-off-by: Amit Shekhar <ashekhar@codeaurora.org>
2014-08-28 16:36:23 -07:00
Krishnankutty Kolathappilly 78b41fff40 ASoC: msm: qdsp6v2: Routing changes for Dolby DS2 audio processing
ADM driver changes to support Dolby DS2 audio processing includes
ADM apis to get modules in a copp topology, enable/disable a
module in a topology, store and set calibration data on DSP, set
volume and ramp parameters. Routing driver changes include adding
supoort for DS2 custom topology and initialize and de-initialize
ds2 module, support custom stereo processing in DS2 custom topology
and provide acdb device id as input to adm driver.

Change-Id: I5ff2929f4af32bce2aced8775bf67bf6ce815289
Signed-off-by: Krishnankutty Kolathappilly <kkolat@codeaurora.org>
2014-08-25 13:20:30 -07:00
Amit Shekhar dc31e5a219 Revert "ASoC: msm: qdsp6v2: Support adm open at multiple sample rate"
This reverts commit c7aefc8af9
Reverting this change as there are missing dependencies which
affects audio playback.

Change-Id: I108c7bddd3931cb8ec9aeaecf96e774896b9aab0
Signed-off-by: Amit Shekhar <ashekhar@codeaurora.org>
2014-08-25 13:15:17 -07:00
Amit Shekhar c7aefc8af9 ASoC: msm: qdsp6v2: Support adm open at multiple sample rate
Currently, "Audio Stream NN App type Cfg" mixer control receives
acdb id and app type only. Using these info, adm opens at only one
fixed sampling rate. By receiving sample rate in mixer control
command, adm topology selection and adm open is done at appropriate
sample rate along with other parameters. Audio calibration is also
sent and queried for the given sample rate.

Change-Id: I81da6f1a01472016ad420e7e02bb28602e8d518e
Signed-off-by: Amit Shekhar <ashekhar@codeaurora.org>
2014-08-15 14:21:39 -07:00
Bhalchandra Gajare 79f7e503b9 ASoC: qdsp6v2: Move calibration header files
It is possible that the audio calibration header files will be used from
other modules within audio drivers. Move the header files to common
common location to be accesible by other modules.

Change-Id: I6d48126865f2c3b35f1bdbff42f62456932d6bd2
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
2014-08-08 16:56:08 -07:00