Commit Graph

138 Commits

Author SHA1 Message Date
Niranjan Dighe
503eb55823 adsp: fix tlv read write issues
Change fixes problems caused in tlv read and write
synchronization with other messages
- Add separate spinlock completions for tlv read
- Add separate spinlock completions for tlv write
- Add separate ack for raw (tlv) messages
- Print msgq indexes when queue or dequeue fails

Bug 2420196

Change-Id: I405e3a9939ec804dc65875d900ba635d2dc15ee3
Signed-off-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1975072
(cherry picked from commit 1df184d908c84c8f4e15b48cdd9ada90da313169)
Signed-off-by: Niranjan Dighe <ndighe@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1986443
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Uday Gupta <udayg@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Niranjan Dighe
9050c3e455 adsp: Make set_eos method generic
- Create generic nvfx_method_set_eos
- Required for plugin specific EOS handling

Bug 2402965

Change-Id: I4e52eca46769862e13ca947a27fcabccc3a1d70d
Signed-off-by: Niranjan Dighe <ndighe@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1974986
(cherry picked from commit 9b48f057c2629bc000b745409551a80597aa4aab)
Reviewed-on: https://git-master.nvidia.com/r/2027461
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com>
Reviewed-by: Hariharan Sivaraman <hariharans@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Jonathan Hunter
736ce72f4b ASoC: tegra-alt: Make ADSP parameter controls write-only
Currently, the ADSP is not booted or if the ADSP is booted but the
plugin is not connected for the ADSP APP, then it is not possible to
configure the various ADSP parameter mixer controls. This causes a lot
of messages to be displayed when the ALSA restore systemd service is
enabled because on boot it will try to restore all mixer controls.

The ADSP mixer controls for setting APP parameters are by default
read/write, however, the function to return the current APP parameters,
tegra210_adsp_get_param(), simply returns zeros and not the actual
parameters. Therefore, make these mixer controls write-only so that
the ALSA restore service will not attempt to save and restore them.

Bug 200458098

Change-Id: Ia61329c4dc338a1973e755ece23082bd2411f9be
Signed-off-by: Jonathan Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/2019227
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Jonathan Hunter
29bfa0b857 ASoC: tegra-alt: Don't display error if app not available
Rather than displaying an error message is an app cannot be loaded,
print a message to indicate that an app was loaded successfully. For
L4T applications such as MP3 decode are not available and this avoids
unnecessary error messages.

Bug 200458098

Change-Id: I2e3acbf2977797c79a0eabee6b7c8c49b33b0df1
Signed-off-by: Jonathan Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/2007328
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Jonathan Hunter
8054d6f242 ASoC: tegra-alt: Always allow ADSP APM controls to be set
Currently, the ADSP is not booted or if the ADSP is booted but the
plugin is not set for the ADSP APP, then it is not possible to
configure the various APM mixer controls. This causes a lot of
messages to be displayed when the ALSA restore systemd service is
enabled because on boot it will try to restore all mixer controls.

Rather than prevent the user from being able to set APM mixer
controls until the ADSP is booted and the plugin is set, always
store the APM settings. If the ADSP is booted or the plugin is not
set when the APM controls are set, then when the ADSP is booted and
the plugin is set, send the APM settings to the ADSP at this time.

Bug 200458098

Change-Id: I8899d876d1d10bd0e07e7c54d6674ca29aef0558
Signed-off-by: Jonathan Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1973345
Reviewed-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: Mohan Kumar D <mkumard@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Mohan Kumar
9320c90d73 ASoC: tegra-alt: Boot the ADSP OS during probe
Currently the ADSP OS is booted only when the mixer control
'ADSP Init' is set, So ADSP OS won't be booted and during
alsa-restoring of service it lead to os not booted error
message.

So try booting the ADSP OS as soon as ADSP tegra-alt driver
is registered.

Bug 200458098

Change-Id: I3cd123bdb5d5f87ba8c9329d0e43241189ffdb66
Signed-off-by: Mohan Kumar <mkumard@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1935089
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Jonathan Hunter <jonathanh@nvidia.com>
Tested-by: Jonathan Hunter <jonathanh@nvidia.com>
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-by: Viswanath L <viswanathl@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Jonathan Hunter
5e0682c2e7 ASoC: tegra-alt: Fix failure path and removal of ADSP
If the ADSP fail during the probe after the ADSP component is
registered, the ADSP component will not be unregistered and this will
cause the kernel to crash when attempting to the probe the component.
Furthermore, if the removal of the ADSP device, the component and codec
register by the ADSP driver are not removed. Fix these items by ensuring
the the ADSP component and codec are removed as necessary during the
probe failure path and driver removal.

Finally, clean-up some of the prints in the driver probe to drop the
unnecessary print when the netlink is created and use the dev_xxx
functions instead of the pr_xxx functions.

Bug 200458098

Change-Id: I4b51949e1c10c86952008ebe5676832e381a68f4
Signed-off-by: Jonathan Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1974520
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Mohan Kumar D <mkumard@nvidia.com>
Reviewed-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-by: Bibek Basu <bbasu@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Viswanath L
dc841995d9 tegra-alt: adsp: Do not adjust Compress PCM pos
PCM pointer in compress path need not be adjusted for sample rate
conversion as rate conversion always happens in AHUB (ASRC) and not
in ADSP; cases where rate conversion happens in ADSP will no longer
return correct position

Bug 200430129

Change-Id: I93e3f0680260ce057a17c70f037c9093be3e17cf
Signed-off-by: Viswanath L <viswanathl@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1959444
(cherry picked from commit fd33d1360f3a2e684363eecf9f0570b66fa2f51d)
Reviewed-on: https://git-master.nvidia.com/r/1984711
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: svc-mobile-misra <svc-mobile-misra@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Sumit Bhattacharya <sumitb@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Niranjan Dighe
f4a50891b0 sound: soc: Separate ADSP driver for virt/non-virt
- Copied the adsp driver from tegra-alt to tegra-virt-alt
- Modified tegra-virt-alt Kconfig and Makefile to make it
  dependent on SND_SOC_TEGRA_VIRT_T210REF_PCM and
  TEGRA_NVADSP
- Make the drivers exclusive with respect to device tree
  node compatibility
- Remove all the code guarded under SND_SOC_TEGRA_VIRT_IVC_COMM
  from tegra-alt ADSP driver .
- Remove all the #ifdefs from the tegra-virt-alt ADSP driver.
- Change ADSP drv name used by dai_links
- Update dai_links with new name
- add -EPROBE_DEFER on sound card register failure. This may
  be required if we decide to remove virt drivers from
  /etc/modules and /etc/modprobe.d/blacklist.conf
- Cleanup in case of deferred probe

Jira: EMA-904
Jira: EMA-1158

Change-Id: I0e707eca1bfa27b3f1814e367baa16e97bf464e5
Signed-off-by: Niranjan Dighe <ndighe@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1966030
GVS: Gerrit_Virtual_Submit
Reviewed-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-by: Uday Gupta <udayg@nvidia.com>
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Hariharan Sivaraman
0f9b5bd384 tegra-alt: fix order for ADSP IO to IO ivc msg
For start of any usecase, the DMA and AHUB blocks
should be enabled in the order from sink to source.
For stop, blocks should be disabled from source
to sink.

Previously, DMA was triggered first then ADMAIF
enable/disable messages were done. Fixed order to:

Start:
 - send start playback IVC
 - trigger DMA by sending active state msg to ADSP
 - send start capture IVC

Stop:
 - send stop capture IVC
 - trigger DMA by sending inactive state msg to ADSP
 - send stop playback IVC

Bug 2407746

Change-Id: Icf25422eccb16af8fa40357910f79320dbd92a0f
Signed-off-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1932277
(cherry picked from commit efead3a657c2b38ec359ad19573d0b3f20e8fb49)
Reviewed-on: https://git-master.nvidia.com/r/1938889
GVS: Gerrit_Virtual_Submit
Reviewed-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-by: Uday Gupta <udayg@nvidia.com>
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Mohan Kumar
82b4e51656 ASoC: tegra-alt: Support for secure playback
Add support for secure audio playback in adsp driver
- Add Secure Mode control to set whether an APM memory will be APR or not.
- Send message for all the plugins within apm to allocate apr memory before
the start of pcm/compress playback.

Bug 200235401

Change-Id: I0aba7197b10a4aab05fff5564e33c529cd2f68f5
Signed-off-by: Mohan Kumar <mkumard@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1602237
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
22fa30cd39 tegra-virt-alt: nvaudio_ivc_send_receive added
Currently exposed api's have limitations of receive
request getting processed out of order. Change make
sure to process ack/receive based message before
queueing other. Also removing unused api's as code
cleanup.

Bug 2403937

Change-Id: Ic3141aac53bc0904dfcad699d419b9ca8aaea155
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1927929
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
(cherry picked from commit d6c592f7ada5ecbcd9af290149af01b52b89b8a3)
Reviewed-on: https://git-master.nvidia.com/r/1753352
GVS: Gerrit_Virtual_Submit
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
spujar
737cefc6e0 tegra-alt: adsp: release socket in device remove
Following error is seen during multiple unload/load of driver,
 Error creating socket
 tegra210-adsp: probe of tegra210-adsp failed with error -1
This is resulting in kernel panic and device reboot.

Following is the crash,
===============================================================================
Unable to handle kernel NULL pointer dereference at virtual address 00000010
Mem abort info:
 ESR = 0x96000005
 Exception class = DABT (current EL), IL = 32 bits
 SET = 0, FnV = 0
 EA = 0, S1PTW = 0
Data abort info:
 ISV = 0, ISS = 0x00000005
 CM = 0, WnR = 0
user pgtable: 4k pages, 39-bit VAs, pgd = ffffffc3e5a09000
[0000000000000010] *pgd=0000000000000000, *pud=0000000000000000
Internal error: Oops: 96000005 [#1] PREEMPT SMP
PC is at soc_probe_component+0x90/0x350
LR is at soc_probe_component+0x34/0x350
pc : [<ffffff8008d59fb0>] lr : [<ffffff8008d59f54>] pstate: 40400045
sp : ffffffc38bbab8c0
x29: ffffffc38bbab8c0 x28: 0000000000000000
x27: 0000000000000000 x26: ffffff80018f19b8
x25: ffffffc3e5acf800 x24: ffffffc3e8b44e00
x23: 00000000000000f8 x22: 0000000000000001
x21: ffffff80018f19b8 x20: ffffff800a067000
x19: ffffffc35b93aa50 x18: 000000003e48590c
x17: 00000022d6c5fcd0 x16: ffffff8008153de0
x15: 0000000300000000 x14: 0000000000000000
x13: 0000000000000003 x12: 0000000000000026
x11: 0000000000000005 x10: 0101010101010101
x9 : 0000000000000000 x8 : 7f7f7f7f7f7f7f7f
x7 : 2f30316071666473 x6 : 070b035f125d521d
x5 : 1d525d125f030b07 x4 : 0000000000000000
x3 : 6dcc85ae6dec65a0 x2 : 000000000000008c
x1 : ffffff80094aa810 x0 : 0000000000000000
Process insmod (pid: 5755, stack limit = 0xffffffc38bba8028)
Call trace:
[<ffffff8008d59fb0>] soc_probe_component+0x90/0x350
[<ffffff8008d5afc8>] snd_soc_instantiate_card+0x4d8/0xb58
[<ffffff8008d5b7a4>] snd_soc_register_card+0x15c/0x200
[<ffffff80018ed630>] tegra_machine_driver_probe+0x3d0/0x5a0
[<ffffff80087c3da0>] platform_drv_probe+0x60/0xc8
[<ffffff80087c1278>] driver_probe_device+0xd0/0x410
[<ffffff80087c16dc>] __driver_attach+0x124/0x128
[<ffffff80087beba8>] bus_for_each_dev+0x88/0xe8
[<ffffff80087c0a68>] driver_attach+0x30/0x40
[<ffffff80087c0438>] bus_add_driver+0x1f8/0x2b0
[<ffffff80087c2648>] driver_register+0x68/0x100
[<ffffff80087c3ce4>] __platform_driver_register+0x5c/0x68
[<ffffff8001276018>] tegra_asoc_machine_driver_init+0x18/0x30
[<ffffff80080832ac>] do_one_initcall+0x5c/0x170
[<ffffff80081ba740>] do_init_module+0x68/0x1b8
[<ffffff80081538dc>] load_module+0x1004/0x1320
[<ffffff8008153ef0>] SyS_finit_module+0x110/0x128
[<ffffff8008083040>] el0_svc_naked+0x34/0x38
---[ end trace 39fa2dd2a3c341ef ]---
===============================================================================

Fix info,
This patch releases the socket in device removal and adsp probe succeeds
Thus avoid above crash during sound card registration.

Bug 200453666

Change-Id: Idb113b9aca71f830cd33cd8f9c3d742ad86280bb
Signed-off-by: spujar <spujar@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1847927
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
spujar
113a32d573 Revert "tegra-alt: adsp: disable remove() callback"
This reverts commit 7d761982ba0689d7d6c933dd17397624bc47a350.
(manual revert since there were conflicts)

Bug 200453666

Change-Id: I904f5d9b915de95f5b1256104d2473008252dd8a
Signed-off-by: spujar <spujar@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1847926
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
dipeshg
92d1ab20d3 tegra-alt: adsp: ignore drain msg to audioserver
On drain trigger no special handling is required on
audioserver side. Change adds case to ignore drain
message to audioserver.

Bug 2117496

Change-Id: I575b895651ed21179c743a0aa0e5f63eea354a5a
Signed-off-by: dipeshg <dipeshg@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1812302
Reviewed-by: Uday Gupta <udayg@nvidia.com>
Reviewed-by: Hariharan Sivaraman <hariharans@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Viswanath L
ffdbb9edcd tegra-alt: adsp: Add pcm_drain functionality
- TRIGGER_DRAIN support is added in pcm_trigger, which sends EOS
    message to ADSP; this is needed so that ADSP sends notification
    for last consumed buffer
 - DRAIN handling in pcm path is as per the implementation in native
    PCM driver

Bug 2117496

Change-Id: I530c16aaea3993569ecf2733f01d43b37df604c1
Signed-off-by: Viswanath L <viswanathl@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1792940
Reviewed-on: https://git-master.nvidia.com/r/1806327
GVS: Gerrit_Virtual_Submit
Reviewed-by: Sumit Bhattacharya <sumitb@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
68f28205ff ASoC: tegra-alt: adsp_audio suspend/resume handling
Change adds suspend/resume to adsp_audio driver.
Also updating pcm_trigger to set FE to inactive state. Setting to
inactive state will make sure dma is paused and not stop when suspend
request is received.

Jira EMA-641

Change-Id: Iadf577266b8f7452acc72526f72f059cfd06ab49
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1689151
Reviewed-by: Sharad Gupta <sharadg@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
Reviewed-by: Sachin Nikam <snikam@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Gaurav Tendolkar
df31a96ba7 tegra-alt: adsp: add adsp fe switch support
Adding ADSP FE widget event which enables/disables
ADMA when using ADSP pcm device, pause the DMA on
path disconnect event. This prevents glitches
if another app starts writing on same ADMAIF
using another ADSP pcm device

Bug 200298756
Bug 2119806

Change-Id: I96f27be3b9616954f7b5acc12deb5935ba770180
Signed-off-by: Gaurav Tendolkar <gtendolkar@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1462190
(cherry picked from commit 93eac105424234b082d7f13ee2ba443594604116)
Signed-off-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1732695
(cherry picked from commit 957029384bc4d51ab79b6e2bef2b9093819b54d5)
Signed-off-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1730254
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Hariharan Sivaraman
cb3d3637bf tegra-alt: adsp: update index for send bytes ctrl
Number of ADSP plugins were increased to 20. The
PLUGIN_SEND_BYTES_IDX macro should be updated to reflect
the same.

Bug 2048629

Change-Id: Ia02361600530f88b133eae1a67e440570e19dfb4
Signed-off-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1775907
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: Uday Gupta <udayg@nvidia.com>
GVS: Gerrit_Virtual_Submit
Tested-by: Uday Gupta <udayg@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
a143f333df nvadsp: prevent race in os_queue for app
Change add spinlock to nvadsp app start and init
functions for os_queue write protection. It make
sure only one app from different context can update
queue at given time.
Also added some debug info to adsp driver for providing
extra info for debugging purpose.

Bug 2060866

Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Change-Id: If1bbfdb233d2af984f62bb02ed515eec1ab8a492
Reviewed-on: https://git-master.nvidia.com/r/1655974
(cherry picked from commit 7edeb242aba4cabc517b6e270b254777e3ea66ea)
Reviewed-on: https://git-master.nvidia.com/r/1775133
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Dara Ramesh
155bf200a9 tegra-alt: adsp: include linux/clk.h
include linux/clk.h to fix build error
on T210 platform when compile ADSP without
enabling T210Ref machine driver for K4.14.

Bug 200406253

Change-Id: I3843962d303320e1f6322a578c9aa9add3ab8c9b
Signed-off-by: Dara Ramesh <dramesh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1764177
Reviewed-by: Joseph Lo <josephl@nvidia.com>
Tested-by: Joseph Lo <josephl@nvidia.com>
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Hariharan Sivaraman
d2da4eb6b4 tegra-alt: adsp: add error event handling
Socket based messaging mechanism to send ADSP error
events to any userspace application listening for the
ADSP events

Bug 2015160

Change-Id: I0ed9ca4ed1ca491ad8211901fd87a7011ddb03c9
Signed-off-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1668119
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: Uday Gupta <udayg@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Hariharan Sivaraman
540f5ece2c tegra-adsp-alt: increase num of plugins
Increase number of supported plugins by ADSP
from 10 to 20

Bug 2048629

Change-Id: I44410252635fafb4b4d484ce75e642286e954ab2
Signed-off-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1664190
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
a6c5cba8dd tegra-alt: apm stack size from dt
Change add support to pass apm thread
stack size from device tree using property
"apmX-stack-size = <N>"

Bug 200389033

Change-Id: Id09703bfc5a3edfa55ec9c389d62660fdf8b6b62
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1662846
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Uday Gupta <udayg@nvidia.com>
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Hariharan Sivaraman
05577afab1 tegra-alt: incr ADSP params limit
For plugins which send integer type data, increasing
limit to 0xFFFFFFFF allows for negative values to
be sent to ADSP where plugin code can typecast uint to
int and obtain desired negative value

Bug 1990609
Bug 200381729

Change-Id: I2afecc934e10d4f82badab739e26f7adae1d4cca
Signed-off-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1641078
(cherry picked from commit 315bae2da963f24785acb24705ae9273bdb0f436)
Reviewed-on: https://git-master.nvidia.com/r/1645013
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: Uday Gupta <udayg@nvidia.com>
Reviewed-by: Ajay Nandakumar M <anandakumarm@nvidia.com>
Reviewed-by: Mohan Kumar D <mkumard@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Hariharan Sivaraman
fbeffb7043 tegra-alt: ADSP IO to IO support for virt configs
Add handling for IO to IO use cases in ADSP for
virtualized configurations

Jira EMA-497
Bug 1990609

Change-Id: Ied779014ca2c484d6741329d94500c0e51e10b80
Signed-off-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1589042
(cherry picked from commit ea529d5d074c8ccb577341b5a1d834db2253ded2)
Reviewed-on: https://git-master.nvidia.com/r/1562134
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Uday Gupta <udayg@nvidia.com>
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Sameer Pujar
d8cccfd903 ASoC: tegra-alt: remove devm_clk_put() APIs
Clock resource is associated with a device and when the device
is unbound, the resource is freed. Drivers get the clock handle
by using devm_clk_get(). No need for an explicit devm_clk_put()
to release the clock, this is handled automatically when the
device lifetime ends.

Bug 200346429

Change-Id: I0885723e3a9a3fb41e54524ddacc3415f571576c
Signed-off-by: Sameer Pujar <spujar@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1574311
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: svccoveritychecker <svccoveritychecker@nvidia.com>
Reviewed-by: Mohan Kumar D <mkumard@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
2022-09-29 15:30:21 +05:30
Sameer Pujar
52b1047acc ASoC: tegra-alt: avoid address hardcoding
xbar codec is registered as per the physical address and the same
is used while defining the dai links. This results in unnecessary
duplication of the code and this is not scalable for upcoming
platforms too. This patch removes such hardcodings for xbar and
adsp audio driver by using dev_set_name() api.

Bug 200346429

Change-Id: I16147b94cc1686ceb8b084ead91d2d35b1f0fbbd
Signed-off-by: Sameer Pujar <spujar@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1568711
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Mohan Kumar
fd1f50ee48 ASoC: tegra-alt: Avoid reg access after shutdown
Below are the hypothetical scenarios
- Drivers are in suspend state while reboot and PCM Open call from
  userspace is received after driver shutdown [APE is power gated
  already]
- PM domain handling doesn't ensure proper functionality after driver
  shutdown is called

The change handles with the below fix
- Will prevent any reg access in runtime resume of drivers and avoid
  opening pcm devices.

Bug 200333417

Change-Id: Ieba2a063342cd1e7becb79a0135cb2b8ec373a61
Signed-off-by: Mohan Kumar <mkumard@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1539396
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: svccoveritychecker <svccoveritychecker@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
a22ea5aac7 ASoC: allow switch to set source before playback
For switch currently we rely on setting switch source
after playback has started in null-sink mode. However
this will leads to missing few frames of intial data.
Thus change adds support to allow setting source to
switch before playback is started.

Jira EMA-528

Change-Id: I2301da6d8b256bb188a8c442058bd87cac5a48ca
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1517265
Signed-off-by: Sameer Pujar <spujar@nvidia.com>
(cherry picked from commit 313c392daeeb84a12a01b1befc47ab1826c2126e)
Reviewed-on: https://git-master.nvidia.com/r/1533084
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
d772f9ce82 ASoC: tegra-alt: override adsp fe-name
Change provide options to update fe-names.
This can be controlled via dt property
fe-info.

Jira EMA-421

Change-Id: Ie8c18e20f07d8a910e93f52720289a3ea70ee347
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1514371
Signed-off-by: Sameer Pujar <spujar@nvidia.com>
(cherry picked from commit ef7904abf93b0451761c304d19f2e6281672e2ab)
Reviewed-on: https://git-master.nvidia.com/r/1533083
GVS: Gerrit_Virtual_Submit
Reviewed-by: svccoveritychecker <svccoveritychecker@nvidia.com>
Reviewed-by: Sachin Nikam <snikam@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
b271d423d8 ASoC:tegra-alt: fix const char* crash
Observing runtime crash in adsp-alt probe
as we are trying to update const char* strings
to update plugin names. Change assign new
memory for all such plugin name updation
and update the respective pointer.

Jira EMA-421

Change-Id: Idc9861b6d00c6b3bb7241edc93dfdcda48b12589
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: https://git-master/r/1513420
Signed-off-by: Sameer Pujar <spujar@nvidia.com>
(cherry picked from commit 216675854724320b66215395b1867fe825551f3a)
Reviewed-on: https://git-master.nvidia.com/r/1533082
GVS: Gerrit_Virtual_Submit
Reviewed-by: svccoveritychecker <svccoveritychecker@nvidia.com>
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
Reviewed-by: Sachin Nikam <snikam@nvidia.com>
2022-09-29 15:30:21 +05:30
Sameer Pujar
f734578a22 ASoC: tegra-alt: send bytes for period size msg
tegra210_adsp_send_period_size_msg is sending size in period size
which is wrong and it should be no of bytes in the period size.

Bug 200329032

Change-Id: Ib43569d24dcfeeeac36c878a51affaa347eacf0b
Signed-off-by: Mohan Kumar <mkumard@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1519960
Signed-off-by: Sameer Pujar <spujar@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1532211
GVS: Gerrit_Virtual_Submit
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
6b67bfa9a0 ASoC: tegra-alt: switch support for adsp
Change allows support to select one FE among allowed
FE's to be routed to ahub, with rest of the inputs
in drain mode.

Jira EMA-389

Change-Id: I31889a52d67390dcfbf0f2d391acd86bb76cd64e
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: http://git-master/r/1331535
Reviewed-by: Uday Gupta <udayg@nvidia.com>
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
GVS: Gerrit_Virtual_Submit
2022-09-29 15:30:21 +05:30
Sameer Pujar
3f5db4388d ASoC: tegra-alt: adsp: callback func ptr for adma
There is a function exported from adsp os code, nvadsp_set_adma_dump_reg,
to set the function pointer for adma regdump callback.

This patch uses the above exported api and sets the callback to
tegra_adma_dump_ch_reg, which is implemented by adma driver.
This is done during tegra210_adsp_init.

Bug 200289390

Change-Id: If1c2826928d5e5d51a805ed0a2211c20a1ecf6f8
Signed-off-by: Sameer Pujar <spujar@nvidia.com>
Reviewed-on: http://git-master/r/1484830
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Mohan Kumar
9a3f4fe1d7 ASoC: tegra-alt: unify tegra-alt driver
Unify adsp and i2s driver to support kernel unification.

Bug 200257345

Change-Id: Ic472c4fec0e1febf9b26a9a0ad67138329a25884
Signed-off-by: Mohan Kumar <mkumard@nvidia.com>
Reviewed-on: http://git-master/r/1477310
GVS: Gerrit_Virtual_Submit
Reviewed-by: Sameer Pujar <spujar@nvidia.com>
Reviewed-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
2022-09-29 15:30:21 +05:30
Uday Gupta
f070dc4c40 ASoc: tegra-alt: ADMA channel property parsing
Add code to use the ADMA start channel number from DT
entry nvidia,adma_ch_start

Jira EMA-413

Change-Id: Iec098d133226f70e455dd8ff0b706636f678ab2f
Signed-off-by: Uday Gupta <udayg@nvidia.com>
Reviewed-on: http://git-master/r/1477152
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Uday Gupta
104d2c7cea ASoC: tegra-virt-alt: Add 24 kHz support
Use SNDRV_PCM_RATE_KNOT instead of
SNDRV_PCM_RATE_8000_192000 to support 24 Khz
Sampling rate

Jira EMA-412

Change-Id: I05375f8203411d0366b7c0b5e2b4dca35d70342c
Signed-off-by: Uday Gupta <udayg@nvidia.com>
Reviewed-on: http://git-master/r/1475235
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Diwakar Paliwal
f2c8d09fea tegra-alt: adsp: Use devm_clk_get for t210
Use devm_clk_get for t210 during probe. This is
required for successful probe as t210 and t186
use common clock framework on K4.4.

Enable ADSP driver for t210 config.

Bug 200297206

Change-Id: I56a7f6196c07edb00548217fac1f69b03de3a882
Signed-off-by: Diwakar Paliwal <dpaliwal@nvidia.com>
Reviewed-on: http://git-master/r/1471996
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
af364ab0a2 tegra-alt: add drain feature
Change adds draining feature for adsp playback.
NULL-SINK's are used as dapm widgets for alsa
path completion.

Jira EMA-389

Change-Id: Ic4125fc4e1b6dab7f4886fe2ad2dfdefc6962209
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: http://git-master/r/1327309
Reviewed-by: Uday Gupta <udayg@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Sharad Gupta <sharadg@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
bff751a2eb ASoc: tegra-alt: fix coverity
Change corrects:
1) Unsigned compared against 0
2) possible null pointer dereferencing.
3) Dereference before null check

Bug 200192143

Change-Id: Ib005e3bb808fb12cb5f8ee6911bd3c522c879b00
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: http://git-master/r/1467216
Reviewed-by: svccoveritychecker <svccoveritychecker@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Sachin Nikam <snikam@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
df7fa78105 ASoc: tegra-alt: increase adsp pcm dev
Change adds support to increase the number
of pcm devices exposed by adsp-alt driver.

Jira EMA-389

Change-Id: I34f23bd993c4d53619de7d74cad3c9dc2644afda
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: http://git-master/r/1454052
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: Uday Gupta <udayg@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Nitin Pai <npai@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
7f5394e3f6 ASoC: tegra-alt: remove pcm ack dependency
Change remove dependency of ack by pcm ops to update
application pointer. MMAP mode can't be used with
ops ack. When trigger is called updated app pointer
info is passed to adma plugin. On adma period
completion callback, updated application pointer
is again passed to adma plugin.

Jira EMA-389

Change-Id: Iad1376cc218b2c7b49812db34e128ed43b10eddb
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: http://git-master/r/1331554
Reviewed-by: Uday Gupta <udayg@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
76d48d8cd8 ASoC: 8 ch playback/capture support
Change adds support on adsp-alt:
- allows pcm_open for upto 8 channel.
- adds option to pass burst_size for HV
- allows BE to be configured with FE's params
  to be sent via ivc to audioserver.

Change-Id: Ib3ab3fb4d95bfc8335cd1d52eeb71cc4e5a538a5
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: http://git-master/r/1317770
GVS: Gerrit_Virtual_Submit
Reviewed-by: Uday Gupta <udayg@nvidia.com>
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: Nitin Pai <npai@nvidia.com>
2022-09-29 15:30:21 +05:30
Dipesh Gandhi
5ec5417e3c tegra-virt-alt: correct build dependency
Change adds correct build dependency
for virt-alt drivers.
Bug 1828453

Change-Id: Ifa47a3eae0335bcaf6a3473b0e13e1902c31faaf
Signed-off-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-on: http://git-master/r/1298609
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Mohan Kumar D <mkumard@nvidia.com>
Reviewed-by: Uday Gupta <udayg@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Nitin Pai <npai@nvidia.com>
2022-09-29 15:30:21 +05:30
Ishan Mittal
aa31cc268e sound: soc: tegra-alt: Use ARCH_TEGRA_210_SOC
Make use of ARCH_TEGRA_210_SOC instead of ARCH_TEGRA_21x_SOC
so that we can get rid of redundant ARCH_TEGRA_21x_SOC.

ARCH_TEGRA_210_SOC aligns to up-stream as well.

Bug 1766370

Change-Id: I10a9d9bb63b1fbac358d85a228710a208d595281
Signed-off-by: Ishan Mittal <imittal@nvidia.com>
Reviewed-on: http://git-master/r/1306757
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
2022-09-29 15:30:21 +05:30
Viraj Karandikar
5fe501ba84 tegra-alt: adsp: add parameter size checks
Fix possible buffer overflow in case of invalid user
parameter by adding size checks

Bug 1869543

Change-Id: I82ac00e24a3ca40915eb6c556454c9649cb644bd
Signed-off-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-on: http://git-master/r/1297227
Reviewed-by: svccoveritychecker <svccoveritychecker@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Dipesh Gandhi <dipeshg@nvidia.com>
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
2022-09-29 15:30:21 +05:30
Shardar Shariff Md
b49c00dac2 soc: tegra: use soc/tegra/chip-id.h for soc header
The soc tegra headers are unified and moved all the content of
linux/tegra-soc.h to the soc/tegra/chip-id.h to have the
single soc header for Tegra.

Change-Id: I8119717635823a642a08ba3e5eeed4e599f8d0df
Signed-off-by: Shardar Shariff Md <smohammed@nvidia.com>
Reviewed-on: http://git-master/r/1288269
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2022-09-29 15:30:21 +05:30
sdash
90b78c8f42 tegra-virt-alt: Match ADMAIF Client and xbar bits
Match Client and xbar bits for ADMAIF Interface

Jira EMA-380

Change-Id: I20fae77b8418f000415acf578aa858b8b12fb54e
Signed-off-by: sdash <sdash@nvidia.com>
Reviewed-on: http://git-master/r/1282761
Reviewed-by: Hariharan Sivaraman <hariharans@nvidia.com>
Tested-by: Hariharan Sivaraman <hariharans@nvidia.com>
Reviewed-by: svccoveritychecker <svccoveritychecker@nvidia.com>
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
Reviewed-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Nitin Pai <npai@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Uday Gupta <udayg@nvidia.com>
2022-09-29 15:30:21 +05:30
Viraj Karandikar
f16184f16f tegra-alt: adsp: fix coverity defects
Add validity checks on data from userspace
Fix variable hiding

Coverity ID 31982 31979

Bug 200192147

Change-Id: I7fd6a8f1016aa5fe819c230e8154e3f82971c2d9
Signed-off-by: Viraj Karandikar <vkarandikar@nvidia.com>
Reviewed-on: http://git-master/r/1275950
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
2022-09-29 15:30:21 +05:30