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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20121113135519.1e02be53@nehalam.linuxnetplumber.net>
Date:	Tue, 13 Nov 2012 13:55:19 -0800
From:	Stephen Hemminger <shemminger@...tta.com>
To:	Joachim Eastwood <manabian@...il.com>
Cc:	davem@...emloft.net, pcnet32@...ntier.com, nicolas.ferre@...el.com,
	mlindner@...vell.com, nico@...xnic.net,
	steve.glendinning@...well.net,
	uclinux-dist-devel@...ckfin.uclinux.org, netdev@...r.kernel.org
Subject: Re: [net-next PATCH] net/ethernet: remove useless
 is_valid_ether_addr from drivers ndo_open

On Tue, 13 Nov 2012 22:46:39 +0100
Joachim Eastwood <manabian@...il.com> wrote:

> diff --git a/drivers/net/ethernet/marvell/skge.c b/drivers/net/ethernet/marvell/skge.c
> index d19a143..ce8d053 100644
> --- a/drivers/net/ethernet/marvell/skge.c
> +++ b/drivers/net/ethernet/marvell/skge.c
> @@ -2524,9 +2524,6 @@ static int skge_up(struct net_device *dev)
>  	size_t rx_size, tx_size;
>  	int err;
>  
> -	if (!is_valid_ether_addr(dev->dev_addr))
> -		return -EINVAL;
> -
>  	netif_info(skge, ifup, skge->netdev, "enabling interface\n");
>  
>  	if (dev->mtu > RX_BUF_SIZE)

This should probably stay since it costs so little and protects
against a obscure error case.
skge_up is called from skge_resume on resume from suspend.
It is possible that the device was zeroed after skge_suspend was
called.
--
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