summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorYi Zhao <yi.zhao@windriver.com>2016-11-29 18:09:01 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-05-16 10:06:51 +0200
commita8c459de1668043739ec330f1f843702edd119e9 (patch)
treeb8a6d5dbe0377acb0f2e857cc008231e9fe447cc /net
parent0678adf8f8a99c66c48c608ea9a79588743bc615 (diff)
xfrm_user: fix return value from xfrm_user_rcv_msg
commit 83e2d0587ae859aae75fd9d246c409b10a6bd137 upstream. It doesn't support to run 32bit 'ip' to set xfrm objdect on 64bit host. But the return value is unknown for user program: ip xfrm policy list RTNETLINK answers: Unknown error 524 Replace ENOTSUPP with EOPNOTSUPP: ip xfrm policy list RTNETLINK answers: Operation not supported Signed-off-by: Yi Zhao <yi.zhao@windriver.com> Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com> Signed-off-by: Nathan Harold <nharold@google.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net')
-rw-r--r--net/xfrm/xfrm_user.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/xfrm/xfrm_user.c b/net/xfrm/xfrm_user.c
index 5d9f25cb6426..90270d7110a3 100644
--- a/net/xfrm/xfrm_user.c
+++ b/net/xfrm/xfrm_user.c
@@ -2480,7 +2480,7 @@ static int xfrm_user_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh)
#ifdef CONFIG_COMPAT
if (is_compat_task())
- return -ENOTSUPP;
+ return -EOPNOTSUPP;
#endif
type = nlh->nlmsg_type;