lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 3 Nov 2017 14:50:52 +0200
From:   Andy Shevchenko <andy.shevchenko@...il.com>
To:     Guillaume Douézan-Grard 
        <gdouezangrard@...il.com>
Cc:     Andy Shevchenko <andy@...radead.org>,
        Darren Hart <dvhart@...radead.org>,
        Platform Driver <platform-driver-x86@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2 4/4] platform/x86: topstar-laptop: add optional WLAN
 LED workaround

On Sun, Oct 29, 2017 at 1:53 AM, Guillaume Douézan-Grard
<gdouezangrard@...il.com> wrote:
> Topstar U931 laptops provide an LED synced with the WLAN adapter
> hard-blocking state. Unfortunately, some models seem to be defective,
> making impossible to hard-block the adapter with the WLAN switch and
> thus the LED is useless.
>
> An ACPI method is available to programmatically control this switch and
> it indirectly allows to control the LED.
>
> This commit registers the LED within the corresponding subsystem, making
> possible for instance to use an rfkill-based trigger to synchronize the
> LED with the soft-blocking state.
>
> This feature is disabled by default and can be enabled with the
> `led_workaround` module parameter.

>  #include <linux/platform_device.h>
>  #include <linux/input.h>
>  #include <linux/input/sparse-keymap.h>
> +#include <linux/leds.h>

Yep, exact place, esp. after moving platform_device to the right place.

> +static bool led_workaround;
> +module_param_named(led_workaround, led_workaround, bool, 0444);
> +MODULE_PARM_DESC(led_workaround,
> +               "Enables software-based WLAN LED control on systems with defective hardware switch");

So, this is most problematic piece in the series.

We are not encouraging module parameters. Why do we need one? Can't be
detected automatically (perhaps based on DMI strings)?

-- 
With Best Regards,
Andy Shevchenko

Powered by blists - more mailing lists