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:	Thu, 11 Feb 2016 00:36:44 +0300
From:	Sergei Shtylyov <sergei.shtylyov@...entembedded.com>
To:	Woojung.Huh@...rochip.com, davem@...emloft.net
Cc:	netdev@...r.kernel.org
Subject: Re: [PATCH net-next 1/3] lan78xx: replace devid to chipid & chiprev

On 02/11/2016 12:13 AM, Woojung.Huh@...rochip.com wrote:

> Replace devid to chipid & chiprev for easy access.
>
> Signed-off-by: Woojung Huh <woojung.huh@...rochip.com>
> ---
>   drivers/net/usb/lan78xx.c | 20 +++++++++++---------
>   drivers/net/usb/lan78xx.h |  1 +
>   2 files changed, 12 insertions(+), 9 deletions(-)
>
> diff --git a/drivers/net/usb/lan78xx.c b/drivers/net/usb/lan78xx.c
> index 1c299b8..b14b22d 100644
> --- a/drivers/net/usb/lan78xx.c
> +++ b/drivers/net/usb/lan78xx.c
[...]
> @@ -471,7 +472,7 @@ static int lan78xx_read_raw_eeprom(struct lan78xx_net *dev, u32 offset,
>   	 */
>   	ret = lan78xx_read_reg(dev, HW_CFG, &val);
>   	saved = val;
> -	if ((dev->devid & ID_REV_CHIP_ID_MASK_) == 0x78000000) {
> +	if ((dev->chipid) == ID_REV_CHIP_ID_7800_) {

    Inner parens not needed.

[...]
> @@ -505,7 +506,7 @@ static int lan78xx_read_raw_eeprom(struct lan78xx_net *dev, u32 offset,
>
>   	retval = 0;
>   exit:
> -	if ((dev->devid & ID_REV_CHIP_ID_MASK_) == 0x78000000)
> +	if ((dev->chipid) == ID_REV_CHIP_ID_7800_)

    Same here.

[...]
> @@ -539,7 +540,7 @@ static int lan78xx_write_raw_eeprom(struct lan78xx_net *dev, u32 offset,
>   	 */
>   	ret = lan78xx_read_reg(dev, HW_CFG, &val);
>   	saved = val;
> -	if ((dev->devid & ID_REV_CHIP_ID_MASK_) == 0x78000000) {
> +	if ((dev->chipid) == ID_REV_CHIP_ID_7800_) {

    And here.

[...]
> @@ -587,7 +588,7 @@ static int lan78xx_write_raw_eeprom(struct lan78xx_net *dev, u32 offset,
>
>   	retval = 0;
>   exit:
> -	if ((dev->devid & ID_REV_CHIP_ID_MASK_) == 0x78000000)
> +	if ((dev->chipid) == ID_REV_CHIP_ID_7800_)

    Here too.

[...]

MBR, Sergei

Powered by blists - more mailing lists