From: Alexander Aring Date: Tue, 19 Aug 2014 17:03:29 +0000 (+0200) Subject: ieee802154: 6lowpan_rtnl: fix correct errno value X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=c4cb901ac667f81786b402ca7d69a9063e770b3a;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git ieee802154: 6lowpan_rtnl: fix correct errno value This patch correct the return value of lowpan_alloc_frag if an error occur. Errno numbers should always be negative. Signed-off-by: Alexander Aring Signed-off-by: Marcel Holtmann --- diff --git a/net/ieee802154/6lowpan_rtnl.c b/net/ieee802154/6lowpan_rtnl.c index 016b77ee88f0..71fa7d42966c 100644 --- a/net/ieee802154/6lowpan_rtnl.c +++ b/net/ieee802154/6lowpan_rtnl.c @@ -246,7 +246,7 @@ lowpan_alloc_frag(struct sk_buff *skb, int size, return ERR_PTR(-rc); } } else { - frag = ERR_PTR(ENOMEM); + frag = ERR_PTR(-ENOMEM); } return frag;