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: <085E4D48-DF23-4C85-84DF-8321CA236304@vmware.com>
Date:	Fri, 24 Feb 2012 08:31:44 -0800
From:	Bhavesh Davda <bhavesh@...are.com>
To:	Danny Kukawka <danny.kukawka@...ect.de>
CC:	Shreyas Bhatewara <sbhatewara@...are.com>,
	"VMware, Inc." <pv-drivers@...are.com>,
	"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
	Danny Kukawka <dkukawka@...e.de>,
	"David S. Miller" <davem@...emloft.net>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [Pv-drivers] [PATCH 08/12] vmxnet3: check given MAC address,	if
 invalid return -EADDRNOTAVAIL

Lgtm.

Reviewed-by: Bhavesh Davda <bhavesh@...are.com>

- Bhavesh

(From my iPhone)


On Feb 24, 2012, at 8:01 AM, "Danny Kukawka" <danny.kukawka@...ect.de> wrote:

> Check if given address is valid in .ndo_set_mac_address/
> vmxnet3_set_mac_addr(), if invalid return -EADDRNOTAVAIL as
> eth_mac_addr() already does if is_valid_ether_addr() fails.
> 
> Signed-off-by: Danny Kukawka <danny.kukawka@...ect.de>
> ---
> drivers/net/vmxnet3/vmxnet3_drv.c |    3 +++
> 1 files changed, 3 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/net/vmxnet3/vmxnet3_drv.c b/drivers/net/vmxnet3/vmxnet3_drv.c
> index e1562e8..bd2a7cd 100644
> --- a/drivers/net/vmxnet3/vmxnet3_drv.c
> +++ b/drivers/net/vmxnet3/vmxnet3_drv.c
> @@ -2331,6 +2331,9 @@ vmxnet3_set_mac_addr(struct net_device *netdev, void *p)
>    struct sockaddr *addr = p;
>    struct vmxnet3_adapter *adapter = netdev_priv(netdev);
> 
> +    if (!is_valid_ether_addr(addr->sa_data))
> +        return -EADDRNOTAVAIL;
> +
>    memcpy(netdev->dev_addr, addr->sa_data, netdev->addr_len);
>    vmxnet3_write_mac_addr(adapter, addr->sa_data);
> 
> -- 
> 1.7.8.3
> 
> _______________________________________________
> Pv-drivers mailing list
> Pv-drivers@...are.com
> http://mailman2.vmware.com/mailman/listinfo/pv-drivers
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ