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:   Sun, 21 Jul 2019 13:54:35 -0700
From:   Joe Perches <joe@...ches.com>
To:     Alan Stern <stern@...land.harvard.edu>
Cc:     Pawel Laszczak <pawell@...ence.com>, felipe.balbi@...ux.intel.com,
        gregkh@...uxfoundation.org, linux-usb@...r.kernel.org,
        rogerq@...com, linux-kernel@...r.kernel.org, jbergsagel@...com,
        nsekhar@...com, nm@...com, sureshp@...ence.com, jpawar@...ence.com,
        kurahul@...ence.com, aniljoy@...ence.com
Subject: Re: [PATCH v10 2/6] usb:common Separated decoding functions from
 dwc3 driver.

On Sun, 2019-07-21 at 16:45 -0400, Alan Stern wrote:
> On Sun, 21 Jul 2019, Joe Perches wrote:
> 
> > On Sun, 2019-07-21 at 19:32 +0100, Pawel Laszczak wrote:
> > > Patch moves some decoding functions from driver/usb/dwc3/debug.h driver
> > > to driver/usb/common/debug.c file. These moved functions include:
> > []
> > > diff --git a/drivers/usb/common/debug.c b/drivers/usb/common/debug.c
> > []
> > > +static void usb_decode_set_clear_feature(__u8 bRequestType, __u8 bRequest,
> > > +                                    __u16 wValue, __u16 wIndex,
> > > +                                    char *str, size_t size)
> > 
> > It's probably not necessary to use Hungarian
> > when moving these functions into generic code.
> 
> In fact, these are the well known and commonly accepted names for these
> data values, as given in the USB specification and used in many other
> places in the Linux USB stack.  See for example the definition of
> struct usb_ctrlrequest in include/uapi/linux/usb/ch9.h.
>
> Changing them here would only make the code less readable.

Perhaps, but these have already been converted from
the __le types, so perhaps not.  It might be more
sensible to convert the __u16 uses to u16 and avoid
the __le16 names.

cheers, Joe

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ