]> git.baikalelectronics.ru Git - kernel.git/commit
ath9k_hw: optimize all descriptor access functions
authorFelix Fietkau <nbd@openwrt.org>
Fri, 15 Oct 2010 23:01:48 +0000 (01:01 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 9 Nov 2010 21:13:25 +0000 (16:13 -0500)
commit16f5547d7cebff8bde3c3d64e895df587b61b306
treeb8a256f5f4bd42c9ec37102638cc49e1a11eb242
parentada22205015423999f5b173486de3c2f5b760660
ath9k_hw: optimize all descriptor access functions

Because all of the descriptor data structures are marked as __packed, GCC
assumes the worst case wrt. alignment and generates unaligned load/store
instructions on MIPS for access to all fields.
Since descriptors always have to be 4-byte-aligned, we can just mark the
data structures with __aligned(4), which allows GCC to generate much more
efficient code.
Verified through disassembly and OProfile comparisons.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/ar9003_mac.h
drivers/net/wireless/ath/ath9k/mac.h