diff options
author | Joe Perches <joe@perches.com> | 2014-12-10 10:28:58 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-12-10 15:33:16 -0500 |
commit | 785c20a08bead1e58ad53f2dc324782da7a0c9ea (patch) | |
tree | 1fbf9ac09b89dea8754927e84a54c15ad3e47d0a /net/irda/parameters.c | |
parent | 22bbf5f3e4e4db4a94f18d7b1ba21b5bd5fd934b (diff) | |
download | linux-stable-785c20a08bead1e58ad53f2dc324782da7a0c9ea.tar.gz linux-stable-785c20a08bead1e58ad53f2dc324782da7a0c9ea.tar.bz2 linux-stable-785c20a08bead1e58ad53f2dc324782da7a0c9ea.zip |
irda: Convert function pointer arrays and uses to const
Making things const is a good thing.
(x86-64 defconfig with all irda)
$ size net/irda/built-in.o*
text data bss dec hex filename
109276 1868 244 111388 1b31c net/irda/built-in.o.new
108828 2316 244 111388 1b31c net/irda/built-in.o.old
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/irda/parameters.c')
-rw-r--r-- | net/irda/parameters.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/net/irda/parameters.c b/net/irda/parameters.c index 006786bfdd65..16ce32ffe004 100644 --- a/net/irda/parameters.c +++ b/net/irda/parameters.c @@ -52,7 +52,7 @@ static int irda_insert_no_value(void *self, __u8 *buf, int len, __u8 pi, static int irda_param_unpack(__u8 *buf, char *fmt, ...); /* Parameter value call table. Must match PV_TYPE */ -static PV_HANDLER pv_extract_table[] = { +static const PV_HANDLER pv_extract_table[] = { irda_extract_integer, /* Handler for any length integers */ irda_extract_integer, /* Handler for 8 bits integers */ irda_extract_integer, /* Handler for 16 bits integers */ @@ -62,7 +62,7 @@ static PV_HANDLER pv_extract_table[] = { irda_extract_no_value /* Handler for no value parameters */ }; -static PV_HANDLER pv_insert_table[] = { +static const PV_HANDLER pv_insert_table[] = { irda_insert_integer, /* Handler for any length integers */ irda_insert_integer, /* Handler for 8 bits integers */ irda_insert_integer, /* Handler for 16 bits integers */ @@ -449,7 +449,7 @@ static int irda_param_unpack(__u8 *buf, char *fmt, ...) int irda_param_insert(void *self, __u8 pi, __u8 *buf, int len, pi_param_info_t *info) { - pi_minor_info_t *pi_minor_info; + const pi_minor_info_t *pi_minor_info; __u8 pi_minor; __u8 pi_major; int type; @@ -504,7 +504,7 @@ EXPORT_SYMBOL(irda_param_insert); static int irda_param_extract(void *self, __u8 *buf, int len, pi_param_info_t *info) { - pi_minor_info_t *pi_minor_info; + const pi_minor_info_t *pi_minor_info; __u8 pi_minor; __u8 pi_major; int type; |