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]
Message-ID: <20191204123815.GC29179@duo.ucw.cz>
Date:   Wed, 4 Dec 2019 13:38:15 +0100
From:   Pavel Machek <pavel@...x.de>
To:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc:     linux-kernel@...r.kernel.org, stable@...r.kernel.org,
        Huazhong Tan <tanhuazhong@...wei.com>,
        "David S. Miller" <davem@...emloft.net>,
        Sasha Levin <sashal@...nel.org>
Subject: Re: [PATCH 4.19 187/306] net: hns3: bugfix for
 is_valid_csq_clean_head()

Hi!

> From: Huazhong Tan <tanhuazhong@...wei.com>
> 
> [ Upstream commit 6d71ec6cbf74ac9c2823ef751b1baa5b889bb3ac ]
> 
> The HEAD pointer of the hardware command queue maybe equal to the command
> queue's next_to_use in the driver, so that does not belong to the invalid
> HEAD pointer, since the hardware may not process the command in time,
> causing the HEAD pointer to be too late to update. The variables' name
> in this function is unreadable, so give them a more readable one.
> 

> +++ b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.c
> @@ -24,15 +24,15 @@ static int hclge_ring_space(struct hclge_cmq_ring *ring)
>  	return ring->desc_num - used - 1;
>  }
>  
> -static int is_valid_csq_clean_head(struct hclge_cmq_ring *ring, int h)
> +static int is_valid_csq_clean_head(struct hclge_cmq_ring *ring, int head)
>  {
...
> -	if (unlikely(h >= ring->desc_num))
> -		return 0;

This sanity check was removed, and it is not mentioned in the
changelog. Is it intended?

Best regards,
							Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

Download attachment "signature.asc" of type "application/pgp-signature" (196 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ