[lkml]   [2011]   [Apr]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRE: [PATCH 01/13] input: touchscreen: use polling mode in 88pm860x

>-----Original Message-----
>From: []
>Sent: 2011年4月16日 10:17 PM
>To: Haojian Zhuang
>Cc:;; linux-
>; Dmitry Torokhov
>Subject: Re: [PATCH 01/13] input: touchscreen: use polling mode in
>On Sat, 16 Apr 2011 20:46:20 +0800, Haojian Zhuang said:
>> Measuring point on touchscreen with IRQ mode can only monitor pen-down
>> event. If finger is moving on touchscreen, it can't be monitored by
>> IRQ pen-down event. So switch to polling mode after pen-down event.
>> drivers/input/touchscreen/88pm860x-ts.c | 79
>> +/*
>> + * While 32KHz hardware timer is used for scheduler, we always assign
>> + * to 128. It means that 1 tick costs 7.8msec.
>> + */
>> +#define MEASURE_INTERVAL_MS (7)
>Is it guaranteed that this hardware part will only ever be used on
>where this is true? How big a bug would it be if somebody tried to glue
>touchscreen into some random embedded-ARM where HZ was something else,
>should this be computed as a function of HZ instead of hardcoding 7?
It's 7msec whatever you choose any silicon. So it's not a problem.

>It *looks* like the intent of the schedule_delayed_work() call is "let's
>this once a tick when we're awake *anyhow*" - but looking at the code, I
>convince myself a rounding error in computing 'interval' won't schedule
>before or after the next tick would have been. Isn't there a better API
>slack timers or something that would do a better "next tick" job?

 \ /
  Last update: 2011-04-18 15:15    [from the cache]
©2003-2014 Jasper Spaans. hosted at Digital Ocean