On 13 June 2016 at 17:01, Pavel Machek wrote:
> On Mon 2016-06-13 15:59:35, João Paulo Rechi Vita wrote:
>> On 13 June 2016 at 15:00, Pavel Machek wrote:
>> > Hi!
>> >
>> >> > João, that means you should send a patch to add the ::rfkill suffix.
&g
s/class/rfkill
> /sys/module/rfkill
>
If we use "rfkill" as a suffix, how do you expect userspace to be able
to differentiate between a LED that indicates airplane-mode (LED ON
when all radios are OFF) and a LED that indicates the state of a
specific radio like WiFi or Bluetooth (L
his is now contained in the platform-drivers-x86 subsystem. Thanks
Johannes for your patience and help designing and reviewing the rfkill
changes, even if not all of them made it through in the end. And
thanks everyone else involved for the feedback.
Best regards,
--
João Paulo Rechi Vita
http://about
From: João Paulo Rechi Vita
Provide an interface for the airplane-mode indicator be controlled from
userspace. User has to first acquire the control through
RFKILL_OP_AIRPLANE_MODE_INDICATOR_ACQUIRE and keep the fd open for the
whole time it wants to be in control of the indicator. Closing the
From: João Paulo Rechi Vita
Signed-off-by: João Paulo Rechi Vita
---
Documentation/rfkill.txt| 3 +++
include/uapi/linux/rfkill.h | 4 ++--
net/rfkill/core.c | 13 +
3 files changed, 18 insertions(+), 2 deletions(-)
diff --git a/Documentation/rfkill.txt b
From: João Paulo Rechi Vita
This creates a new LED trigger to be used by platform drivers as a
default trigger for airplane-mode indicator LEDs.
By default this trigger will fire when RFKILL_OP_CHANGE_ALL is called
for all types (RFKILL_TYPE_ALL), setting the LED brightness to LED_FULL
when the
k 577/1880
PASS rfkill_wpa2_psk 0.330014 2016-04-29 12:48:59.016711
João Paulo Rechi Vita (3):
rfkill: Create "rfkill-airplane-mode" LED trigger
rfkill: Userspace control for airplane mode
rfkill: Notify userspace of airplane-mode state changes
Documentation/rfkill.txt| 15 +++
in
Hello Johannes,
On 1 March 2016 at 11:15, João Paulo Rechi Vita wrote:
> On 1 March 2016 at 08:43, Johannes Berg wrote:
>>
>> I'm fine with Jouni's change, preserving the original behaviour of
>> requiring TYPE_ALL or the correct type, but I'm tempted to simp
ANGE)
> continue;
>
> to ignore the type entirely.
>
> I'm fine with Jouni's change, preserving the original behaviour of
> requiring TYPE_ALL or the correct type, but I'm tempted to simply
> remove the type check entirely.
>
> Thought
Hello Jouni,
On 26 February 2016 at 12:59, Jouni Malinen wrote:
> On Mon, Feb 22, 2016 at 11:36:39AM -0500, João Paulo Rechi Vita wrote:
>> Using a switch to handle different ev.op values in rfkill_fop_write()
>> makes the code easier to extend, as out-of-range values can always b
On 22 February 2016 at 12:00, Dan Williams wrote:
> On Mon, 2016-02-22 at 11:36 -0500, João Paulo Rechi Vita wrote:
>> This series implements an airplane-mode indicator LED trigger, which
>> can be
>> used by platform drivers. The default policy have have airplane-mode
&
.
To change state of the indicator, the
RFKILL_OP_AIRPLANE_MODE_INDICATOR_CHANGE operation is used, passing the
value on "struct rfkill_event.soft". If the caller has not acquired the
airplane-mode control beforehand, the operation fails.
Signed-off-by: João Paulo Rechi Vita
---
Doc
Factor all assignments to rfkill_global_states[].cur into a single
function rfkill_update_global_state().
Signed-off-by: João Paulo Rechi Vita
---
net/rfkill/core.c | 38 +-
1 file changed, 17 insertions(+), 21 deletions(-)
diff --git a/net/rfkill/core.c b
There is still quite a bit of code using this interface, so we can't
just remove it. Hopefully it will be possible in the future, but since
its scheduled removal date is past 2 years already, we are better having
the documentation reflecting the current state of things.
Signed-off-by: João
Signed-off-by: João Paulo Rechi Vita
---
Documentation/rfkill.txt | 2 ++
1 file changed, 2 insertions(+)
diff --git a/Documentation/rfkill.txt b/Documentation/rfkill.txt
index 2ee6ef9..1f0c270 100644
--- a/Documentation/rfkill.txt
+++ b/Documentation/rfkill.txt
@@ -83,6 +83,8 @@ rfkill drivers
Signed-off-by: João Paulo Rechi Vita
---
net/rfkill/core.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/net/rfkill/core.c b/net/rfkill/core.c
index ffbc375..56d79cb 100644
--- a/net/rfkill/core.c
+++ b/net/rfkill/core.c
@@ -455,7 +455,6 @@ bool rfkill_get_global_sw_state(const enum
Using a switch to handle different ev.op values in rfkill_fop_write()
makes the code easier to extend, as out-of-range values can always be
handled by the default case.
Signed-off-by: João Paulo Rechi Vita
---
net/rfkill/core.c | 32 ++--
1 file changed, 18
The "claim" sysfs interface has been removed, so its documentation now
lives in the "removed" folder.
Signed-off-by: João Paulo Rechi Vita
---
Documentation/ABI/stable/sysfs-class-rfkill | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/Documentat
RFKILL_OP_AIRPLANE_MODE_RELEASE restores the default policy.
To change state of the indicator, the RFKILL_OP_AIRPLANE_MODE_CHANGE
operation is used, passing the value on "struct rfkill_event.soft". If
the caller has not acquired the airplane-mode control beforehand, the
operation fails.
Signed-off-by: João Paulo
, and to LED_OFF when the changing
the state to unblocked. In the future there will be a mechanism for
userspace to override the default policy, so it can implement its own.
This trigger will be used by the asus-wireless x86 platform driver.
Signed-off-by: João Paulo Rechi Vita
---
Documentation
Signed-off-by: João Paulo Rechi Vita
---
Documentation/rfkill.txt| 3 +++
include/uapi/linux/rfkill.h | 4 ++--
net/rfkill/core.c | 13 +
3 files changed, 18 insertions(+), 2 deletions(-)
diff --git a/Documentation/rfkill.txt b/Documentation/rfkill.txt
index 9dbe3fc
Signed-off-by: João Paulo Rechi Vita
---
net/rfkill/core.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/net/rfkill/core.c b/net/rfkill/core.c
index a805831..ffbc375 100644
--- a/net/rfkill/core.c
+++ b/net/rfkill/core.c
@@ -282,8 +282,8 @@ static void rfkill_set_block
.
Additionally, I have a couple of patches to have this feature supported by the
userspace tool 'rfkill' [1]. Should I use a different subject prefix to help
separate those from kernel patches in linux-wireless?
[1] https://wireless.wiki.kernel.org/en/users/documentation/rfkill
João Paulo
On 18 February 2016 at 15:12, Johannes Berg wrote:
> Hi,
>
> Sorry for the delay reviewing this.
>
No problems!
>
> On Mon, 2016-02-08 at 10:41 -0500, João Paulo Rechi Vita wrote:
>> Provide an interface for the airplane-mode indicator be controlled
>> from
&
On 18 February 2016 at 15:08, Johannes Berg wrote:
> On Mon, 2016-02-08 at 10:41 -0500, João Paulo Rechi Vita wrote:
>> This creates a new LED trigger to be used by platform drivers as a
>> default trigger for airplane-mode indicator LEDs.
>>
>> By default
s not
extend the RFKill event struct.
One alternative would be to move the control point to a separate
device, like /dev/rfkill-airplane-mode, but I'm not sure this is a
very elegant approach. Anyway, I'm open to work on changes to the API,
but it would be great if you could at least
RFKILL_OP_AIRPLANE_MODE_RELEASE restores the default policy.
To change state of the indicator, the RFKILL_OP_AIRPLANE_MODE_CHANGE
operation is used, passing the value on "struct rfkill_event.soft". If
the caller has not acquired the airplane-mode control beforehand, the
operation fails.
Signed-off-by: João Paulo
separate function?
>
Yes, makes sense. This also made me notice I was assigning a negative
value to a size_t variable (count).
>> + }
>> +
>> list_del(&data->list);
>> +
>
> (extra line)
>
After factoring out the _RELEASE code it looks be
On 8 February 2016 at 11:11, Dan Williams wrote:
> On Mon, 2016-02-08 at 10:41 -0500, João Paulo Rechi Vita wrote:
>> Provide an interface for the airplane-mode indicator be controlled
>> from
>> userspace. User has to first acquire the control through
>> RFKILL_OP_AIR
ge from Johannes
http://www.spinics.net/lists/linux-wireless/msg146069.html and let me
know if that covers your concern.
Thanks!
--
João Paulo Rechi Vita
http://about.me/jprvita
--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signed-off-by: João Paulo Rechi Vita
---
net/rfkill/core.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/net/rfkill/core.c b/net/rfkill/core.c
index ffbc375..56d79cb 100644
--- a/net/rfkill/core.c
+++ b/net/rfkill/core.c
@@ -455,7 +455,6 @@ bool rfkill_get_global_sw_state(const enum
There is still quite a bit of code using this interface, so we can't
just remove it. Hopefully it will be possible in the future, but since
its scheduled removal date is past 2 years already, we are better having
the documentation reflecting the current state of things.
Signed-off-by: João
The "claim" sysfs interface has been removed, so its documentation now
lives in the "removed" folder.
Signed-off-by: João Paulo Rechi Vita
---
Documentation/ABI/stable/sysfs-class-rfkill | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/Documentat
Signed-off-by: João Paulo Rechi Vita
---
net/rfkill/core.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/net/rfkill/core.c b/net/rfkill/core.c
index a805831..ffbc375 100644
--- a/net/rfkill/core.c
+++ b/net/rfkill/core.c
@@ -282,8 +282,8 @@ static void rfkill_set_block
Factor all assignments to rfkill_global_states[].cur into a single
function rfkill_update_global_state().
Signed-off-by: João Paulo Rechi Vita
---
net/rfkill/core.c | 38 +-
1 file changed, 17 insertions(+), 21 deletions(-)
diff --git a/net/rfkill/core.c b
Signed-off-by: João Paulo Rechi Vita
---
Documentation/rfkill.txt | 2 ++
1 file changed, 2 insertions(+)
diff --git a/Documentation/rfkill.txt b/Documentation/rfkill.txt
index 2ee6ef9..1f0c270 100644
--- a/Documentation/rfkill.txt
+++ b/Documentation/rfkill.txt
@@ -83,6 +83,8 @@ rfkill drivers
, and to LED_OFF when the changing
the state to unblocked. In the future there will be a mechanism for
userspace to override the default policy, so it can implement its own.
This trigger will be used by the asus-wireless x86 platform driver.
Signed-off-by: João Paulo Rechi Vita
---
Documentation
RFKILL_OP_AIRPLANE_MODE_RELEASE restores the default policy.
To change state of the indicator, the RFKILL_OP_AIRPLANE_MODE_CHANGE
operation is used, passing the value on "struct rfkill_event.soft". If
the caller has not acquired the airplane-mode control beforehand, the
operation fails.
Signed-off-by: João Paulo
Signed-off-by: João Paulo Rechi Vita
---
Documentation/rfkill.txt | 3 +++
net/rfkill/core.c| 13 +
2 files changed, 16 insertions(+)
diff --git a/Documentation/rfkill.txt b/Documentation/rfkill.txt
index aa6e014..5248812 100644
--- a/Documentation/rfkill.txt
+++ b
_AIRPLANE_MODE_ACQUIRE,
_AIRPLANE_MODE_RELEASE, and _AIRPLANE_MODE_CHANGE. When the airplane-mode
indicator state changes, userspace gets notifications through the RFKill
control misc device (/dev/rfkill).
The series also contains a few general fixes and improvements to the subsystem.
João Paulo Rechi Vita (9
40 matches
Mail list logo