From: Kent Gibson Date: Thu, 14 Jul 2022 02:03:15 +0000 (+0800) Subject: gpiolib: cdev: simplify parameter in call to hte_edge_setup X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=2487a812236cdeecd0729cfc673fa352db44da5d;p=linux.git gpiolib: cdev: simplify parameter in call to hte_edge_setup Improve readability by using the GPIO_V2_LINE_FLAG_EDGE_BOTH instead of combining the rising and falling edge flags. Signed-off-by: Kent Gibson Reviewed-by: Andy Shevchenko Acked-by: Dipen Patel Tested-by: Dipen Patel Reviewed-by: Linus Walleij Signed-off-by: Bartosz Golaszewski --- diff --git a/drivers/gpio/gpiolib-cdev.c b/drivers/gpio/gpiolib-cdev.c index b44526e3630ee..f635bbbb6a6d5 100644 --- a/drivers/gpio/gpiolib-cdev.c +++ b/drivers/gpio/gpiolib-cdev.c @@ -885,9 +885,7 @@ static int debounce_setup(struct line *line, return ret; line->irq = irq; } else { - ret = hte_edge_setup(line, - GPIO_V2_LINE_FLAG_EDGE_RISING | - GPIO_V2_LINE_FLAG_EDGE_FALLING); + ret = hte_edge_setup(line, GPIO_V2_LINE_FLAG_EDGE_BOTH); if (ret) return ret; }