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] [day] [month] [year] [list]
Date:   Tue, 17 Aug 2021 07:10:29 +0000
From:   Chunfeng Yun (云春峰) 
        <Chunfeng.Yun@...iatek.com>
To:     "balbi@...nel.org" <balbi@...nel.org>,
        "pawell@...ence.com" <pawell@...ence.com>
CC:     "rikard.falkeborn@...il.com" <rikard.falkeborn@...il.com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "jonathanh@...dia.com" <jonathanh@...dia.com>,
        "linux-usb@...r.kernel.org" <linux-usb@...r.kernel.org>,
        "bcm-kernel-feedback-list@...adcom.com" 
        <bcm-kernel-feedback-list@...adcom.com>,
        "linux-mediatek@...ts.infradead.org" 
        <linux-mediatek@...ts.infradead.org>,
        Eddie Hung (洪正鑫) 
        <Eddie.Hung@...iatek.com>,
        "thierry.reding@...il.com" <thierry.reding@...il.com>,
        "alcooperx@...il.com" <alcooperx@...il.com>,
        "gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
        "linux-arm-kernel@...ts.infradead.org" 
        <linux-arm-kernel@...ts.infradead.org>,
        "matthias.bgg@...il.com" <matthias.bgg@...il.com>,
        "christophe.jaillet@...adoo.fr" <christophe.jaillet@...adoo.fr>,
        "linux-tegra@...r.kernel.org" <linux-tegra@...r.kernel.org>,
        "yangyingliang@...wei.com" <yangyingliang@...wei.com>
Subject: Re: [PATCH 3/6] usb: cdnsp: fix the wrong mult value for HS isoc or
 intr

On Tue, 2021-08-17 at 05:05 +0000, Pawel Laszczak wrote:
> > 
> > Chunfeng Yun <chunfeng.yun@...iatek.com> writes:
> > 
> > > usb_endpoint_maxp() only returns the bit[10:0] of wMaxPacketSize
> > > of endpoint descriptor, not include bit[12:11] anymore, so use
> > > usb_endpoint_maxp_mult() instead.
> > > 
> > > Signed-off-by: Chunfeng Yun <chunfeng.yun@...iatek.com>
> > > ---
> > >  drivers/usb/cdns3/cdnsp-mem.c | 2 +-
> > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > > 
> > > diff --git a/drivers/usb/cdns3/cdnsp-mem.c
> > > b/drivers/usb/cdns3/cdnsp-mem.c
> > > index a47948a1623f..ad9aee3f1e39 100644
> > > --- a/drivers/usb/cdns3/cdnsp-mem.c
> > > +++ b/drivers/usb/cdns3/cdnsp-mem.c
> > > @@ -882,7 +882,7 @@ static u32
> > > cdnsp_get_endpoint_max_burst(struct usb_gadget *g,
> > >  	if (g->speed == USB_SPEED_HIGH &&
> > >  	    (usb_endpoint_xfer_isoc(pep->endpoint.desc) ||
> > >  	     usb_endpoint_xfer_int(pep->endpoint.desc)))
> > > -		return (usb_endpoint_maxp(pep->endpoint.desc) & 0x1800)
> > > >> 11;
> > > +		return usb_endpoint_maxp_mult(pep->endpoint.desc) - 1;
> > 
> > this looks like a bugfix. Do we need to Cc stable here?
> > 
> > In any case:
> > 
> > Acked-by: Felipe Balbi <balbi@...nel.org>
> > 
> 
> It's not a bugfix. The result is the same.

"(usb_endpoint_maxp(pep->endpoint.desc) & 0x1800) >> 11" is always zero
now!
but not for "usb_endpoint_maxp_mult(pep->endpoint.desc) - 1".

> 
> Acked-by: Pawel Laszczak <pawell@...ence.com>
> 
> --
> 
> Thanks 
> Pawel Laszczak

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ