rt2x00: Use static const
authorJoe Perches <joe@perches.com>
Sun, 21 Nov 2010 02:39:01 +0000 (18:39 -0800)
committerJohn W. Linville <linville@tuxdriver.com>
Mon, 22 Nov 2010 20:58:53 +0000 (15:58 -0500)
Using static const generally increases object text and decreases data size.
It also generally decreases overall object size.

   text    data     bss     dec     hex filename
  40197      56    8336   48589    bdcd drivers/net/wireless/rt2x00/rt2800lib.o.new
  40205      56    8336   48597    bdd5 drivers/net/wireless/rt2x00/rt2800lib.o.old

Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/rt2x00/rt2800lib.c

index ce8df66a3de8e6dcc884aa123797d229107228cf..75631614aba3487c48a92e759737c083a9ef20e7 100644 (file)
@@ -2166,7 +2166,7 @@ static int rt2800_init_registers(struct rt2x00_dev *rt2x00dev)
                                         SHARED_KEY_MODE_ENTRY(i), 0);
 
        for (i = 0; i < 256; i++) {
-               u32 wcid[2] = { 0xffffffff, 0x00ffffff };
+               static const u32 wcid[2] = { 0xffffffff, 0x00ffffff };
                rt2800_register_multiwrite(rt2x00dev, MAC_WCID_ENTRY(i),
                                              wcid, sizeof(wcid));