From: dmitry.torokhov@gmail.com
To: "Michał Mirosław" <mirq-linux@rere.qmqm.pl>
Cc: Jonathan Cameron <jic23@kernel.org>,
Hartmut Knaack <knaack.h@gmx.de>,
Lars-Peter Clausen <lars@metafoo.de>,
Peter Meerwald-Stadler <pmeerw@pmeerw.net>,
Kukjin Kim <kgene@kernel.org>,
Krzysztof Kozlowski <krzk@kernel.org>,
Andrzej Pietrasiewicz <andrzej.p@collabora.com>,
linux-iio@vger.kernel.org, linux-samsung-soc@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] iio: adc: exynos: do not rely on 'users' counter in ISR
Date: Mon, 5 Oct 2020 17:34:00 -0700 [thread overview]
Message-ID: <20201006003400.GN1009802@dtor-ws> (raw)
In-Reply-To: <20201005190010.GA29936@qmqm.qmqm.pl>
On Mon, Oct 05, 2020 at 09:00:10PM +0200, Michał Mirosław wrote:
> On Mon, Oct 05, 2020 at 10:36:36AM -0700, dmitry.torokhov@gmail.com wrote:
> > Hi Michał,
> >
> > On Mon, Oct 05, 2020 at 01:09:08PM +0200, Michał Mirosław wrote:
> > > and breaking the loop will desync touch
> > > state (I would guess this would be noticable by next user).
> > Upon next open driver will service the interrupt and provide new set of
> > touch coordinates. Userspace is supposed to query current state of
> > device when opening it before starting processing events. Or you are
> > concerned about some other state?
>
> From the code I would expect that there is a slight window, wher when the
> user releases the touch between close() and open(), the client that open()s
> will see a 'pressed' state until the ISR runs again (probably immediately
> because of pending interrupt). OTOH, maybe the app should be prepared
> for that anyway?
I think users should be prepared for it. There could be many users, so
anyone opening interface device (evdev or similar) can not expect that
the hardware device is in a quiesce state; it could just happen that
finger was on the surface and will be released as someone is opening the
device anyway.
Thanks.
--
Dmitry
prev parent reply other threads:[~2020-10-06 0:34 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-05 5:24 [PATCH] iio: adc: exynos: do not rely on 'users' counter in ISR dmitry.torokhov
2020-10-05 8:32 ` Krzysztof Kozlowski
2020-10-05 11:09 ` Michał Mirosław
2020-10-05 17:36 ` dmitry.torokhov
2020-10-05 19:00 ` Michał Mirosław
2020-10-06 0:34 ` dmitry.torokhov [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201006003400.GN1009802@dtor-ws \
--to=dmitry.torokhov@gmail.com \
--cc=andrzej.p@collabora.com \
--cc=jic23@kernel.org \
--cc=kgene@kernel.org \
--cc=knaack.h@gmx.de \
--cc=krzk@kernel.org \
--cc=lars@metafoo.de \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-samsung-soc@vger.kernel.org \
--cc=mirq-linux@rere.qmqm.pl \
--cc=pmeerw@pmeerw.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox