Re: [PATCH] eeepc-wmi: Add backlight support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Apr 7, 2010 at 4:17 PM, Yong Wang <yong.y.wang@xxxxxxxxxxxxxxx> wrote:
> Add backlight support for WMI based Eee PC laptops. In addition, start
> to use a platform device to manage all functional devices as more
> features will be implemented later.
>
> +static struct platform_device *eeepc_wmi_platform_device;
>  static struct input_dev *eeepc_wmi_input_dev;
> +struct backlight_device *eeepc_wmi_backlight_device;

Instead of using static variables, you should really use a struct
eeepc_wmi, store stuff inside it,
and make all these functions reentrant. Alan did it for eeepc-laptop,
and I did it for asus-laptop,
see http://git.iksaif.net/?p=acpi4asus.git;a=commit;h=854c78363f37f03e30e2856ef17d7eefc62e0d06
.
The driver would really be cleaner and easier to review with that. And
it would be more coherent with
eeepc-laptop's code.

-- 
Corentin Chary
http://xf.iksaif.net
--
To unsubscribe from this list: send the line "unsubscribe platform-driver-x86" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux