]> git.baikalelectronics.ru Git - kernel.git/commit
rt2x00: Optimize get_duration / get_duration_res
authorIvo van Doorn <ivdoorn@gmail.com>
Sun, 9 Nov 2008 19:47:00 +0000 (20:47 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 21 Nov 2008 16:08:16 +0000 (11:08 -0500)
commitf212240de5e4a668d5755f1f8f80bab5b86f5a9e
tree3c0114b3a3791d23e2ba88ee5534e0fc318f1dc5
parente9f716e04ab35887f7dc9b419262944e44f7e437
rt2x00: Optimize get_duration / get_duration_res

We can optimize get_duration and get_duration_res
by making them a macro. They are really simple
calculation handlers so this doesn't matter much.

Often (especially in rt2400pci and rt2500pci,
the arguments are hardcoded, and the result value
is passed into other hardcoded values.

By making the functions a macro GCC can
optimize the entire thing much better.

Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/rt2x00/rt2400pci.c
drivers/net/wireless/rt2x00/rt2500pci.c
drivers/net/wireless/rt2x00/rt2500usb.c
drivers/net/wireless/rt2x00/rt2x00.h
drivers/net/wireless/rt2x00/rt2x00config.c
drivers/net/wireless/rt2x00/rt2x00queue.c