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]
Message-ID: <Pine.LNX.4.44L0.1705021424520.1758-100000@iolanthe.rowland.org>
Date:   Tue, 2 May 2017 14:25:28 -0400 (EDT)
From:   Alan Stern <stern@...land.harvard.edu>
To:     "Gustavo A. R. Silva" <garsilva@...eddedor.com>
cc:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        <linux-usb@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] usb: host: remove unnecessary null check

On Tue, 2 May 2017, Gustavo A. R. Silva wrote:

> Remove unnecessary null check. udev->tt cannot ever be NULL when this
> section of code runs.
> 
> Addresses-Coverity-ID: 100828
> Cc: Alan Stern <stern@...land.harvard.edu>
> Signed-off-by: Gustavo A. R. Silva <garsilva@...eddedor.com>
> ---
>  drivers/usb/host/ehci-sched.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/usb/host/ehci-sched.c b/drivers/usb/host/ehci-sched.c
> index 980a6b3..6bc6304 100644
> --- a/drivers/usb/host/ehci-sched.c
> +++ b/drivers/usb/host/ehci-sched.c
> @@ -1105,7 +1105,7 @@ iso_stream_init(
>  		addr |= epnum << 8;
>  		addr |= dev->devnum;
>  		stream->ps.usecs = HS_USECS_ISO(maxp);
> -		think_time = dev->tt ? dev->tt->think_time : 0;
> +		think_time = dev->tt->think_time;
>  		stream->ps.tt_usecs = NS_TO_US(think_time + usb_calc_bus_time(
>  				dev->speed, is_input, 1, maxp));
>  		hs_transfers = max(1u, (maxp + 187) / 188);

Acked-by: Alan Stern <stern@...land.harvard.edu>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ