For single band solutions, do not access the 5g channels
Change-Id: Iaf7ad26129eb43795fb03bc73cae9f58ef4409ef
SCSC-Bug-Id: SSB-37249
Signed-off-by: Himani Gupta <himani.g2@samsung.com>
chan->flags |= IEEE80211_CHAN_DISABLED;
}
}
- for (i = 0; i < ARRAY_SIZE(sdev->supported_5g_channels); i++) {
- if (sdev->supported_5g_channels[i] == 0) {
- chan = &wiphy->bands[1]->channels[i];
- chan->flags |= IEEE80211_CHAN_DISABLED;
+ if (sdev->band_5g_supported) {
+ for (i = 0; i < ARRAY_SIZE(sdev->supported_5g_channels); i++) {
+ if (sdev->supported_5g_channels[i] == 0) {
+ chan = &wiphy->bands[1]->channels[i];
+ chan->flags |= IEEE80211_CHAN_DISABLED;
+ }
}
}
}