Re: [PATCH 5/8] net: sun4i-emac: fix error return code

2014-12-31 Thread David Miller
From: Julia Lawall Date: Mon, 29 Dec 2014 18:04:40 +0100 > Return a negative error code on failure. > > A simplified version of the semantic match that finds this problem is as > follows: (http://coccinelle.lip6.fr/) ... > Signed-off-by: Julia Lawall Applied. -- To unsubscribe from this list:

[PATCH 5/8] net: sun4i-emac: fix error return code

2014-12-29 Thread Julia Lawall
Return a negative error code on failure. A simplified version of the semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // @@ identifier ret; expression e1,e2; @@ ( if (\(ret < 0\|ret != 0\)) { ... return ret; } | ret = 0 ) ... when != ret = e1 when != &ret *