On 13-12-2016 23:29, Johannes Berg wrote: > On Tue, 2016-12-13 at 21:09 +0100, Arend Van Spriel wrote: >> >>> There's a bit of a weird hard-coded restriction to 16 channels too, >>> that's due to the bucket map? >> >> Uhm. Is there? I will check, but if you can give me a pointer where >> to look it is appreciated. > > Just look for "< 16" or "<= 16" or so in the patch. I do think that's > because the channel map is a u16 though, not sure we'd want to change > that. Had to look for "> 16" ;-) > + /* ignore channels if band is specified */ > + if (band_select) > + return 0; > + > + nla_for_each_nested(chan, tb[NL80211_GSCAN_BUCKET_ATTR_CHANNELS], rem) { > + num_chans++; > + } Here an instance of the tab vs. space issue you mentioned. Will go over the patch and fix that. > + if (num_chans > 16) > + return -EINVAL; I suspect this is the restriction you were referring to. There is no reason for this although the android wifi hal has max 16 channels in a bucket so I might have picked that up. So could a driver have a similar limit and should we add such to the gscan capabilities? For instance our firmware api has a nasty restriction of 64 channels for all buckets together, eg. can do 4 buckets of 16 channels each. Regards, Arend