Why is the /dev/gpiochip line event kfifo so small?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I was looking into using the /dev/gpiochip API to detect pulses. In my
application, the crucial bit is to precisely identify the start time of
the pule and the API mostly helps doing that by providing high precision
kernel timestamps. However, it stuffs them into a kfifo with 16 entries.
When your hardware is not properly debounced (which it always should,
but often isn't), that space can fill quickly. Is there a reason to
limit the API to such a small number of events?

A single event is 16 bytes. So for every line, we incur 256 bytes of
kfifo space. This space is only incurred for lines that are actually
being watched. It seems to me that bumping up this size would not hurt
badly. Non-realtime applications could then read events after-the-fact
with a smaller risk of missing ones. I've encountered a full kfifo a
number of times now.

Helmut



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux