lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 15 Jan 2015 17:47:07 -0600
From:	Chris Rorvick <chris@...vick.com>
To:	Oliver Neukum <oneukum@...e.de>
Cc:	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	linux-usb@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] usb: Fix typo in `struct usb_host_interface' comment

On Thu, Jan 15, 2015 at 6:54 AM, Chris Rorvick <chris@...vick.com> wrote:
> On Thu, Jan 15, 2015 at 5:03 AM, Oliver Neukum <oneukum@...e.de> wrote:
>> On Wed, 2015-01-14 at 21:52 -0600, Chris Rorvick wrote:
>>> The descriptor member `bNumEndpoints' is plural.
>>
>> I am afraid that is not a good idea. The name of a
>> member of a structure mentioned in the specification should
>> appear as it is used in the specification.
>
> Where is it not plural in the specification?

I think understand your comment now so I will respond more specifically:
This is a typo precisely because `bNumEndpoint' is not consistent with
the specification, nor is it consistent with the definition of `struct
usb_interface_descriptor'.  The specification and the structure both use
`bNumEndpoints'.

Fixing this has utility because `struct usb_interface_descriptor' is not
defined in <linux/usb.h>.  So, if corrected, the code for determining
the number of endpoints is readily available to anyone looking at
`struct usb_host_interface' without tracking down the uapi header.

Mentioning that the descriptor member/field is plural was just an
attempt to make it easy to see what changed.

Regards,

Chris
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ