From: Greg KH <gregkh@linuxfoundation.org>
To: Oliver Neukum <oneukum@suse.com>
Cc: linux-usb@vger.kernel.org
Subject: Re: [PATCH 1/1] uapi: cdc.h: cleanly provide for more interfaces and countries
Date: Tue, 28 Oct 2025 14:32:44 +0100 [thread overview]
Message-ID: <2025102858-doorframe-canola-e6c0@gregkh> (raw)
In-Reply-To: <20251028123254.1888303-1-oneukum@suse.com>
On Tue, Oct 28, 2025 at 01:32:22PM +0100, Oliver Neukum wrote:
> The spec requires at least one interface respectively country.
> It allows multiple ones. This needs to be clearly said in the UAPI.
>
> Signed-off-by: Oliver Neukum <oneukum@suse.com>
> ---
> include/uapi/linux/usb/cdc.h | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/include/uapi/linux/usb/cdc.h b/include/uapi/linux/usb/cdc.h
> index 1924cf665448..5fcbce0be133 100644
> --- a/include/uapi/linux/usb/cdc.h
> +++ b/include/uapi/linux/usb/cdc.h
> @@ -105,7 +105,7 @@ struct usb_cdc_union_desc {
>
> __u8 bMasterInterface0;
> __u8 bSlaveInterface0;
> - /* ... and there could be other slave interfaces */
> + __u8 bSlaveInterfaces[];
Can this be combined with bSlaveInterface0? Feels odd to have 0 and
then "more".
Also, what determines how many, the overall length?
> } __attribute__ ((packed));
>
> /* "Country Selection Functional Descriptor" from CDC spec 5.2.3.9 */
> @@ -116,7 +116,7 @@ struct usb_cdc_country_functional_desc {
>
> __u8 iCountryCodeRelDate;
> __le16 wCountyCode0;
> - /* ... and there can be a lot of country codes */
> + __le16 wCountyCodes[];
same here.
thanks,
greg k-h
next prev parent reply other threads:[~2025-10-28 13:41 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-28 12:32 [PATCH 1/1] uapi: cdc.h: cleanly provide for more interfaces and countries Oliver Neukum
2025-10-28 13:32 ` Greg KH [this message]
2025-10-28 14:34 ` Oliver Neukum
2025-10-28 14:40 ` Greg KH
2025-10-28 16:43 ` Gustavo A. R. Silva
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=2025102858-doorframe-canola-e6c0@gregkh \
--to=gregkh@linuxfoundation.org \
--cc=linux-usb@vger.kernel.org \
--cc=oneukum@suse.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox