diff options
author | Joe Perches <joe@perches.com> | 2011-08-26 04:56:39 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-08-30 15:38:52 -0400 |
commit | 29e76245d46ff530bb2b0311e9fc823fc07b1147 (patch) | |
tree | 616e40295d0ca6b87e51334f32f4338cac3eb30a /drivers/net/wireless/ath/main.c | |
parent | 7b8112d6db0cc67dd2a722ca5bf707768890ac9d (diff) |
ath: Make ath_printk void not int and remove unused struct ath_common *
Changing the return type and removing the unused argument from
ath_printk reduces code size.
Add an __always_unused struct ath_common * to the macros
that call ath_printk to avoid unused variable warnings.
$ size drivers/net/wireless/ath/built-in.o*
text data bss dec hex filename
1159859 16235 212000 1388094 152e3e drivers/net/wireless/ath/built-in.o.new
1164175 16235 212032 1392442 153f3a drivers/net/wireless/ath/built-in.o.old
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/main.c')
-rw-r--r-- | drivers/net/wireless/ath/main.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/drivers/net/wireless/ath/main.c b/drivers/net/wireless/ath/main.c index c325202fdc5..d9218fe0203 100644 --- a/drivers/net/wireless/ath/main.c +++ b/drivers/net/wireless/ath/main.c | |||
@@ -57,22 +57,18 @@ struct sk_buff *ath_rxbuf_alloc(struct ath_common *common, | |||
57 | } | 57 | } |
58 | EXPORT_SYMBOL(ath_rxbuf_alloc); | 58 | EXPORT_SYMBOL(ath_rxbuf_alloc); |
59 | 59 | ||
60 | int ath_printk(const char *level, struct ath_common *common, | 60 | void ath_printk(const char *level, const char *fmt, ...) |
61 | const char *fmt, ...) | ||
62 | { | 61 | { |
63 | struct va_format vaf; | 62 | struct va_format vaf; |
64 | va_list args; | 63 | va_list args; |
65 | int rtn; | ||
66 | 64 | ||
67 | va_start(args, fmt); | 65 | va_start(args, fmt); |
68 | 66 | ||
69 | vaf.fmt = fmt; | 67 | vaf.fmt = fmt; |
70 | vaf.va = &args; | 68 | vaf.va = &args; |
71 | 69 | ||
72 | rtn = printk("%sath: %pV", level, &vaf); | 70 | printk("%sath: %pV", level, &vaf); |
73 | 71 | ||
74 | va_end(args); | 72 | va_end(args); |
75 | |||
76 | return rtn; | ||
77 | } | 73 | } |
78 | EXPORT_SYMBOL(ath_printk); | 74 | EXPORT_SYMBOL(ath_printk); |