From: Takashi Iwai <tiwai@suse.de>
To: Cristian Ciocaltea <cristian.ciocaltea@collabora.com>
Cc: Takashi Iwai <tiwai@suse.de>, linux-sound@vger.kernel.org
Subject: Re: [PATCH] ALSA: usb-audio: Fix build with CONFIG_INPUT=n
Date: Fri, 13 Jun 2025 11:53:00 +0200 [thread overview]
Message-ID: <8734c4rmrn.wl-tiwai@suse.de> (raw)
In-Reply-To: <ef20f7e8-9d78-44df-9ee4-841e7634460e@collabora.com>
On Fri, 13 Jun 2025 11:37:38 +0200,
Cristian Ciocaltea wrote:
>
> Hi Takashi,
>
> On 6/13/25 11:15 AM, Takashi Iwai wrote:
> > The recent addition of DualSense mixer quirk relies on the input
> > device handle, and the build can fail if CONFIG_INPUT isn't set.
> > Put (rather ugly) workarounds to wrap with IS_REACHABLE() for avoiding
> > the build error.
> >
> > Fixes: 79d561c4ec04 ("ALSA: usb-audio: Add mixer quirk for Sony DualSense PS5")
> > Reported-by: kernel test robot <lkp@intel.com>
> > Closes: https://lore.kernel.org/oe-kbuild-all/202506130733.gnPKw2l3-lkp@intel.com/
> > Signed-off-by: Takashi Iwai <tiwai@suse.de>
> > ---
> > sound/usb/mixer_quirks.c | 4 ++++
> > 1 file changed, 4 insertions(+)
> >
> > diff --git a/sound/usb/mixer_quirks.c b/sound/usb/mixer_quirks.c
> > index a0ffe8b559dc..7cc27ae5512f 100644
> > --- a/sound/usb/mixer_quirks.c
> > +++ b/sound/usb/mixer_quirks.c
> > @@ -532,6 +532,7 @@ static int snd_emu0204_controls_create(struct usb_mixer_interface *mixer)
> > &snd_emu0204_control, NULL);
> > }
> >
> > +#if IS_REACHABLE(CONFIG_INPUT)
> > /*
> > * Sony DualSense controller (PS5) jack detection
> > *
> > @@ -788,6 +789,7 @@ static int snd_dualsense_controls_create(struct usb_mixer_interface *mixer)
> >
> > return snd_dualsense_jack_create(mixer, "Headset Mic Jack", false);
> > }
> > +#endif /* IS_REACHABLE(CONFIG_INPUT) */
> >
> > /* ASUS Xonar U1 / U3 controls */
> >
> > @@ -4331,10 +4333,12 @@ int snd_usb_mixer_apply_create_quirk(struct usb_mixer_interface *mixer)
> > err = snd_emu0204_controls_create(mixer);
> > break;
> >
> > +#if IS_REACHABLE(CONFIG_INPUT)
> > case USB_ID(0x054c, 0x0ce6): /* Sony DualSense controller (PS5) */
> > case USB_ID(0x054c, 0x0df2): /* Sony DualSense Edge controller (PS5) */
> > err = snd_dualsense_controls_create(mixer);
> > break;
> > +#endif /* IS_REACHABLE(CONFIG_INPUT) */
> >
> > case USB_ID(0x0763, 0x2030): /* M-Audio Fast Track C400 */
> > case USB_ID(0x0763, 0x2031): /* M-Audio Fast Track C400 */
>
> I've seen the build issue report earlier today and planned to
> investigate, but you beat me to it, so thanks for the quick fix!
>
> I reproduced the linker errors on a minimal kernel configuration with
> CONFIG_INPUT not being set and I confirm the build passes after applying
> the patch.
>
> Reviewed-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com>
Thanks for confirmation. Now queued.
Takashi
prev parent reply other threads:[~2025-06-13 9:53 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-13 8:15 [PATCH] ALSA: usb-audio: Fix build with CONFIG_INPUT=n Takashi Iwai
2025-06-13 9:37 ` Cristian Ciocaltea
2025-06-13 9:53 ` Takashi Iwai [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8734c4rmrn.wl-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=cristian.ciocaltea@collabora.com \
--cc=linux-sound@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.