event: remove the line field from struct gpiod_line_event
authorBartosz Golaszewski <bartekgola@gmail.com>
Tue, 10 Jan 2017 10:11:00 +0000 (11:11 +0100)
committerBartosz Golaszewski <bartekgola@gmail.com>
Tue, 10 Jan 2017 10:11:00 +0000 (11:11 +0100)
This doesn't make sense - we know what line we're reading the event
from anyway.

Signed-off-by: Bartosz Golaszewski <bartekgola@gmail.com>
core.c
gpiod.h

diff --git a/core.c b/core.c
index 0d36bdddc79afd03f14d82278841e57302ab81c9..fa89110a833781b013048013b88c247c46744aa2 100644 (file)
--- a/core.c
+++ b/core.c
@@ -710,7 +710,6 @@ int gpiod_line_event_read(struct gpiod_line *line,
                return -1;
        }
 
-       event->line = line;
        event->event_type = evdata.id == GPIOEVENT_EVENT_RISING_EDGE
                                                ? GPIOD_EVENT_RISING_EDGE
                                                : GPIOD_EVENT_FALLING_EDGE;
diff --git a/gpiod.h b/gpiod.h
index 49bcd7f33b46fee64cd7b0fe790ac7bc62c6f221..21082833dc05244c9b5bf8dba004bf6ba5c4f679 100644 (file)
--- a/gpiod.h
+++ b/gpiod.h
@@ -490,8 +490,6 @@ struct gpiod_line_evreq_config {
  * @brief Structure holding event info.
  */
 struct gpiod_line_event {
-       struct gpiod_line *line;
-       /**< Line on which the event occurred. */
        struct timespec ts;
        /**< Best estimate of time of event occurrence. */
        int event_type;