Re: [PATCH v9 8/8] Loongson: YeeLoong: add input/hotkey driver

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

 



On Tue, 2009-12-08 at 22:15 +0800, Wu Zhangjin wrote:
> From: Wu Zhangjin <wuzhangjin@xxxxxxxxx>
> 
> This patch adds Hotkey Driver, which will do related actions for The
> hotkey event(/sys/class/input) and report the corresponding input keys
> to the user-space applications.
> 
> [NOTE:
> 
> This patch is based on the sparse keymap library in:
> 
> git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input next
> 
> of Dmitry Torokhov. that sparse keymap support is also queued for
> 2.6.33. Before the above branch is pulled by linus, this patch is not
> appliable.]
> 
[...]
> +
> +/* yeeloong_wifi_handler may be implemented in the wifi driver */
> +sci_handler yeeloong_wifi_handler;
> +EXPORT_SYMBOL(yeeloong_wifi_handler);
> +

Because we have reported the KEY_WLAN to user-space and If we provide
the standard rfkill interfaces too, there is no need to handle the Fn+F5
event in kernel space, will remove the above three lines the following
related source code.

> +static void do_event_action(int event)
> +{
> +	sci_handler handler;
> +	int reg, status;
> +	struct key_entry *ke;
> +
> +	reg = 0;
> +	handler = NULL;
> +
> +	switch (event) {
[...]
> +	case EVENT_WLAN:
> +		/* We use 2 to indicate it as a switch */
> +		status = 2;
> +		handler = yeeloong_wifi_handler;
> +		break;

Will remove it and send the this patch as v10 later.

Best Regards,
	Wu Zhangjin



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux