diff options
author | Joe Perches <joe@perches.com> | 2010-11-20 21:38:57 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-11-22 15:58:48 -0500 |
commit | 20407ed8a5bb271dd8e8bd4678e1d3dadeb318bd (patch) | |
tree | ce6bcb885432ed86e6551b6416dd6ea65bf81fee /drivers/net/wireless/b43 | |
parent | 5b4bc649e18539a5d5a5482670d77f3f72de0eea (diff) |
iwlwifi: Use static const
Using static const generally increases object text and decreases data size.
It also generally decreases overall object size.
text data bss dec hex filename
48644 57 12120 60821 ed95 drivers/net/wireless/b43/phy_n.o.new
48661 57 12120 60838 eda6 drivers/net/wireless/b43/phy_n.o.old
37906 86 7904 45896 b348 drivers/net/wireless/iwlwifi/iwl-agn-lib.o.new
37937 86 7904 45927 b367 drivers/net/wireless/iwlwifi/iwl-agn-lib.o.old
37781 523 6752 45056 b000 drivers/net/wireless/iwlwifi/iwl-3945.o.new
37781 523 6752 45056 b000 drivers/net/wireless/iwlwifi/iwl-3945.o.old
Changed b43_nphy_write_clip_detection to take a const u16 *
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/b43')
-rw-r--r-- | drivers/net/wireless/b43/phy_n.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/net/wireless/b43/phy_n.c b/drivers/net/wireless/b43/phy_n.c index 6facb8ab05d1..afbfdf0ee6e0 100644 --- a/drivers/net/wireless/b43/phy_n.c +++ b/drivers/net/wireless/b43/phy_n.c | |||
@@ -655,7 +655,8 @@ static void b43_nphy_tx_iq_workaround(struct b43_wldev *dev) | |||
655 | } | 655 | } |
656 | 656 | ||
657 | /* http://bcm-v4.sipsolutions.net/802.11/PHY/N/clip-detection */ | 657 | /* http://bcm-v4.sipsolutions.net/802.11/PHY/N/clip-detection */ |
658 | static void b43_nphy_write_clip_detection(struct b43_wldev *dev, u16 *clip_st) | 658 | static void b43_nphy_write_clip_detection(struct b43_wldev *dev, |
659 | const u16 *clip_st) | ||
659 | { | 660 | { |
660 | b43_phy_write(dev, B43_NPHY_C1_CLIP1THRES, clip_st[0]); | 661 | b43_phy_write(dev, B43_NPHY_C1_CLIP1THRES, clip_st[0]); |
661 | b43_phy_write(dev, B43_NPHY_C2_CLIP1THRES, clip_st[1]); | 662 | b43_phy_write(dev, B43_NPHY_C2_CLIP1THRES, clip_st[1]); |
@@ -731,7 +732,7 @@ static void b43_nphy_stay_in_carrier_search(struct b43_wldev *dev, bool enable) | |||
731 | struct b43_phy_n *nphy = phy->n; | 732 | struct b43_phy_n *nphy = phy->n; |
732 | 733 | ||
733 | if (enable) { | 734 | if (enable) { |
734 | u16 clip[] = { 0xFFFF, 0xFFFF }; | 735 | static const u16 clip[] = { 0xFFFF, 0xFFFF }; |
735 | if (nphy->deaf_count++ == 0) { | 736 | if (nphy->deaf_count++ == 0) { |
736 | nphy->classifier_state = b43_nphy_classifier(dev, 0, 0); | 737 | nphy->classifier_state = b43_nphy_classifier(dev, 0, 0); |
737 | b43_nphy_classifier(dev, 0x7, 0); | 738 | b43_nphy_classifier(dev, 0x7, 0); |
@@ -843,7 +844,7 @@ static void b43_nphy_adjust_lna_gain_table(struct b43_wldev *dev) | |||
843 | u16 data[4]; | 844 | u16 data[4]; |
844 | s16 gain[2]; | 845 | s16 gain[2]; |
845 | u16 minmax[2]; | 846 | u16 minmax[2]; |
846 | u16 lna_gain[4] = { -2, 10, 19, 25 }; | 847 | static const u16 lna_gain[4] = { -2, 10, 19, 25 }; |
847 | 848 | ||
848 | if (nphy->hang_avoid) | 849 | if (nphy->hang_avoid) |
849 | b43_nphy_stay_in_carrier_search(dev, 1); | 850 | b43_nphy_stay_in_carrier_search(dev, 1); |
@@ -2299,7 +2300,7 @@ static void b43_nphy_int_pa_set_tx_dig_filters(struct b43_wldev *dev) | |||
2299 | { | 2300 | { |
2300 | int i, j; | 2301 | int i, j; |
2301 | /* B43_NPHY_TXF_20CO_S0A1, B43_NPHY_TXF_40CO_S0A1, unknown */ | 2302 | /* B43_NPHY_TXF_20CO_S0A1, B43_NPHY_TXF_40CO_S0A1, unknown */ |
2302 | u16 offset[] = { 0x186, 0x195, 0x2C5 }; | 2303 | static const u16 offset[] = { 0x186, 0x195, 0x2C5 }; |
2303 | 2304 | ||
2304 | for (i = 0; i < 3; i++) | 2305 | for (i = 0; i < 3; i++) |
2305 | for (j = 0; j < 15; j++) | 2306 | for (j = 0; j < 15; j++) |