[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date: Wed, 6 Jun 2012 22:30:59 +0100
From: Ben Hutchings <bhutchings@...arflare.com>
To: Yuval Mintz <yuvalmin@...adcom.com>
CC: <davem@...emloft.net>, <netdev@...r.kernel.org>,
<eilong@...adcom.com>, <peppe.cavallaro@...com>
Subject: Re: [v3 net-next PATCH 1/3] Added kernel support in EEE Ethtool
commands
On Wed, 2012-06-06 at 22:07 +0300, Yuval Mintz wrote:
> This patch extends the kernel's ethtool interface by adding support
> for 2 new EEE commands - get_eee and set_eee.
>
> Thanks goes to Giuseppe Cavallaro for his original patch adding this support.
>
> Signed-off-by: Yuval Mintz <yuvalmin@...adcom.com>
> Signed-off-by: Eilon Greenstein <eilong@...adcom.com>
Reviewed-by: Ben Hutchings <bhutchings@...arflare.com>
but with one tiny change required:
[...]
> +static int ethtool_set_eee(struct net_device *dev, char __user *useraddr)
> +{
> + struct ethtool_eee edata;
> +
> + if (!dev->ethtool_ops->get_eee)
This must check set_eee, not get_eee.
Ben.
> + return -EOPNOTSUPP;
> +
> + if (copy_from_user(&edata, useraddr, sizeof(edata)))
> + return -EFAULT;
> +
> + return dev->ethtool_ops->set_eee(dev, &edata);
> +}
[...]
--
Ben Hutchings, Staff Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.
--
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