Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-12-01 Thread Darren Hart
On Fri, Nov 28, 2014 at 01:54:57PM +0200, Mika Westerberg wrote: > On Fri, Nov 28, 2014 at 12:45:55PM +0100, Pali Rohár wrote: > > Hello, > > > > I will fix all those style problems and add some comments. > > > > On Friday 28 November 2014 12:33:28 Mika Westerberg wrote: > > > > + if

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-12-01 Thread Darren Hart
On Fri, Nov 28, 2014 at 01:54:57PM +0200, Mika Westerberg wrote: On Fri, Nov 28, 2014 at 12:45:55PM +0100, Pali Rohár wrote: Hello, I will fix all those style problems and add some comments. On Friday 28 November 2014 12:33:28 Mika Westerberg wrote: + if

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-28 Thread Mika Westerberg
On Fri, Nov 28, 2014 at 12:45:55PM +0100, Pali Rohár wrote: > Hello, > > I will fix all those style problems and add some comments. > > On Friday 28 November 2014 12:33:28 Mika Westerberg wrote: > > > + if (ACPI_FAILURE(status)) > > > + return; > > > + > > > + rfkill_set_states(rfkill,

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-28 Thread Pali Rohár
Hello, I will fix all those style problems and add some comments. On Friday 28 November 2014 12:33:28 Mika Westerberg wrote: > > + if (ACPI_FAILURE(status)) > > + return; > > + > > + rfkill_set_states(rfkill, !output, !output); > > You can also write it like: > > if

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-28 Thread Mika Westerberg
On Sun, Nov 23, 2014 at 04:09:19PM +0100, Pali Rohár wrote: > This is an ACPI driver for Dell laptops which receive HW switch events. > It exports rfkill device dell-rbtn which provide correct hard rfkill state. > > It does not provide support for setting soft rfkill state yet. > >

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-28 Thread Mika Westerberg
On Sun, Nov 23, 2014 at 04:09:19PM +0100, Pali Rohár wrote: This is an ACPI driver for Dell laptops which receive HW switch events. It exports rfkill device dell-rbtn which provide correct hard rfkill state. It does not provide support for setting soft rfkill state yet. Signed-off-by: Pali

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-28 Thread Pali Rohár
Hello, I will fix all those style problems and add some comments. On Friday 28 November 2014 12:33:28 Mika Westerberg wrote: + if (ACPI_FAILURE(status)) + return; + + rfkill_set_states(rfkill, !output, !output); You can also write it like: if

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-28 Thread Mika Westerberg
On Fri, Nov 28, 2014 at 12:45:55PM +0100, Pali Rohár wrote: Hello, I will fix all those style problems and add some comments. On Friday 28 November 2014 12:33:28 Mika Westerberg wrote: + if (ACPI_FAILURE(status)) + return; + + rfkill_set_states(rfkill, !output, !output);

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-24 Thread Pali Rohár
On Monday 24 November 2014 22:50:26 Matthew Garrett wrote: > On Mon, Nov 24, 2014 at 09:55:47PM +0100, Pali Rohár wrote: > > This is complicated. HW switch controls all radio devices > > and you do not know which are present in specified running > > machine. Also list of devices which HW switch

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-24 Thread Matthew Garrett
On Mon, Nov 24, 2014 at 09:55:47PM +0100, Pali Rohár wrote: > This is complicated. HW switch controls all radio devices and you > do not know which are present in specified running machine. Also > list of devices which HW switch controls can be edited in BIOS > (on some machines). So what to

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-24 Thread Pali Rohár
On Monday 24 November 2014 21:09:05 Matthew Garrett wrote: > On Sun, Nov 23, 2014 at 04:09:19PM +0100, Pali Rohár wrote: > > + /* NOTE: rbtn controls all radio devices, not only WLAN > > +but rfkill interface does not support "ANY" type > > +so "WLAN" type is used > > +

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-24 Thread Matthew Garrett
On Sun, Nov 23, 2014 at 04:09:19PM +0100, Pali Rohár wrote: > + /* NOTE: rbtn controls all radio devices, not only WLAN > + but rfkill interface does not support "ANY" type > + so "WLAN" type is used > + */ If it controls multiple radio types then you should

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-24 Thread Matthew Garrett
On Sun, Nov 23, 2014 at 04:09:19PM +0100, Pali Rohár wrote: + /* NOTE: rbtn controls all radio devices, not only WLAN + but rfkill interface does not support ANY type + so WLAN type is used + */ If it controls multiple radio types then you should register

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-24 Thread Pali Rohár
On Monday 24 November 2014 21:09:05 Matthew Garrett wrote: On Sun, Nov 23, 2014 at 04:09:19PM +0100, Pali Rohár wrote: + /* NOTE: rbtn controls all radio devices, not only WLAN +but rfkill interface does not support ANY type +so WLAN type is used +*/ If it

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-24 Thread Matthew Garrett
On Mon, Nov 24, 2014 at 09:55:47PM +0100, Pali Rohár wrote: This is complicated. HW switch controls all radio devices and you do not know which are present in specified running machine. Also list of devices which HW switch controls can be edited in BIOS (on some machines). So what to do?

Re: [PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-24 Thread Pali Rohár
On Monday 24 November 2014 22:50:26 Matthew Garrett wrote: On Mon, Nov 24, 2014 at 09:55:47PM +0100, Pali Rohár wrote: This is complicated. HW switch controls all radio devices and you do not know which are present in specified running machine. Also list of devices which HW switch controls

[PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-23 Thread Pali Rohár
This is an ACPI driver for Dell laptops which receive HW switch events. It exports rfkill device dell-rbtn which provide correct hard rfkill state. It does not provide support for setting soft rfkill state yet. Signed-off-by: Pali Rohár --- drivers/platform/x86/Kconfig | 13 +++

[PATCH 1/3] platform: x86: dell-rbtn: Dell Airplane Mode Switch driver

2014-11-23 Thread Pali Rohár
This is an ACPI driver for Dell laptops which receive HW switch events. It exports rfkill device dell-rbtn which provide correct hard rfkill state. It does not provide support for setting soft rfkill state yet. Signed-off-by: Pali Rohár pali.ro...@gmail.com --- drivers/platform/x86/Kconfig