[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1412843212.1828.17.camel@jlt4.sipsolutions.net>
Date: Thu, 09 Oct 2014 10:26:52 +0200
From: Johannes Berg <johannes@...solutions.net>
To: Rostislav Lisovy <lisovy@...il.com>
Cc: linux-wireless@...r.kernel.org, linux-kernel@...r.kernel.org,
Michal Sojka <sojkam1@....cvut.cz>, s.sander@...dsys.de,
jan-niklas.meier@...kswagen.de, burak.simsek@...kswagen.de,
Emmanuel Thierry <emmanuel.thierry@...oko.fr>,
laszlo.virag@...msignia.com,
Rostislav Lisovy <rostislav.lisovy@....cvut.cz>
Subject: Re: [PATCH 3/4] cfg80211: Join and Leave handling for OCB mode
On Thu, 2014-09-11 at 16:30 +0200, Rostislav Lisovy wrote:
> Signed-off-by: Rostislav Lisovy <rostislav.lisovy@....cvut.cz>
A bit more commit log would be good :)
> +++ b/include/net/cfg80211.h
> @@ -375,6 +375,8 @@ static inline enum nl80211_channel_type
> cfg80211_get_chandef_type(const struct cfg80211_chan_def *chandef)
> {
> switch (chandef->width) {
> + case NL80211_CHAN_WIDTH_5:
> + case NL80211_CHAN_WIDTH_10:
> case NL80211_CHAN_WIDTH_20_NOHT:
> return NL80211_CHAN_NO_HT;
This is wrong, the old nl80211_channel_type simply cannot express a 5 or
10 MHz width - so this case should WARN() or something and really never
ever be called here.
Also, it doesn't really belong into this patch?
> +struct ocb_setup {
> + struct cfg80211_chan_def chandef;
> +};
kernel-doc would be appreciated.
> @@ -892,6 +893,13 @@ cfg80211_get_chan_state(struct wireless_dev *wdev,
> *radar_detect |= BIT(wdev->chandef.width);
> }
> return;
> + case NL80211_IFTYPE_OCB:
> + if (wdev->chandef.chan) {
> + *chan = wdev->chandef.chan;
> + *chanmode = CHAN_MODE_EXCLUSIVE;
> + return;
> + }
same as in the mac80211 patch - I don't see why this should be
exclusive.
> + WARN_ON(!setup->chandef.chan);
if (WARN_ON(...))
return -EINVAL;
would be better
johannes
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists