[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <s5hh8jy5kia.wl-tiwai@suse.de>
Date: Mon, 13 Aug 2018 17:55:25 +0200
From: Takashi Iwai <tiwai@...e.de>
To: "Dmitry V. Levin" <ldv@...linux.org>
Cc: Jorge Sanjuan <jorge.sanjuan@...ethink.co.uk>,
Ruslan Bilovol <ruslan.bilovol@...il.com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] uapi: fix linux/usb/audio.h userspace compilation error
On Mon, 13 Aug 2018 17:46:51 +0200,
Dmitry V. Levin wrote:
>
> Replace NULL with 0 in uac_mixer_unit_bmControls() to fix the following
> linux/usb/audio.h userspace compilation error:
>
> /usr/include/linux/usb/audio.h: In function 'uac_mixer_unit_bmControls':
> /usr/include/linux/usb/audio.h:304:10: error: 'NULL' undeclared (first use in this function)
> return NULL;
>
> Fixes: 6cfd839ae78e ("ALSA: usb-audio: UAC3. Add support for mixer unit.")
> Cc: <stable@...r.kernel.org> # v4.18
> Signed-off-by: Dmitry V. Levin <ldv@...linux.org>
Hrm, can we include the standard header for definition of NULL
instead? It's way too ugly to use 0 just for that.
thanks,
Takashi
> ---
> include/uapi/linux/usb/audio.h | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/include/uapi/linux/usb/audio.h b/include/uapi/linux/usb/audio.h
> index 74e520fb944f..2b61fe34b2ca 100644
> --- a/include/uapi/linux/usb/audio.h
> +++ b/include/uapi/linux/usb/audio.h
> @@ -301,7 +301,7 @@ static inline __u8 *uac_mixer_unit_bmControls(struct uac_mixer_unit_descriptor *
> case UAC_VERSION_3:
> return &desc->baSourceID[desc->bNrInPins + 2];
> default:
> - return NULL;
> + return 0;
> }
> }
>
> --
> ldv
>
Powered by blists - more mailing lists