* [PATCH] nl80211: fix logic inversion in start_nan()
@ 2016-11-21 12:55 Johannes Berg
2016-11-21 12:57 ` Arend Van Spriel
0 siblings, 1 reply; 3+ messages in thread
From: Johannes Berg @ 2016-11-21 12:55 UTC (permalink / raw)
To: linux-wireless; +Cc: Arend Van Spriel, Johannes Berg
From: Johannes Berg <johannes.berg@intel.com>
Arend inadvertedly inverted the logic while converting to
wdev_running(), fix that.
Fixes: 73c7da3dae1e ("cfg80211: add generic helper to check interface is running")
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
net/wireless/nl80211.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 4e9bda49e957..e4f718e956d7 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -10625,7 +10625,7 @@ static int nl80211_start_nan(struct sk_buff *skb, struct genl_info *info)
if (wdev->iftype != NL80211_IFTYPE_NAN)
return -EOPNOTSUPP;
- if (!wdev_running(wdev))
+ if (wdev_running(wdev))
return -EEXIST;
if (rfkill_blocked(rdev->rfkill))
--
2.9.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] nl80211: fix logic inversion in start_nan()
2016-11-21 12:55 [PATCH] nl80211: fix logic inversion in start_nan() Johannes Berg
@ 2016-11-21 12:57 ` Arend Van Spriel
2016-11-21 12:58 ` Arend Van Spriel
0 siblings, 1 reply; 3+ messages in thread
From: Arend Van Spriel @ 2016-11-21 12:57 UTC (permalink / raw)
To: Johannes Berg, linux-wireless; +Cc: Johannes Berg
On 21-11-2016 13:55, Johannes Berg wrote:
> From: Johannes Berg <johannes.berg@intel.com>
>
> Arend inadvertedly inverted the logic while converting to
> wdev_running(), fix that.
It was indeed inadvertedly.
Thanks,
Arend
> Fixes: 73c7da3dae1e ("cfg80211: add generic helper to check interface is running")
> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
> ---
> net/wireless/nl80211.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
> index 4e9bda49e957..e4f718e956d7 100644
> --- a/net/wireless/nl80211.c
> +++ b/net/wireless/nl80211.c
> @@ -10625,7 +10625,7 @@ static int nl80211_start_nan(struct sk_buff *skb, struct genl_info *info)
> if (wdev->iftype != NL80211_IFTYPE_NAN)
> return -EOPNOTSUPP;
>
> - if (!wdev_running(wdev))
> + if (wdev_running(wdev))
> return -EEXIST;
>
> if (rfkill_blocked(rdev->rfkill))
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] nl80211: fix logic inversion in start_nan()
2016-11-21 12:57 ` Arend Van Spriel
@ 2016-11-21 12:58 ` Arend Van Spriel
0 siblings, 0 replies; 3+ messages in thread
From: Arend Van Spriel @ 2016-11-21 12:58 UTC (permalink / raw)
To: Johannes Berg, linux-wireless; +Cc: Johannes Berg
On 21-11-2016 13:57, Arend Van Spriel wrote:
> On 21-11-2016 13:55, Johannes Berg wrote:
>> From: Johannes Berg <johannes.berg@intel.com>
>>
>> Arend inadvertedly inverted the logic while converting to
>> wdev_running(), fix that.
>
> It was indeed inadvertedly.
Actually spelling checker complains. Should be 'inadvertently'.
Regards,
Arend
> Thanks,
> Arend
>
>> Fixes: 73c7da3dae1e ("cfg80211: add generic helper to check interface is running")
>> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
>> ---
>> net/wireless/nl80211.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
>> index 4e9bda49e957..e4f718e956d7 100644
>> --- a/net/wireless/nl80211.c
>> +++ b/net/wireless/nl80211.c
>> @@ -10625,7 +10625,7 @@ static int nl80211_start_nan(struct sk_buff *skb, struct genl_info *info)
>> if (wdev->iftype != NL80211_IFTYPE_NAN)
>> return -EOPNOTSUPP;
>>
>> - if (!wdev_running(wdev))
>> + if (wdev_running(wdev))
>> return -EEXIST;
>>
>> if (rfkill_blocked(rdev->rfkill))
>>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-11-21 12:58 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-11-21 12:55 [PATCH] nl80211: fix logic inversion in start_nan() Johannes Berg
2016-11-21 12:57 ` Arend Van Spriel
2016-11-21 12:58 ` Arend Van Spriel
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox