Commit e1b90c41 authored by Jeff Garzik's avatar Jeff Garzik

[NET] ethtool: fix oops by testing correct struct member

Noticed by Willy Tarreau.
Signed-off-by: default avatarJeff Garzik <jeff@garzik.org>
parent 82d6897f
......@@ -437,7 +437,7 @@ static int ethtool_set_pauseparam(struct net_device *dev, void __user *useraddr)
{
struct ethtool_pauseparam pauseparam;
if (!dev->ethtool_ops->get_pauseparam)
if (!dev->ethtool_ops->set_pauseparam)
return -EOPNOTSUPP;
if (copy_from_user(&pauseparam, useraddr, sizeof(pauseparam)))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment