doc: improve the description of gpiod_line_event_read()
authorBartosz Golaszewski <bgolaszewski@baylibre.com>
Tue, 28 Apr 2020 11:24:19 +0000 (13:24 +0200)
committerBartosz Golaszewski <bgolaszewski@baylibre.com>
Tue, 28 Apr 2020 11:54:09 +0000 (13:54 +0200)
The description of gpiod_line_event_read() states that it reads the last
event that occurred for this line. This is not true: the kernel stores
the events in a FIFO and this function reads the next event from it.

Fix the confusing statement.

Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
include/gpiod.h

index 98203627e2f742edf108ceaa1ef19d407b1ed975..3af97c44fbd115f42088813cd83184945bf1276f 100644 (file)
@@ -1490,7 +1490,7 @@ int gpiod_line_event_wait_bulk(struct gpiod_line_bulk *bulk,
                               struct gpiod_line_bulk *event_bulk) GPIOD_API;
 
 /**
- * @brief Read the last event from the GPIO line.
+ * @brief Read next pending event from the GPIO line.
  * @param line GPIO line object.
  * @param event Buffer to which the event data will be copied.
  * @return 0 if the event was read correctly, -1 on error.