From: Jeff Garzik Date: Mon, 17 Jul 2006 16:54:40 +0000 (-0400) Subject: [NET] ethtool: fix oops by testing correct struct member X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e1b90c416d6e6b71fc63974c1798e3cf55bba77f;p=GitHub%2Fmt8127%2Fandroid_kernel_alcatel_ttab.git [NET] ethtool: fix oops by testing correct struct member Noticed by Willy Tarreau. Signed-off-by: Jeff Garzik --- diff --git a/net/core/ethtool.c b/net/core/ethtool.c index 27ce1683caf5..2797e2815418 100644 --- a/net/core/ethtool.c +++ b/net/core/ethtool.c @@ -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)))