2 comments:
File src/mainboard/pcengines/apu2/gpio_ftns.c:
Patch Set #1, Line 13: if (gpio >= 0x300)
What is w/ this 0x300 check and how does it correspond 0x300? Seems we shouldn't be open coding any of this as the soc code should be bounds checking. If anything the bounds check should be on iomux_gpio. And really this code shouldn't be in here at all.
Patch Set #1, Line 16: return gpio0_read32(gpio & 0x3ff);
if a single namespace for gpios is intended to be used then gpioX_read() should be dropped entirely instead of implicitly assuming the memory map is contiguous.
To view, visit change 42521. To unsubscribe, or for help writing mail filters, visit settings.