rfkill: remove user_claim stuff

Almost all drivers do not support user_claim, so remove it
completely and always report -EOPNOTSUPP to userspace. Since
userspace cannot really drive rfkill _anyway_ (due to the
odd restrictions imposed by the documentation) having this
code is just pointless.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
Johannes Berg 2009-03-27 14:14:31 +01:00 committed by John W. Linville
parent c1c6b14b22
commit 621cac8529
12 changed files with 8 additions and 71 deletions

View file

@ -58,9 +58,6 @@ enum rfkill_state {
* @type: Radio type which the button controls, the value stored
* here should be a value from enum rfkill_type.
* @state: State of the switch, "UNBLOCKED" means radio can operate.
* @user_claim_unsupported: Whether the hardware supports exclusive
* RF-kill control by userspace. Set this before registering.
* @user_claim: Set when the switch is controlled exlusively by userspace.
* @mutex: Guards switch state transitions. It serializes callbacks
* and also protects the state.
* @data: Pointer to the RF button drivers private data which will be
@ -83,9 +80,6 @@ struct rfkill {
const char *name;
enum rfkill_type type;
bool user_claim_unsupported;
bool user_claim;
/* the mutex serializes callbacks and also protects
* the state */
struct mutex mutex;