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: <20111201.125504.1641339242050833778.davem@davemloft.net>
Date:	Thu, 01 Dec 2011 12:55:04 -0500 (EST)
From:	David Miller <davem@...emloft.net>
To:	patrick.kelle81@...il.com
Cc:	netdev@...r.kernel.org, romieu@...zoreil.com, sorbica@...lus.com.tw
Subject: Re: [PATCH v2] icplus: mdio_write(), remove unnecessary for loop

From: Patrick Kelle <patrick.kelle81@...il.com>
Date: Thu,  1 Dec 2011 14:26:56 +0100

> At this point the variable j is always set to 7 and the code within
> the loop has to run only once anyway.
> 
> As suggested by David Miller:
> "You can simply this even further since p[7] is what is used here,
> and this means len is one, the inner loop therefore executes only
> once, and the p[7].field value is not used (it's zero in the table)
> and the write to it is completely thrown away."
> 
> Signed-off-by: Patrick Kelle <patrick.kelle81@...il.com>

Applied.
--
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