From: Jonathan Cameron <jic23@kernel.org>
To: David Lechner <david@lechnology.com>
Cc: kamel.bouhara@bootlin.com, gwendal@chromium.org,
alexandre.torgue@st.com, felipe.balbi@linux.intel.com,
linux-iio@vger.kernel.org, syednwaris@gmail.com,
William Breathitt Gray <vilhelm.gray@gmail.com>,
linux-kernel@vger.kernel.org, alexandre.belloni@bootlin.com,
mcoquelin.stm32@gmail.com, patrick.havelange@essensium.com,
fabrice.gasnier@st.com, fabien.lahoudere@collabora.com,
linux-stm32@st-md-mailman.stormreply.com,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 0/4] Introduce the Counter character device interface
Date: Sun, 3 May 2020 15:52:45 +0100 [thread overview]
Message-ID: <20200503155245.08916211@archlinux> (raw)
In-Reply-To: <a6402ade-648d-6e49-85cd-a7fd7f58fd1d@lechnology.com>
On Wed, 29 Apr 2020 15:21:05 -0500
David Lechner <david@lechnology.com> wrote:
> On 4/29/20 1:11 PM, William Breathitt Gray wrote:
> > Over the past couple years we have noticed some shortcomings with the
> > Counter sysfs interface. Although useful in the majority of situations,
> > there are certain use-cases where interacting through sysfs attributes
> > can become cumbersome and inefficient. A desire to support more advanced
> > functionality such as timestamps, multi-axis positioning tables, and
> > other such latency-sensitive applications, has motivated a reevaluation
> > of the Counter subsystem. I believe a character device interface will be
> > helpful for this more niche area of counter device use.
>
> Nice to see some progress being made. :-)
>
> >
> > Interaction with Counter character devices occurs via ioctl commands.
> > This allows userspace applications to access and set counter data using
> > native C datatypes rather than working through string translations.
>
> For most aspects of the counter subsystem, this is not an issue since
> configuring a counter is not a time-sensitive operation. Instead of
> ioctls, I was expecting to just be able to read the character device
> and receive counter events or poll to wait for events similar to how
> the input subsystem works or how buffers work in the iio subsystem.
>
> I'm afraid I don't really see much use in having ioctls that do
> exactly what sysfs already does. And my intuition tells me that the
> extra work needed to maintain it will probably cost more than any
> benefit gained. (Maybe other have a different experience that leads
> to a different conclusion?)
I agree with David here. The ioctls are currently doing what could have
been done nicely with a userspace library. Moving away from the string
based internal interface is a good move to my mind, because it ensures
consistency in they sysfs interface and provides for in kernel users
when they make sense. The step of then using that to simplify providing
an IOCTL interface to do the same things doesn't seem particularly useful.
So what do we gain?
Jonathan
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2020-05-03 14:52 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-29 18:11 [PATCH 0/4] Introduce the Counter character device interface William Breathitt Gray
2020-04-29 18:11 ` [PATCH 2/4] docs: counter: Update to reflect sysfs internalization William Breathitt Gray
2020-04-29 18:11 ` [PATCH 3/4] counter: Add character device interface William Breathitt Gray
2020-04-29 18:11 ` [PATCH 4/4] docs: counter: Document " William Breathitt Gray
2020-04-29 20:21 ` [PATCH 0/4] Introduce the Counter " David Lechner
2020-05-03 14:52 ` Jonathan Cameron [this message]
2020-04-30 20:13 ` Alexandre Belloni
2020-05-01 15:46 ` William Breathitt Gray
2020-05-02 16:55 ` Jonathan Cameron
2020-05-03 9:23 ` Greg Kroah-Hartman
2020-05-03 12:54 ` Jonathan Cameron
2020-05-03 13:16 ` William Breathitt Gray
2020-05-03 15:05 ` Jonathan Cameron
2020-05-03 14:13 ` Jonathan Cameron
2020-05-03 14:21 ` David Laight
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=20200503155245.08916211@archlinux \
--to=jic23@kernel.org \
--cc=alexandre.belloni@bootlin.com \
--cc=alexandre.torgue@st.com \
--cc=david@lechnology.com \
--cc=fabien.lahoudere@collabora.com \
--cc=fabrice.gasnier@st.com \
--cc=felipe.balbi@linux.intel.com \
--cc=gwendal@chromium.org \
--cc=kamel.bouhara@bootlin.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-stm32@st-md-mailman.stormreply.com \
--cc=mcoquelin.stm32@gmail.com \
--cc=patrick.havelange@essensium.com \
--cc=syednwaris@gmail.com \
--cc=vilhelm.gray@gmail.com \
/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;
as well as URLs for NNTP newsgroup(s).