diff options
author | Joe Perches <joe@perches.com> | 2010-05-14 03:19:28 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-05-14 03:19:28 -0400 |
commit | a4b770972b8f819e408d7cc3ae9637e15bff62f6 (patch) | |
tree | 62e3c413b084c106d750cf6cc0701709cde30100 /drivers/net/stmmac/stmmac_timer.c | |
parent | 21ce849ba5cc178740c6532ba3dded852296ad91 (diff) |
drivers/net: Remove unnecessary returns from void function()s
This patch removes from drivers/net/ all the unnecessary
return; statements that precede the last closing brace of
void functions.
It does not remove the returns that are immediately
preceded by a label as gcc doesn't like that.
It also does not remove null void functions with return.
Done via:
$ grep -rP --include=*.[ch] -l "return;\n}" net/ | \
xargs perl -i -e 'local $/ ; while (<>) { s/\n[ \t\n]+return;\n}/\n}/g; print; }'
with some cleanups by hand.
Compile tested x86 allmodconfig only.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/stmmac/stmmac_timer.c')
-rw-r--r-- | drivers/net/stmmac/stmmac_timer.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/drivers/net/stmmac/stmmac_timer.c b/drivers/net/stmmac/stmmac_timer.c index 679f61ffb1f8..2a0e1abde7e7 100644 --- a/drivers/net/stmmac/stmmac_timer.c +++ b/drivers/net/stmmac/stmmac_timer.c | |||
@@ -31,8 +31,6 @@ static void stmmac_timer_handler(void *data) | |||
31 | struct net_device *dev = (struct net_device *)data; | 31 | struct net_device *dev = (struct net_device *)data; |
32 | 32 | ||
33 | stmmac_schedule(dev); | 33 | stmmac_schedule(dev); |
34 | |||
35 | return; | ||
36 | } | 34 | } |
37 | 35 | ||
38 | #define STMMAC_TIMER_MSG(timer, freq) \ | 36 | #define STMMAC_TIMER_MSG(timer, freq) \ |
@@ -47,13 +45,11 @@ static void stmmac_rtc_start(unsigned int new_freq) | |||
47 | { | 45 | { |
48 | rtc_irq_set_freq(stmmac_rtc, &stmmac_task, new_freq); | 46 | rtc_irq_set_freq(stmmac_rtc, &stmmac_task, new_freq); |
49 | rtc_irq_set_state(stmmac_rtc, &stmmac_task, 1); | 47 | rtc_irq_set_state(stmmac_rtc, &stmmac_task, 1); |
50 | return; | ||
51 | } | 48 | } |
52 | 49 | ||
53 | static void stmmac_rtc_stop(void) | 50 | static void stmmac_rtc_stop(void) |
54 | { | 51 | { |
55 | rtc_irq_set_state(stmmac_rtc, &stmmac_task, 0); | 52 | rtc_irq_set_state(stmmac_rtc, &stmmac_task, 0); |
56 | return; | ||
57 | } | 53 | } |
58 | 54 | ||
59 | int stmmac_open_ext_timer(struct net_device *dev, struct stmmac_timer *tm) | 55 | int stmmac_open_ext_timer(struct net_device *dev, struct stmmac_timer *tm) |
@@ -102,13 +98,11 @@ static void stmmac_tmu_start(unsigned int new_freq) | |||
102 | { | 98 | { |
103 | clk_set_rate(timer_clock, new_freq); | 99 | clk_set_rate(timer_clock, new_freq); |
104 | clk_enable(timer_clock); | 100 | clk_enable(timer_clock); |
105 | return; | ||
106 | } | 101 | } |
107 | 102 | ||
108 | static void stmmac_tmu_stop(void) | 103 | static void stmmac_tmu_stop(void) |
109 | { | 104 | { |
110 | clk_disable(timer_clock); | 105 | clk_disable(timer_clock); |
111 | return; | ||
112 | } | 106 | } |
113 | 107 | ||
114 | int stmmac_open_ext_timer(struct net_device *dev, struct stmmac_timer *tm) | 108 | int stmmac_open_ext_timer(struct net_device *dev, struct stmmac_timer *tm) |