]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
ALSA: usb-audio: us144mkii: Implement audio capture and decoding
authorŠerif Rami <ramiserifpersia@gmail.com>
Thu, 14 Aug 2025 17:22:19 +0000 (19:22 +0200)
committerTakashi Iwai <tiwai@suse.de>
Fri, 15 Aug 2025 15:53:47 +0000 (17:53 +0200)
commitc1bb0c13e430623c26543baae5bb9ae21139db87
treee02328bee29a2fc84ede5f24a7f9a782fe2cb86b
parenta2a2210f2c2e65a39631e4be727f1f9cc155171a
ALSA: usb-audio: us144mkii: Implement audio capture and decoding

This patch adds the full audio capture data path. It allocates and
manages bulk URBs to receive audio data from the device.

The incoming data is in a custom multiplexed format. A workqueue is
used to offload the decoding process from the interrupt context. The
`capture_urb_complete` handler copies raw data into a ring buffer and
schedules the work. The `tascam_capture_work_handler` then reads from
this buffer, decodes the data into standard S32_LE samples, and copies
it to the ALSA capture buffer.

The PCM trigger is updated to manage the submission of capture URBs,
and the feedback handler now also advances the capture stream pointer
to keep it synchronized with playback.

Signed-off-by: Šerif Rami <ramiserifpersia@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Link: https://patch.msgid.link/20250814172222.9448-5-ramiserifpersia@gmail.com
sound/usb/usx2y/us144mkii.c
sound/usb/usx2y/us144mkii.h
sound/usb/usx2y/us144mkii_capture.c
sound/usb/usx2y/us144mkii_pcm.c
sound/usb/usx2y/us144mkii_pcm.h