aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input
diff options
context:
space:
mode:
authorVishnudev Ramakrishnan <vramakri@sta.samsung.com>2011-10-12 17:16:37 -0700
committerArve Hjønnevåg <arve@android.com>2011-11-17 17:54:42 -0800
commitd9c6617a5f50470926bae896bfd8f918c7bd99fe (patch)
treeb27893b259d44533bf91265175d217991bc6c6d2 /drivers/input
parent7913941122fe09636297da3b656d4af4e46d952a (diff)
downloadkernel_samsung_aries-d9c6617a5f50470926bae896bfd8f918c7bd99fe.zip
kernel_samsung_aries-d9c6617a5f50470926bae896bfd8f918c7bd99fe.tar.gz
kernel_samsung_aries-d9c6617a5f50470926bae896bfd8f918c7bd99fe.tar.bz2
gp2a: report light sensor value on enable
Driver changes to make light sensor value to be reported on enabling light sensor. - On enable, push a dummy value -1 to input subsystem Change-Id: Icd154fc04ef78fcae2eadfde280abe19da6a7b2a Signed-off-by: Vishnudev Ramakrishnan <vramakri@sta.samsung.com>
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/misc/gp2a.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/input/misc/gp2a.c b/drivers/input/misc/gp2a.c
index 04db6ed..2fa6453 100644
--- a/drivers/input/misc/gp2a.c
+++ b/drivers/input/misc/gp2a.c
@@ -131,6 +131,8 @@ static void gp2a_light_enable(struct gp2a_data *gp2a)
{
gp2a_dbgmsg("starting poll timer, delay %lldns\n",
ktime_to_ns(gp2a->light_poll_delay));
+ /* push -1 to input subsystem to enable real value to go through next */
+ input_report_abs(gp2a->light_input_dev, ABS_MISC, -1);
hrtimer_start(&gp2a->timer, gp2a->light_poll_delay, HRTIMER_MODE_REL);
}