soc/intel/ptl: Update ME specification version to 21
[coreboot.git] / src / soc / mediatek / common / gpio_eint_v1.c
blob194dff45add61686bed4f04436c5c0d468a0748d
1 /* SPDX-License-Identifier: GPL-2.0-only */
3 #include <soc/addressmap.h>
4 #include <gpio.h>
6 void gpio_calc_eint_pos_bit(gpio_t gpio, u32 *pos, u32 *bit)
8 *pos = gpio.id / MAX_EINT_REG_BITS;
9 *bit = gpio.id % MAX_EINT_REG_BITS;
12 struct eint_regs *gpio_get_eint_reg(gpio_t gpio)
14 return (struct eint_regs *)(EINT_BASE);