linux/drivers/staging/vt6656
Oscar Carter bf42304b55 staging: vt6656: Use fls instead of for loop in vnt_update_top_rates
Replace the for loops of the vnt_update_top_rates function by the fls
function.

The purpose of the two for loops is to find the most significant bit set
in a range of bits. So, they can be replace by the fls function (find
last set) with a previous mask to define the range.

This way avoid the iteration over unnecessary for loops.

The header "linux/bits.h" can be remove as it is included in the header
"linux/bitops.h".

Signed-off-by: Oscar Carter <oscar.carter@gmx.com>
Link: https://lore.kernel.org/r/20200420155246.4925-1-oscar.carter@gmx.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-04-23 13:39:51 +02:00
..
baseband.c staging: vt6656: Move vnt_get_frame_time and vnt_get_phy_field to rxtx 2020-04-23 13:33:36 +02:00
baseband.h staging: vt6656: Move vnt_get_frame_time and vnt_get_phy_field to rxtx 2020-04-23 13:33:36 +02:00
card.c staging: vt6656: Use fls instead of for loop in vnt_update_top_rates 2020-04-23 13:39:51 +02:00
card.h staging: vt6656: Refactor the vnt_ofdm_min_rate function 2020-04-23 13:38:08 +02:00
channel.c staging: vt6656: Remove redundant license text 2017-11-28 13:20:47 +01:00
channel.h staging: vt6656: Fix styling of the comment related to SPDX-License-Identifier 2019-04-02 09:29:27 +02:00
desc.h staging: vt6656: Use BIT() macro instead of hex value 2020-03-21 10:58:16 +01:00
device.h staging: vt6656: Move firmware functions into main_usb. 2020-04-23 13:31:59 +02:00
Kconfig staging: vt665*: use help instead of ---help--- in Kconfig 2019-05-20 10:49:08 +02:00
key.c staging: vt6656: Fix return for unsupported cipher modes. 2020-02-09 16:22:56 -08:00
key.h staging: vt6656: Fix styling of the comment related to SPDX-License-Identifier 2019-04-02 09:29:27 +02:00
mac.c staging: vt6656: avoid discarding called function's return code 2019-05-21 08:25:03 +02:00
mac.h staging: vt6656: Define EnCFG_BBType_MASK as OR between previous defines 2020-04-13 08:55:28 +02:00
main_usb.c staging: vt6656: call vnt_update_pre_ed_threshold from vnt_config. 2020-04-23 13:33:36 +02:00
Makefile staging: vt6656: Move firmware functions into main_usb. 2020-04-23 13:31:59 +02:00
power.c staging: vt6656: Remove redundant license text 2017-11-28 13:20:47 +01:00
power.h staging: vt6656: Fix styling of the comment related to SPDX-License-Identifier 2019-04-02 09:29:27 +02:00
rf.c staging: vt6656: Return error code in vnt_rf_write_embedded function 2020-04-16 12:54:25 +02:00
rf.h staging: vt6556: vnt_rf_setpower convert to use ieee80211_channel. 2020-04-13 14:53:21 +02:00
rxtx.c staging: vt6656: Move vnt_get_frame_time and vnt_get_phy_field to rxtx 2020-04-23 13:33:36 +02:00
rxtx.h staging: vt6656: Move vnt_get_frame_time and vnt_get_phy_field to rxtx 2020-04-23 13:33:36 +02:00
TODO
usbpipe.c staging: vt6656: struct vnt_rcb remove unused in_use. 2020-03-10 10:51:20 +01:00
usbpipe.h staging: vt6656: Delete int.c/h file and move functions to usbpipe 2020-03-04 07:52:32 +01:00
wcmd.c staging: vt6556: vnt_rf_setpower convert to use ieee80211_channel. 2020-04-13 14:53:21 +02:00
wcmd.h staging: vt6656: Fix styling of the comment related to SPDX-License-Identifier 2019-04-02 09:29:27 +02:00