USB audio refactoring for better implicit feedback support
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest41 patches 10 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/41 | ALSA: usb-audio: Handle discrete rates properly in hw constraintssound/ sound/ sound/ | +15 | 0 replies | |
| 2/41 | ALSA: usb-audio: Don't call usb_set_interface() at trigger callbacksound/ | +13 | 0 replies | |
| 3/41 | ALSA: usb-audio: Check valid altsetting at parsing rates for UAC2/3sound/ sound/ sound/ | +158 | 0 replies | |
| 4/41 | ALSA: usb-audio: Check implicit feedback EP generically for UAC2sound/ | +66 | 0 replies | |
| 5/41 | ALSA: usb-audio: Add snd_usb_get_endpoint() helpersound/ sound/ | +31 | 0 replies | |
| 6/41 | ALSA: usb-audio: Set and clear sync EP link properlysound/ | +11 | 0 replies | |
| 7/41 | ALSA: usb-audio: Improve some debug printssound/ sound/ | +12 | 0 replies | |
| 8/41 | ALSA: usb-audio: Track implicit fb sync endpoint in audioformat listsound/ sound/ sound/ +1 more | +100 | 0 replies | |
| 9/41 | ALSA: usb-audio: Move snd_usb_autoresume() call out of setup_hw_info()sound/ | +9 | 0 replies | |
| 10/41 | ALSA: usb-audio: Add hw constraint for implicit fb syncsound/ sound/ sound/ | +175 | 0 replies | |
| 11/41 | ALSA: usb-audio: Simplify hw_params rulessound/ | +38 | 0 replies | |
| 12/41 | ALSA: usb-audio: Drop debug.hsound/ sound/ sound/ +1 more | +13 | 0 replies | |
| 13/41 | ALSA: usb-audio: Avoid doubly initialization for implicit fbsound/ | +20 | 0 replies | |
| 14/41 | ALSA: usb-audio: Create endpoint objects at parsing phasesound/ sound/ sound/ +1 more | +67 | 9 replies | |
| 15/41 | ALSA: usb-audio: Drop keep_interface flag againsound/ sound/ sound/ | +7 | 0 replies | |
| 16/41 | ALSA: usb-audio: Add snd_usb_get_host_interface() helpersound/ sound/ sound/ | +24 | 0 replies | |
| 17/41 | ALSA: usb-audio: Don't set altsetting before initializing sample ratesound/ | +2 | 0 replies | |
| 18/41 | ALSA: usb-audio: Pass snd_usb_audio object to quirk functionssound/ sound/ sound/ +1 more | +17 | 0 replies | |
| 19/41 | ALSA: usb-audio: Simplify snd_usb_init_sample_rate() argumentssound/ sound/ sound/ +2 more | +18 | 0 replies | |
| 20/41 | ALSA: usb-audio: Simplify snd_usb_init_pitch() argumentssound/ sound/ sound/ +1 more | +12 | 0 replies | |
| 21/41 | ALSA: usb-audio: Stop both endpoints properly at errorsound/ sound/ | +23 | 0 replies | |
| 22/41 | ALSA: usb-audio: Set callbacks via snd_usb_endpoint_set_callback()sound/ sound/ sound/ | +66 | 0 replies | |
| 23/41 | ALSA: usb-audio: Always set up the parameters after resumesound/ sound/ sound/ +1 more | +6 | 0 replies | |
| 24/41 | ALSA: usb-audio: Fix EP matching for continuous ratessound/ | +13 | 0 replies | |
| 25/41 | ALSA: usb-audio: Refactor endpoint managementsound/ sound/ sound/ +3 more | +616 | 0 replies | |
| 26/41 | ALSA: usb-audio: Fix possible stall of implicit fb packet ring-buffersound/ sound/ | +63 | 0 replies | |
| 27/41 | ALSA: usb-audio: Constify audioformat pointer referencessound/ sound/ sound/ +6 more | +39 | 0 replies | |
| 28/41 | ALSA: usb-audio: Use atomic_t for endpoint use_countsound/ sound/ | +15 | 0 replies | |
| 29/41 | ALSA: usb-audio: Refactoring endpoint URB deactivationsound/ | +23 | 0 replies | |
| 30/41 | ALSA: usb-audio: Drop unneeded snd_usb_substream fieldssound/ sound/ sound/ +2 more | +24 | 0 replies | |
| 31/41 | ALSA: usb-audio: Unify the code for the next packet size calculationsound/ sound/ sound/ | +27 | 0 replies | |
| 32/41 | ALSA: usb-audio: Simplify rate_min/max and rates set upsound/ | +24 | 0 replies | |
| 33/41 | ALSA: usb-audio: Replace slave/master termssound/ sound/ | +16 | 0 replies | |
| 34/41 | ALSA: usb-audio: Use unsigned char for iface and altsettings fieldssound/ sound/ | +8 | 0 replies | |
| 35/41 | ALSA: usb-audio: Show sync endpoint information in proc outputssound/ | +15 | 0 replies | |
| 36/41 | ALSA: usb-audio: Quirk for BOSS GT-001sound/ | +31 | 0 replies | |
| 37/41 | ALSA: usb-audio: Factor out the implicit feedback quirk codesound/ sound/ sound/ +1 more | +376 | 0 replies | |
| 38/41 | ALSA: usb-audio: Add generic implicit fb parsingsound/ | +54 | 0 replies | |
| 39/41 | ALSA: usb-audio: Add implicit_fb module optionDocumentation/ sound/ sound/ +1 more | +14 | 1 reply | |
| 40/41 | ALSA: usb-audio: Fix quirks for other BOSS devicessound/ | +6 | 0 replies | |
| 41/41 | ALSA: usb-audio: Fix MOTU M-Series quirkssound/ sound/ | +0 | 0 replies |
Reviews trailers per patch
None of the 41 patches has a Reviewed-by or Acked-by.
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH 00/41] USB audio refactoring for better implicit feedback support
Hi,
here is a largish patch set for USB-audio. Its main goal is to address the long-standing issues wrt the implicit feedback mode. With the current driver, when the implicit fb is used, the full duplex doesn't work properly unless you start both streams *very* carefully. This patch set tries to ease such the configuration mismatch and fix many other bugs.
In short, with this patch set applied, USB-audio driver will try to restrict the hw_params to match with the already opened counter-part stream automatically. So individual aplay and arecord invocation should work now, as well as PulseAudio.
Also, the patch set includes more fixes, e.g. the generic detection of the implicit feedback mode on UAC2/3, and the fix for the sample rate selection on UAC2/3, as well as a few more quirks to follow the new implicit fb model.
The latest patches are available in topic/usb-audio-refactoring branch.
I specially thank Keith Milner and Dylan Robinson for their time spent for lots of testing. Without their patient help, I couldn't finish those patches, as I myself don't own such devices.
Takashi
===
Dylan Robinson (1):
ALSA: usb-audio: Fix MOTU M-Series quirks
Takashi Iwai (40):
ALSA: usb-audio: Handle discrete rates properly in hw constraints
ALSA: usb-audio: Don't call usb_set_interface() at trigger callback
ALSA: usb-audio: Check valid altsetting at parsing rates for UAC2/3
ALSA: usb-audio: Check implicit feedback EP generically for UAC2
ALSA: usb-audio: Add snd_usb_get_endpoint() helper
ALSA: usb-audio: Set and clear sync EP link properly
ALSA: usb-audio: Improve some debug prints
ALSA: usb-audio: Track implicit fb sync endpoint in audioformat list
ALSA: usb-audio: Move snd_usb_autoresume() call out of setup_hw_info()
ALSA: usb-audio: Add hw constraint for implicit fb sync
ALSA: usb-audio: Simplify hw_params rules
ALSA: usb-audio: Drop debug.h
ALSA: usb-audio: Avoid doubly initialization for implicit fb
ALSA: usb-audio: Create endpoint objects at parsing phase
ALSA: usb-audio: Drop keep_interface flag again
ALSA: usb-audio: Add snd_usb_get_host_interface() helper
ALSA: usb-audio: Don't set altsetting before initializing sample rate
ALSA: usb-audio: Pass snd_usb_audio object to quirk functions
ALSA: usb-audio: Simplify snd_usb_init_sample_rate() arguments
ALSA: usb-audio: Simplify snd_usb_init_pitch() arguments
ALSA: usb-audio: Stop both endpoints properly at error
ALSA: usb-audio: Set callbacks via snd_usb_endpoint_set_callback()
ALSA: usb-audio: Always set up the parameters after resume
ALSA: usb-audio: Fix EP matching for continuous rates
ALSA: usb-audio: Refactor endpoint management
ALSA: usb-audio: Fix possible stall of implicit fb packet ring-buffer
ALSA: usb-audio: Constify audioformat pointer references
ALSA: usb-audio: Use atomic_t for endpoint use_count
ALSA: usb-audio: Refactoring endpoint URB deactivation
ALSA: usb-audio: Drop unneeded snd_usb_substream fields
ALSA: usb-audio: Unify the code for the next packet size calculation
ALSA: usb-audio: Simplify rate_min/max and rates set up
ALSA: usb-audio: Replace slave/master terms
ALSA: usb-audio: Use unsigned char for iface and altsettings fields
ALSA: usb-audio: Show sync endpoint information in proc outputs
ALSA: usb-audio: Quirk for BOSS GT-001
ALSA: usb-audio: Factor out the implicit feedback quirk code
ALSA: usb-audio: Add generic implicit fb parsing
ALSA: usb-audio: Add implicit_fb module option
ALSA: usb-audio: Fix quirks for other BOSS devices
Documentation/sound/alsa-configuration.rst | 5 + sound/usb/Makefile | 1 + sound/usb/card.c | 14 +- sound/usb/card.h | 53 +- sound/usb/clock.c | 152 ++-- sound/usb/clock.h | 11 +- sound/usb/debug.h | 16 - sound/usb/endpoint.c | 943 +++++++++++++---------- sound/usb/endpoint.h | 57 +- sound/usb/format.c | 125 +++- sound/usb/helper.c | 10 + sound/usb/helper.h | 3 + sound/usb/implicit.c | 402 ++++++++++ sound/usb/implicit.h | 14 + sound/usb/mixer.c | 46 -- sound/usb/pcm.c | 1117 ++++++++++------------------ sound/usb/pcm.h | 7 +- sound/usb/proc.c | 35 +- sound/usb/quirks-table.h | 8 - sound/usb/quirks.c | 60 +- sound/usb/quirks.h | 10 +- sound/usb/stream.c | 24 +- sound/usb/usbaudio.h | 5 +- 23 files changed, 1696 insertions(+), 1422 deletions(-) delete mode 100644 sound/usb/debug.h create mode 100644 sound/usb/implicit.c create mode 100644 sound/usb/implicit.h
Signature · 1 line
2.16.4