cfg80211: allow wext to remove keys that don't exist
authorJohannes Berg <johannes@sipsolutions.net>
Mon, 18 May 2009 17:56:36 +0000 (19:56 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 20 May 2009 18:46:30 +0000 (14:46 -0400)
commite3da574a0ddd3e90a1e2b788b84b94bc17a75172
treedc17ed9268594c1236e1f0b5efae2140b226b5cf
parent73606d00360cb93963aeb7bfbf8bfdbc51cfab9f
cfg80211: allow wext to remove keys that don't exist

Some applications using wireless extensions expect to be able to
remove a key that doesn't exist. One example is wpa_supplicant
which doesn't actually change behaviour when running into an
error while trying to do that, but it prints an error message
which users interpret as wpa_supplicant having problems.

The safe thing to do is not change the behaviour of wireless
extensions any more, so when the driver reports -ENOENT let
the wext bridge code return success to userspace. To guarantee
this, also document that drivers should return -ENOENT when the
key doesn't exist.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
include/net/cfg80211.h
net/wireless/wext-compat.c