From: Bartosz Golaszewski Date: Thu, 13 Jul 2017 16:07:25 +0000 (+0200) Subject: core: fix single line event requests with flags X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=2ac43f80d5491dced058332b17990f58e3a74a73;p=qemu-gpiodev%2Flibgpiod.git core: fix single line event requests with flags We currently always request rising edge events for the 'flags' variants. Request correct event types. Signed-off-by: Bartosz Golaszewski --- diff --git a/src/lib/core.c b/src/lib/core.c index 4a2ef84..b3b16e5 100644 --- a/src/lib/core.c +++ b/src/lib/core.c @@ -636,14 +636,14 @@ int gpiod_line_request_falling_edge_events_flags(struct gpiod_line *line, int flags) { return line_event_request_type(line, consumer, flags, - GPIOD_REQUEST_EVENT_RISING_EDGE); + GPIOD_REQUEST_EVENT_FALLING_EDGE); } int gpiod_line_request_both_edges_events_flags(struct gpiod_line *line, const char *consumer, int flags) { return line_event_request_type(line, consumer, flags, - GPIOD_REQUEST_EVENT_RISING_EDGE); + GPIOD_REQUEST_EVENT_BOTH_EDGES); } int gpiod_line_request_bulk(struct gpiod_line_bulk *bulk,