Search Linux Wireless

Re: [PATCH v3] cfg80211: check for carrier state only when offchanel CAC supported

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

 



On Mon, 2015-01-05 at 05:28 -0800, Avinash Patil wrote:

> > -     if (netif_carrier_ok(dev))
> > +     if (wiphy_ext_feature_isset(&rdev->wiphy,
> > +                                 NL80211_EXT_FEATURE_OFFCHAN_CAC) &&
> > +         netif_carrier_ok(dev))
> >               return -EBUSY;
> 
> >Wait - doesn't that have to be !feature_isset()?
> 
> >johannes
> 
> If Offchannel CAC is supported (driver has set this bit in wiphy's
> extended features) & carrier is ON, return EBUSY as offchannel CAC may
> be ongoing, isnt it?

Well, my thinking is this - a new feature flag should allow something
new.

Therefore, the patch should essentially be this:

+ if (!new_feature)
  if (do_old_check)

Now wrapping that into a single if gives

- if (do_old_check)
+ if (!new_feature && do_old_check)

so the patch looks wrong to me.

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



[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