Messages in this thread | | | Subject | Re: [PATCH v4 3/5] counter: Add character device interface | From | David Lechner <> | Date | Thu, 30 Jul 2020 17:49:37 -0500 |
| |
On 7/28/20 7:20 PM, David Lechner wrote: > On 7/21/20 2:35 PM, William Breathitt Gray wrote: >> This patch introduces a character device interface for the Counter >> subsystem. Device data is exposed through standard character device read >> operations. Device data is gathered when a Counter event is pushed by >> the respective Counter device driver. Configuration is handled via ioctl >> operations on the respective Counter character device node. > > This sounds similar to triggers and buffers in the iio subsystem. And > I can see how it might be useful in some cases. But I think it would not > give the desired results when performance is important. >
By the way, I really appreciate the work you have done here. When reviewing code, it is easy to point out what is wrong or we don't like and to not mention all the parts that are good. And there is a lot of really good work here already.
I've been working on this all week to try out some of my suggestions and I'm not getting very far. This is a very difficult problem to solve!
I just wanted to mention this since I responded to this patch series already but I am still learning and trying things. So I may have more/ different feedback in the future and I may decide some of my suggestions are not so good. :-)
And one more thing, there was a nice talk at the Embedded Linux Conference last month about lessons learned from designing a userspace API for the GPIO subsystem [1]. Unfortunately, there is no video yet, but the slides might have some helpful ideas about mistakes to avoid.
[1]: https://elinux.org/ELC_2020_Presentations
| |