You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by je...@apache.org on 2021/05/23 18:43:09 UTC

[incubator-nuttx] 04/07: boards: cxd56xx: Set the pin number to the argument of gpio handler

This is an automated email from the ASF dual-hosted git repository.

jerpelea pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git

commit 6cc60f3bd98f45215094c3788f54f4c6613fa2c7
Author: SPRESENSE <41...@users.noreply.github.com>
AuthorDate: Wed May 19 17:48:33 2021 +0900

    boards: cxd56xx: Set the pin number to the argument of gpio handler
    
    Make it easy to get the pin number on GPIO interrupt handler.
---
 boards/arm/cxd56xx/spresense/src/cxd56_gpioif.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/boards/arm/cxd56xx/spresense/src/cxd56_gpioif.c b/boards/arm/cxd56xx/spresense/src/cxd56_gpioif.c
index 236a34d..27c8415 100644
--- a/boards/arm/cxd56xx/spresense/src/cxd56_gpioif.c
+++ b/boards/arm/cxd56xx/spresense/src/cxd56_gpioif.c
@@ -188,7 +188,8 @@ int board_gpio_intconfig(uint32_t pin, int mode, bool filter, xcpt_t isr)
       gpiocfg |= GPIOINT_NOISE_FILTER_ENABLE;
     }
 
-  ret = cxd56_gpioint_config(pin, gpiocfg, isr, NULL);
+  ret = cxd56_gpioint_config(pin, gpiocfg, isr, (void *)pin);
+
   return ret;
 #else
   return -ENOTSUP;