diff options
author | Andriy Voskoboinyk <avos@FreeBSD.org> | 2016-05-02 19:07:44 +0000 |
---|---|---|
committer | Andriy Voskoboinyk <avos@FreeBSD.org> | 2016-05-02 19:07:44 +0000 |
commit | d35192e513990878d540407f7a0f7cbc65097842 (patch) | |
tree | d2825dbb26f8e6b220c74d2df56ff8ce6036592e | |
parent | 7bc47ad999d953d8ee1b83a16afe8593fab9e573 (diff) | |
download | src-d35192e513990878d540407f7a0f7cbc65097842.tar.gz src-d35192e513990878d540407f7a0f7cbc65097842.zip |
iwm: fix parameters for iwm_add_channel_band()
It accepts <first index, max index + 1>, not
<first index, number of entries>.
Reported by: adrian
Notes
Notes:
svn path=/head/; revision=298936
-rw-r--r-- | sys/dev/iwm/if_iwm.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/dev/iwm/if_iwm.c b/sys/dev/iwm/if_iwm.c index eabcf75cbb6a..220d5a06ecea 100644 --- a/sys/dev/iwm/if_iwm.c +++ b/sys/dev/iwm/if_iwm.c @@ -1737,14 +1737,13 @@ iwm_init_channel_map(struct ieee80211com *ic, int maxchans, int *nchans, /* 14: 11b channel only. */ clrbit(bands, IEEE80211_MODE_11G); iwm_add_channel_band(sc, chans, maxchans, nchans, - IWM_NUM_2GHZ_CHANNELS - 1, 1, bands); + IWM_NUM_2GHZ_CHANNELS - 1, IWM_NUM_2GHZ_CHANNELS, bands); if (data->sku_cap_band_52GHz_enable) { memset(bands, 0, sizeof(bands)); setbit(bands, IEEE80211_MODE_11A); iwm_add_channel_band(sc, chans, maxchans, nchans, - IWM_NUM_2GHZ_CHANNELS, - nitems(iwm_nvm_channels) - IWM_NUM_2GHZ_CHANNELS, bands); + IWM_NUM_2GHZ_CHANNELS, nitems(iwm_nvm_channels), bands); } } |