1 /* SPDX-License-Identifier: GPL-2.0-only OR MIT */
3 #include <device/mmio.h>
6 void *gpio_find_reg_addr(gpio_t gpio
)
9 switch (gpio
.base
& 0x0f) {
11 reg_addr
= (void *)IOCFG_BL_BASE
;
14 reg_addr
= (void *)IOCFG_BM_BASE
;
17 reg_addr
= (void *)IOCFG_BR_BASE
;
20 reg_addr
= (void *)IOCFG_LM_BASE
;
23 reg_addr
= (void *)IOCFG_RB_BASE
;
26 reg_addr
= (void *)IOCFG_TL_BASE
;