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:	Fri, 11 Sep 2009 16:33:52 -0700
From:	"Matt Carlson" <mcarlson@...adcom.com>
To:	"David Miller" <davem@...emloft.net>
cc:	"Matthew Carlson" <mcarlson@...adcom.com>,
	"Benjamin Li" <benli@...adcom.com>,
	"netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: Re: 5717 support commit is buggy

On Fri, Sep 11, 2009 at 03:15:54PM -0700, David Miller wrote:
> Also:
> 
> @@ -13486,7 +13556,8 @@ static void __devinit tg3_init_link_config(struct tg3 *tp)
>  
>  static void __devinit tg3_init_bufmgr_config(struct tg3 *tp)
>  {
> -	if (tp->tg3_flags2 & TG3_FLG2_5705_PLUS) {
> +	if (tp->tg3_flags2 & TG3_FLG2_5705_PLUS &&
> +	    GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5717) {
>  		tp->bufmgr_config.mbuf_read_dma_low_water =
>  			DEFAULT_MB_RDMA_LOW_WATER_5705;
>  		tp->bufmgr_config.mbuf_mac_rx_low_water =
> 
> I wonder what that does with C precedence rules.  Probably need
> parenhesis around "tp->tg3_flags2 & TG3_FLG2_5705_PLUS" for
> safety.

Harbison & Steele says '&' takes precedence over '&&'.  That said, I'm
not shy about adding parens to remove any doubt.

I'm brewing another patchset that contains a patch to address things
like this.  I'll add this to that patch.

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ