On Mon, 2011-08-08 at 14:02 +0200, Alexander Simon wrote: > Check if the requested HT mode can be used. > Extend cfg80211 IBSS struct for HT mode. > > Signed-off-by: Alexander Simon <alexander.simon@xxxxxxxxx> > --- > > As there were no replies for my RFC post, i am resending this as PATCH. I was on vacation ;-) > + ibss.channel = rdev_freq_to_chan(rdev, > + nla_get_u32(info->attrs[NL80211_ATTR_WIPHY_FREQ]), > + ibss.channel_type); > if (!ibss.channel || > + ibss.channel->flags & IEEE80211_CHAN_PASSIVE_SCAN || > ibss.channel->flags & IEEE80211_CHAN_NO_IBSS || > - ibss.channel->flags & IEEE80211_CHAN_DISABLED) > + ibss.channel->flags & IEEE80211_CHAN_RADAR) > + return -EINVAL; > + > + /* Both channels should be able to initiate communication */ > + if ((ibss.channel_type == NL80211_CHAN_HT40PLUS || > + ibss.channel_type == NL80211_CHAN_HT40MINUS) && > + !can_beacon_sec_chan(&rdev->wiphy, ibss.channel, > + ibss.channel_type)) { > + printk(KERN_DEBUG > + "cfg80211: Secondary channel not " > + "allowed to initiate communication\n"); remove the printk please johannes -- 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