From 539366efe56bb94940eca9818b7681292ed0ab89 Mon Sep 17 00:00:00 2001 From: "Hans J. Koch" Date: Sun, 12 Jul 2009 20:51:25 -0700 Subject: [PATCH] --- yaml --- r: 161253 b: refs/heads/master c: f9c22736940cdc8f5e2db0109fc9493e0cbd895d h: refs/heads/master i: 161251: b63e4949194d2841fd00a0da48d272e9f5e6c9c8 v: v3 --- [refs] | 2 +- trunk/drivers/input/touchscreen/ucb1400_ts.c | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index cd35c7ece07c..82ff7a86a438 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: f7370699fbbb18f97442d6f47cc2d478a911ad6f +refs/heads/master: f9c22736940cdc8f5e2db0109fc9493e0cbd895d diff --git a/trunk/drivers/input/touchscreen/ucb1400_ts.c b/trunk/drivers/input/touchscreen/ucb1400_ts.c index 6954f5500108..e85483578bd4 100644 --- a/trunk/drivers/input/touchscreen/ucb1400_ts.c +++ b/trunk/drivers/input/touchscreen/ucb1400_ts.c @@ -128,9 +128,10 @@ static inline unsigned int ucb1400_ts_read_yres(struct ucb1400_ts *ucb) return ucb1400_adc_read(ucb->ac97, 0, adcsync); } -static inline int ucb1400_ts_pen_down(struct snd_ac97 *ac97) +static inline int ucb1400_ts_pen_up(struct snd_ac97 *ac97) { unsigned short val = ucb1400_reg_read(ac97, UCB_TS_CR); + return val & (UCB_TS_CR_TSPX_LOW | UCB_TS_CR_TSMX_LOW); } @@ -209,7 +210,7 @@ static int ucb1400_ts_thread(void *_ucb) msleep(10); - if (ucb1400_ts_pen_down(ucb->ac97)) { + if (ucb1400_ts_pen_up(ucb->ac97)) { ucb1400_ts_irq_enable(ucb->ac97); /*