Thread (4 messages) 4 messages, 2 authors, 2013-06-03
DORMANTno replies

Re: [PATCH v2] input: sirfsoc_pwrc: add onkey input driver for CSR SiRFprimaII PWRC

From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Date: 2013-06-03 06:38:41
Also in: linux-arm-kernel

On Tue, May 28, 2013 at 04:07:46PM +0800, Barry Song wrote:
2013/5/28 Dmitry Torokhov [off-list ref]:
quoted
Hi Barry,

On Tue, May 28, 2013 at 10:47:38AM +0800, Barry Song wrote:
quoted
+     /*
+      * For a typical Linux system, we report KEY_SUSPEND to trigger apm-power.c
+      * to queue a SUSPEND APM event
+      */
+     input_event(pwrcdrv->input, EV_PWR, KEY_SUSPEND, 1);
+     input_sync(pwrcdrv->input);
+
+     /*
+      * Todo: report KEY_POWER event for Android platforms, Android PowerManager
+      * will handle the suspend and powerdown/hibernation
+      */
+
...
quoted
+
+     pwrcdrv->input->evbit[0] = BIT_MASK(EV_PWR) | BIT_MASK(EV_KEY);
+     set_bit(KEY_POWER, pwrcdrv->input->keybit);
Why are we setting up KEY_POWER if we do not send this event?
For Android products, we send KEY_POWER to let Android PM trigger
SUSPEND. that is left to be done.
OK, but then we should be adding capabilities when we are ready to send
KEY_POWER events.

I'll apply without KEY_POWER.

Thanks.

-- 
Dmitry
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help