summaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorWanlong Gao <gaowanlong@cn.fujitsu.com>2012-08-26 23:23:13 +0200
committerDavid S. Miller <davem@davemloft.net>2012-08-31 22:14:33 +0200
commit4a2c240691bfdb9b08e680fb8af3f8c011c60e02 (patch)
tree7658ba4c416ef6c8b8e96af2ff850f1e26a35b1a /net
parentnet:stmmac: convert driver to use devm_request_and_ioremap. (diff)
downloadlinux-4a2c240691bfdb9b08e680fb8af3f8c011c60e02.tar.xz
linux-4a2c240691bfdb9b08e680fb8af3f8c011c60e02.zip
net:atm:fix up ENOIOCTLCMD error handling
At commit 07d106d0, Linus pointed out that ENOIOCTLCMD should be translated as ENOTTY to user mode. Cc: "David S. Miller" <davem@davemloft.net> Cc: netdev@vger.kernel.org Signed-off-by: Wanlong Gao <gaowanlong@cn.fujitsu.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r--net/atm/resources.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/atm/resources.c b/net/atm/resources.c
index 23f45ce6f351..0447d5d0b639 100644
--- a/net/atm/resources.c
+++ b/net/atm/resources.c
@@ -432,7 +432,7 @@ int atm_dev_ioctl(unsigned int cmd, void __user *arg, int compat)
size = dev->ops->ioctl(dev, cmd, buf);
}
if (size < 0) {
- error = (size == -ENOIOCTLCMD ? -EINVAL : size);
+ error = (size == -ENOIOCTLCMD ? -ENOTTY : size);
goto done;
}
}