Re: [PATCH] ALSA: usb-audio: add Pioneer DJ DDJ-SZ support

From: Takashi Iwai

Date: Mon Sep 07 2026 - 04:07:43 EST


On Sat, 05 Sep 2026 08:19:37 +0200,
Geraldo Nascimento wrote:
>
> On Sat, Sep 5, 2026 at 2:35 AM Hanh Kieu <hhkieu@xxxxxxxxx> wrote:
> >
> > Hi Geraldo,
> >
> > I looked further into the is_pioneer_implicit_fb() check you pointed out.
> >
> > It seems the DATA case is intentional. In the original Pioneer DJM-900NXS2 work, Fabian Lesniak described the observed behavior as:
> >
> > “the playback streams also tries to start the capture endpoint as sync source.”
> >
> > https://gist.github.com/flesniak/074ab23bbc833663b782f44174eae6a4
> >
> > Takashi Iwai later formalized this in the Pioneer implicit-feedback handling, explicitly accepting either USB_ENDPOINT_USAGE_DATA or USB_ENDPOINT_USAGE_IMPLICIT_FB for the secondary IN endpoint before passing it to add_implicit_fb_sync_ep():
> >
> > https://github.com/torvalds/linux/commit/167c9dc84ec384c0940359e067301883ad2b42a8
> >
>
> Every other Pioneer device has that USB_ENDPOINT_USAGE_IMPLICIT_FB
> on the IN endpoint. Yours would be the first without it in the IN
> endpoint. Unless
> your hardware doesn't rely on implicit feedback for syncing then there's a good
> chance that implicit.c short-circuiting and still picking up implicit
> feedback for you
> isn't correct, but what you need to do is cool down now and wait for proper
> maintainer response which takes time.

Accepting both DATA and IMPLICIT_FB usages is intentional, yes.
But I don't follow what's the problem there -- in this case, the
bmAttributes of the secondary EP shows it's DATA, no? Then this check
must pass.

The condition is:

if (!usb_endpoint_is_isoc_in(epd) ||
(epd->bmAttributes & USB_ENDPOINT_SYNCTYPE) != USB_ENDPOINT_SYNC_ASYNC ||
((epd->bmAttributes & USB_ENDPOINT_USAGE_MASK) !=
USB_ENDPOINT_USAGE_DATA &&
(epd->bmAttributes & USB_ENDPOINT_USAGE_MASK) !=
USB_ENDPOINT_USAGE_IMPLICIT_FB))
return false;

return false;

... and maybe it's better to be rewritten like:

sync = (epd->bmAttributes & USB_ENDPOINT_SYNCTYPE);
usage = (epd->bmAttributes & USB_ENDPOINT_USAGE_MASK);

if (usb_endpoint_is_isoc_in(epd) &&
sync == USB_ENDPOINT_SYNC_ASYNC &&
(usage == USB_ENDPOINT_USAGE_DATA ||
usage == USB_ENDPOINT_USAGE_IMPLICIT_FB))
return true;

return false;

So it should return true.
Please double-check which test actually fails.


thanks,

Takashi