acassis commented on PR #16223: URL: https://github.com/apache/nuttx/pull/16223#issuecomment-2809319506
> I'm not sure if expanding `/drivers/ioexpander/gpio.c` this way is a good idea. This driver is designed to support **single GPIO**. The interface for single GPIO is different and mutually exclusive with the interface to control many GPIOs. In your implementation, when `go_bundle_XXXX` is defined, all the rest of the operations in the gpio driver doesn't make sense. So what is the point of combining two not compatible implementations into one? > > The correct solution is a new driver, dedicated to control many GPIOs, maybe something like `gpiochip` in Linux. @eren-terzioglu I think @raiden00pl raised some important point here. Another thing that I noticed is the way it was implemented this solution seems ESP-specific. The right solution should be creating ARCH_HAS_GPIO_GROUPING and also the gpio example should have been modified to support it. I think GPIO grouping is more common term than bundle. If you decide to create a new driver, I suggest something like iogroup, gpiowide or par_io, it should be more appropriated, gpiochip that Raiden suggested is not self-explanatory. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org