[PATCH] ethtool: two oopses in ethtool_set_coalesce() and ethtool_set_pauseparam()
Linux Kernel Mailing List <[email protected]> Fri, 28 Jul 2006 23:59:02 GMT
| Newsgroups | gmane.linux.kernel.commits.2-4 |
|---|---|
| Message-ID | <[email protected]> |
commit 8f13032569e345d8875882c7f3eb869f72558d56 tree 43d397c1e373578e046e44d7204bd845bb111904 parent 8c6f6cf38bc9b04edc69c2869ae1e6c584584b4f author Willy Tarreau <willy@wtap.(none)> Wed, 05 Jul 2006 22:34:52 +0200 committer Willy Tarreau <[email protected]> Wed, 05 Jul 2006 22:38:08 +0200 [PATCH] ethtool: two oopses in ethtool_set_coalesce() and ethtool_set_pauseparam() The function pointers which were checked were for their get_* counterparts. Typically a copy-paste typo. Signed-off-by: Willy Tarreau <[email protected]> net/core/ethtool.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/net/core/ethtool.c b/net/core/ethtool.c index e140eb3..89c1031 100644 --- a/net/core/ethtool.c +++ b/net/core/ethtool.c @@ -349,7 +349,7 @@ static int ethtool_set_coalesce(struct n { struct ethtool_coalesce coalesce; - if (!dev->ethtool_ops->get_coalesce) + if (!dev->ethtool_ops->set_coalesce) return -EOPNOTSUPP; if (copy_from_user(&coalesce, useraddr, sizeof(coalesce))) @@ -403,7 +403,7 @@ static int ethtool_set_pauseparam(struct { 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)))