android_kernel_samsung_sm8650/sound/usb
Krishna Kurapati 3b14c6f914 sound: usb: qmi: Prevent Null pointer deference due to connect/disconnect
Currently the sound driver uses qmi workqueues for any qmi request
sequences to execute, however while doing fast disconnect/connect
there is a possbility that the worker thread race between each other
which might lead to a scenario where in between the connect sequence
the disconnect might interfere and the endpoint might get freed.
This might lead to a null pointer deferences in the process used by
the hcd.

Fix this by making use of the chip-s usage_count to serialize these
processes. The disconnect in card drvier will wait for the usage_count
to be decreased to 0 in order to execute the disconnect sequences
which woudl make sure that the connect runs completely before disconnect.

Change-Id: I2a996a5bd6a451fdffdd3d09ba62770e3779f3f4
Signed-off-by: Udipto Goswami <quic_ugoswami@quicinc.com>
Signed-off-by: Krishna Kurapati <quic_kriskura@quicinc.com>
2023-09-28 12:12:05 +05:30
..
6fire ALSA: usb/6fire: fix repeated words in comments 2022-07-25 08:28:17 +02:00
bcd2000 ALSA: bcd2000: Fix a UAF bug on the error path of probing 2022-07-15 08:58:36 +02:00
caiaq module: remove never implemented MODULE_SUPPORTED_DEVICE 2021-03-17 13:16:18 -07:00
hiface ALSA: hiface: fix repeated words in comments 2022-07-25 08:28:37 +02:00
line6 ALSA: line6: fix stack overflow in line6_midi_transmit 2023-01-04 11:29:00 +01:00
misc ALSA: ua101: fix division by zero at probe 2021-10-27 08:23:30 +02:00
usx2y UPSTREAM: mm: replace vma->vm_flags direct modifications with modifier calls 2023-06-07 14:24:57 +00:00
card.c ANDROID: Snap to android14-6.1-2023-06 2023-08-08 17:02:27 -07:00
card.h ANDROID: Snap to android14-6.1-2023-06 2023-08-08 17:02:27 -07:00
clock.c ALSA: usb-audio: Optimize TEAC clock quirk 2022-05-31 15:09:05 +02:00
clock.h ALSA: usb-audio: Constify audioformat pointer references 2020-11-23 15:15:36 +01:00
endpoint.c This is the 6.1.23 stable release 2023-04-06 14:14:07 +00:00
endpoint.h ALSA: usb-audio: Fix recursive locking at XRUN during syncing 2023-04-06 12:10:43 +02:00
format.c ALSA: usb-audio: Fix regression on detection of Roland VS-100 2023-04-06 12:10:54 +02:00
format.h ALSA: usb: initial USB Audio Device Class 3.0 support 2018-03-21 11:46:33 +01:00
helper.c ALSA: usb-audio: Add snd_usb_get_host_interface() helper 2020-11-23 15:13:47 +01:00
helper.h ALSA: usb-audio: Add snd_usb_get_host_interface() helper 2020-11-23 15:13:47 +01:00
implicit.c ALSA: usb-audio: Always initialize fixed_rate in snd_usb_find_implicit_fb_sync_format() 2023-01-18 11:58:09 +01:00
implicit.h ALSA: usb-audio: Add new quirk FIXED_RATE for JBL Quantum810 Wireless 2023-01-07 11:11:43 +01:00
Kconfig sound: usb: Add snapshot of USB QMI SND drivers 2022-12-07 19:02:13 -08:00
Makefile sound: usb: Add snapshot of USB QMI SND drivers 2022-12-07 19:02:13 -08:00
media.c ALSA: usb-audio: fix spelling mistakes 2021-07-05 19:33:54 +02:00
media.h media: sound/usb: Use Media Controller API to share media resources 2019-04-22 11:21:06 -04:00
midi.c ALSA: usb-audio: Drop snd_BUG_ON() from snd_usbmidi_output_open() 2022-11-12 15:13:01 +01:00
midi.h ALSA: usb-audio: generate midi streaming substream names from jack names 2021-03-01 09:21:54 +01:00
mixer_maps.c ALSA: usb-audio: More comprehensive mixer map for ASUS ROG Zenith II 2022-08-09 13:28:41 +02:00
mixer_quirks.c ALSA: scarlett2: Add Focusrite Clarett+ 8Pre support 2022-08-09 09:24:38 +02:00
mixer_quirks.h ALSA: usb-audio: Drop CONFIG_PM ifdefs 2021-12-06 10:19:40 +01:00
mixer_s1810c.c ALSA: usb-audio: remove redundant assignment to variable c 2022-02-08 08:21:32 +01:00
mixer_s1810c.h ALSA: usb-audio: Add support for Presonus Studio 1810c 2020-02-15 09:46:16 +01:00
mixer_scarlett_gen2.c ALSA: scarlett2: Add Focusrite Clarett+ 8Pre support 2022-08-09 09:24:38 +02:00
mixer_scarlett_gen2.h ALSA: usb-audio: scarlett2: Improve driver startup messages 2021-05-21 16:22:52 +02:00
mixer_scarlett.c ALSA: usb-audio: fix spelling mistakes 2021-07-05 19:33:54 +02:00
mixer_scarlett.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
mixer_us16x08.c ALSA: usb-audio: US16x08: Move overflow check before array access 2022-06-13 07:40:08 +02:00
mixer_us16x08.h ALSA: usb: Constify snd_kcontrol_new items 2020-01-03 09:24:34 +01:00
mixer.c ALSA: usb-audio: Use snd_ctl_rename() to rename a control 2022-10-21 08:17:08 +02:00
mixer.h ALSA: usb-audio: Drop CONFIG_PM ifdefs 2021-12-06 10:19:40 +01:00
pcm.c ANDROID: Snap to android14-6.1-2023-06 2023-08-08 17:02:27 -07:00
pcm.h ALSA: usb-audio: Add new quirk FIXED_RATE for JBL Quantum810 Wireless 2023-01-07 11:11:43 +01:00
power.c ANDROID: sound: usb: Export symbols for endpoint management 2023-03-22 02:29:10 +00:00
power.h ALSA: usb-audio: Drop CONFIG_PM ifdefs 2021-12-06 10:19:40 +01:00
proc.c ALSA: usb-audio: Show sync endpoint information in proc outputs 2020-11-23 15:16:45 +01:00
proc.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
quirks-table.h ALSA: usb-audio: add the quirk for KT0206 device 2022-12-31 13:33:09 +01:00
quirks.c ALSA: usb-audio: Add FIXED_RATE quirk for JBL Quantum610 Wireless 2023-02-22 12:59:41 +01:00
quirks.h ALSA: usb-audio: Register card at the last interface 2022-09-06 11:04:56 +02:00
stream.c ANDROID: Snap to android14-6.1-2023-06 2023-08-08 17:02:27 -07:00
stream.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
usb_audio_qmi_svc.c sound: usb: qmi: Prevent Null pointer deference due to connect/disconnect 2023-09-28 12:12:05 +05:30
usb_audio_qmi_v01.c sound: usb: Add snapshot of USB QMI SND drivers 2022-12-07 19:02:13 -08:00
usb_audio_qmi_v01.h sound: usb: Add snapshot of USB QMI SND drivers 2022-12-07 19:02:13 -08:00
usbaudio.h ANDROID: Snap to android14-6.1-2023-06 2023-08-08 17:02:27 -07:00
validate.c ALSA: usb-audio: Fix endianess in descriptor validation 2020-02-01 09:06:11 +01:00
xhci-sec.c sound: usb: Add snapshot of USB QMI SND drivers 2022-12-07 19:02:13 -08:00