aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJulia Lawall <julia@diku.dk>2010-08-16 12:25:21 -0400
committerJohn W. Linville <linville@tuxdriver.com>2010-08-24 16:28:05 -0400
commit9f19fa62edd2c397ed41c2dba29fb9f7144cb918 (patch)
tree2df431dee44817484b1a52035a70bf67abcc5574
parent30bf4169ad163047f87a2555cb33aa55f5d5e2bc (diff)
drivers/net/wireless/wl12xx: Use available error codes
In each case, error codes are stored in ret, but the return value is always 0. Return ret instead. The semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> @r@ local idexpression x; constant C; @@ if (...) { ... x = -C ... when != x ( return <+...x...+>; | return NULL; | return; | * return ...; ) } // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Acked-by: Kalle Valo <kvalo@adurom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r--drivers/net/wireless/wl12xx/wl1251_acx.c2
-rw-r--r--drivers/net/wireless/wl12xx/wl1251_cmd.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/wl12xx/wl1251_acx.c b/drivers/net/wireless/wl12xx/wl1251_acx.c
index 91891f928070..2f8a2ba744dc 100644
--- a/drivers/net/wireless/wl12xx/wl1251_acx.c
+++ b/drivers/net/wireless/wl12xx/wl1251_acx.c
@@ -380,7 +380,7 @@ int wl1251_acx_pd_threshold(struct wl1251 *wl)
380 380
381out: 381out:
382 kfree(pd); 382 kfree(pd);
383 return 0; 383 return ret;
384} 384}
385 385
386int wl1251_acx_slot(struct wl1251 *wl, enum acx_slot_type slot_time) 386int wl1251_acx_slot(struct wl1251 *wl, enum acx_slot_type slot_time)
diff --git a/drivers/net/wireless/wl12xx/wl1251_cmd.c b/drivers/net/wireless/wl12xx/wl1251_cmd.c
index ce3722f4c3e3..15fb68c6b542 100644
--- a/drivers/net/wireless/wl12xx/wl1251_cmd.c
+++ b/drivers/net/wireless/wl12xx/wl1251_cmd.c
@@ -200,7 +200,7 @@ int wl1251_cmd_vbm(struct wl1251 *wl, u8 identity,
200 200
201out: 201out:
202 kfree(vbm); 202 kfree(vbm);
203 return 0; 203 return ret;
204} 204}
205 205
206int wl1251_cmd_data_path(struct wl1251 *wl, u8 channel, bool enable) 206int wl1251_cmd_data_path(struct wl1251 *wl, u8 channel, bool enable)