diff options
Diffstat (limited to 'Documentation/rfkill.txt')
-rw-r--r-- | Documentation/rfkill.txt | 44 |
1 files changed, 13 insertions, 31 deletions
diff --git a/Documentation/rfkill.txt b/Documentation/rfkill.txt index b4860509c319..83668e5dd17f 100644 --- a/Documentation/rfkill.txt +++ b/Documentation/rfkill.txt | |||
@@ -99,37 +99,15 @@ system. Also, it is possible to switch all rfkill drivers (or all drivers of | |||
99 | a specified type) into a state which also updates the default state for | 99 | a specified type) into a state which also updates the default state for |
100 | hotplugged devices. | 100 | hotplugged devices. |
101 | 101 | ||
102 | After an application opens /dev/rfkill, it can read the current state of | 102 | After an application opens /dev/rfkill, it can read the current state of all |
103 | all devices, and afterwards can poll the descriptor for hotplug or state | 103 | devices. Changes can be either obtained by either polling the descriptor for |
104 | change events. | 104 | hotplug or state change events or by listening for uevents emitted by the |
105 | 105 | rfkill core framework. | |
106 | Applications must ignore operations (the "op" field) they do not handle, | 106 | |
107 | this allows the API to be extended in the future. | 107 | Additionally, each rfkill device is registered in sysfs and emits uevents. |
108 | 108 | ||
109 | Additionally, each rfkill device is registered in sysfs and there has the | 109 | rfkill devices issue uevents (with an action of "change"), with the following |
110 | following attributes: | 110 | environment variables set: |
111 | |||
112 | name: Name assigned by driver to this key (interface or driver name). | ||
113 | type: Driver type string ("wlan", "bluetooth", etc). | ||
114 | persistent: Whether the soft blocked state is initialised from | ||
115 | non-volatile storage at startup. | ||
116 | state: Current state of the transmitter | ||
117 | 0: RFKILL_STATE_SOFT_BLOCKED | ||
118 | transmitter is turned off by software | ||
119 | 1: RFKILL_STATE_UNBLOCKED | ||
120 | transmitter is (potentially) active | ||
121 | 2: RFKILL_STATE_HARD_BLOCKED | ||
122 | transmitter is forced off by something outside of | ||
123 | the driver's control. | ||
124 | This file is deprecated because it can only properly show | ||
125 | three of the four possible states, soft-and-hard-blocked is | ||
126 | missing. | ||
127 | claim: 0: Kernel handles events | ||
128 | This file is deprecated because there no longer is a way to | ||
129 | claim just control over a single rfkill instance. | ||
130 | |||
131 | rfkill devices also issue uevents (with an action of "change"), with the | ||
132 | following environment variables set: | ||
133 | 111 | ||
134 | RFKILL_NAME | 112 | RFKILL_NAME |
135 | RFKILL_STATE | 113 | RFKILL_STATE |
@@ -137,3 +115,7 @@ RFKILL_TYPE | |||
137 | 115 | ||
138 | The contents of these variables corresponds to the "name", "state" and | 116 | The contents of these variables corresponds to the "name", "state" and |
139 | "type" sysfs files explained above. | 117 | "type" sysfs files explained above. |
118 | |||
119 | |||
120 | For further details consult Documentation/ABI/stable/dev-rfkill and | ||
121 | Documentation/ABI/stable/sysfs-class-rfkill. | ||