Search Linux Wireless

Re: [PATCH] ath6kl: fix incorrect use of IEEE80211_NUM_BANDS

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 12 Jul 2012 12:13:12 +0300
Kalle Valo <kvalo@xxxxxxxxxxxxxxxx> wrote:

> +	/* only check 2.4 and 5 GHz bands, skip the rest */
> +	for (band = 0; band <= IEEE80211_BAND_5GHZ; band++) {

There is something inelegant here.  The code is mixing an integer and
an enum.  I'd rather go with one or those:

two enums:
for (band = IEEE80211_BAND_2GHZ; band <= IEEE80211_BAND_5GHZ; band++) {

or two integers:
for (band = 0; band <= ATH6KL_NUM_BANDS; band++) {

-- 
Regards,
Pavel Roskin
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux