Search Linux Wireless

Re: [PATCH v9 3/4] mac80211: implement chanctx reservation

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

 



On 13 March 2014 14:33, Luciano Coelho <luciano.coelho@xxxxxxxxx> wrote:

[...]

> +       ret = ieee80211_assign_vif_chanctx(sdata, ctx);
> +       if (old_ctx->refcount == 0)
> +               ieee80211_free_chanctx(local, old_ctx);
> +       if (ret) {
> +               /* if assign fails refcount stays the same */
> +               if (ctx->refcount == 0)
> +                       ieee80211_free_chanctx(local, ctx);
> +               goto out;
> +       }
> +
> +       __ieee80211_vif_copy_chanctx_to_vlans(sdata, false);

I'm sorry I didn't notice that this earlier :-( but this should be
guarded by if (sdata->vif.type == NL80211_IFTYPE_AP). Otherwise you
hit WARN_ON for non-AP (e.g. STA) chanctx reservation.

Same goes for 4/4 (since you re-indent the code there).


Michał
--
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