Good bug hunting in this thread! Please see if you can use libgpiod or the tools from the kernel tools/gpio directory to test GPIO lines, I usually use that since the global GPIO numberspace only constantly confuse me.
Especially when there is a really many many GPIOs the local numberspace and the global GPIO numberspace approach the same values and I get totally lost sometimes. Yours, Linus Walleij