| /f-stack/freebsd/arm/ti/am335x/ |
| H A D | am335x_gpio.c | 89 if (flags & GPIO_PIN_OUTPUT) { in am335x_gpio_set_flags() 117 *flags = GPIO_PIN_OUTPUT; in am335x_gpio_get_flags() 120 *flags = GPIO_PIN_OUTPUT | GPIO_PIN_PULLUP; in am335x_gpio_get_flags()
|
| /f-stack/freebsd/mips/atheros/ar531x/ |
| H A D | ar5315_gpio.c | 58 #define DEFAULT_CAPS (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT) 122 if (flags & (GPIO_PIN_INPUT|GPIO_PIN_OUTPUT)) { in ar5315_gpio_pin_configure() 123 pin->gp_flags &= ~(GPIO_PIN_INPUT|GPIO_PIN_OUTPUT); in ar5315_gpio_pin_configure() 124 if (flags & GPIO_PIN_OUTPUT) { in ar5315_gpio_pin_configure() 125 pin->gp_flags |= GPIO_PIN_OUTPUT; in ar5315_gpio_pin_configure() 191 *flags = dir ? GPIO_PIN_OUTPUT : GPIO_PIN_INPUT; in ar5315_gpio_pin_getflags() 409 sc->gpio_pins[i].gp_flags = GPIO_PIN_OUTPUT; in ar5315_gpio_attach() 420 ar5315_gpio_pin_setflags(dev, j, GPIO_PIN_OUTPUT); in ar5315_gpio_attach()
|
| /f-stack/freebsd/arm/freescale/vybrid/ |
| H A D | vf_gpio.c | 73 #define DEFAULT_CAPS (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT) 148 GPIO_PIN_OUTPUT: GPIO_PIN_INPUT; in vf_gpio_attach() 301 if (flags & (GPIO_PIN_INPUT|GPIO_PIN_OUTPUT)) { in vf_gpio_pin_configure() 302 pin->gp_flags &= ~(GPIO_PIN_INPUT|GPIO_PIN_OUTPUT); in vf_gpio_pin_configure() 303 if (flags & GPIO_PIN_OUTPUT) { in vf_gpio_pin_configure() 304 pin->gp_flags |= GPIO_PIN_OUTPUT; in vf_gpio_pin_configure()
|
| /f-stack/freebsd/mips/atheros/ |
| H A D | ar71xx_gpio.c | 64 #define DEFAULT_CAPS (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT) 199 if (flags & (GPIO_PIN_INPUT|GPIO_PIN_OUTPUT)) { in ar71xx_gpio_pin_configure() 200 pin->gp_flags &= ~(GPIO_PIN_INPUT|GPIO_PIN_OUTPUT); in ar71xx_gpio_pin_configure() 201 if (flags & GPIO_PIN_OUTPUT) { in ar71xx_gpio_pin_configure() 202 pin->gp_flags |= GPIO_PIN_OUTPUT; in ar71xx_gpio_pin_configure() 522 sc->gpio_pins[i].gp_flags = GPIO_PIN_OUTPUT; in ar71xx_gpio_attach() 532 ar71xx_gpio_pin_setflags(dev, j, GPIO_PIN_OUTPUT); in ar71xx_gpio_attach()
|
| /f-stack/freebsd/arm/ti/omap4/ |
| H A D | omap4_gpio.c | 84 if (flags & GPIO_PIN_OUTPUT) in omap4_gpio_set_flags() 112 *flags = GPIO_PIN_OUTPUT; in omap4_gpio_get_flags()
|
| /f-stack/freebsd/arm/xilinx/ |
| H A D | zy7_gpio.c | 144 *caps = (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | GPIO_PIN_TRISTATE); in zy7_gpio_pin_getcaps() 182 *flags = (GPIO_PIN_OUTPUT | GPIO_PIN_TRISTATE); in zy7_gpio_pin_getflags() 184 *flags = GPIO_PIN_OUTPUT; in zy7_gpio_pin_getflags() 205 if ((flags & GPIO_PIN_OUTPUT) != 0) { in zy7_gpio_pin_setflags()
|
| /f-stack/freebsd/mips/cavium/ |
| H A D | octeon_gpio.c | 60 #define DEFAULT_CAPS (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT) 120 if (flags & (GPIO_PIN_INPUT|GPIO_PIN_OUTPUT)) { in octeon_gpio_pin_configure() 122 pin->gp_flags &= ~(GPIO_PIN_INPUT|GPIO_PIN_OUTPUT); in octeon_gpio_pin_configure() 123 if (flags & GPIO_PIN_OUTPUT) { in octeon_gpio_pin_configure() 124 pin->gp_flags |= GPIO_PIN_OUTPUT; in octeon_gpio_pin_configure()
|
| /f-stack/freebsd/arm64/qoriq/ |
| H A D | ls1046_gpio.c | 59 (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | \ 200 if (((flags & GPIO_PIN_INPUT) && (flags & GPIO_PIN_OUTPUT)) || in qoriq_gpio_configure() 211 if (flags & GPIO_PIN_OUTPUT) { in qoriq_gpio_configure() 212 newflags = GPIO_PIN_OUTPUT; in qoriq_gpio_configure() 471 newflags[i] = GPIO_PIN_OUTPUT; in qoriq_gpio_pin_config_32()
|
| /f-stack/freebsd/arm/freescale/imx/ |
| H A D | imx_gpio.c | 100 #define DEFAULT_CAPS (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | \ 104 #define DEFAULT_CAPS (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT) 542 if (flags & (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT)) { in imx51_gpio_pin_configure() 543 newflags = pin->gp_flags & ~(GPIO_PIN_INPUT | GPIO_PIN_OUTPUT); in imx51_gpio_pin_configure() 544 if (flags & GPIO_PIN_OUTPUT) { in imx51_gpio_pin_configure() 556 newflags |= GPIO_PIN_OUTPUT; in imx51_gpio_pin_configure() 762 } else if (flags & GPIO_PIN_OUTPUT) { in imx51_gpio_pin_config_32() 856 (READ4(sc, IMX_GPIO_OE_REG) & (1U << i)) ? GPIO_PIN_OUTPUT : in imx51_gpio_attach()
|
| H A D | imx_i2c.c | 453 gpio_pin_setflags(sc->rb_sclpin, GPIO_PIN_OUTPUT); in i2c_attach() 454 gpio_pin_setflags(sc->rb_sdapin, GPIO_PIN_OUTPUT); in i2c_attach()
|
| /f-stack/freebsd/arm64/rockchip/ |
| H A D | rk_gpio.c | 73 #define RK_GPIO_DEFAULT_CAPS (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | \ 251 *flags |= GPIO_PIN_OUTPUT; in rk_gpio_pin_getflags() 291 else if (flags & GPIO_PIN_OUTPUT) in rk_gpio_pin_setflags() 400 } else if (flags & GPIO_PIN_OUTPUT) { in rk_gpio_pin_config_32()
|
| /f-stack/freebsd/arm/mv/ |
| H A D | a37x0_gpio.c | 134 *caps = GPIO_PIN_INPUT | GPIO_PIN_OUTPUT; in a37x0_gpio_pin_getcaps() 150 *flags = GPIO_PIN_OUTPUT; in a37x0_gpio_pin_getflags() 168 if (flags & GPIO_PIN_OUTPUT) in a37x0_gpio_pin_setflags()
|
| H A D | mvebu_gpio.c | 157 if ((flags & (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT)) == 0) in mvebu_gpio_pin_configure() 161 pin->gp_flags &= ~(GPIO_PIN_INPUT | GPIO_PIN_OUTPUT); in mvebu_gpio_pin_configure() 162 if (flags & GPIO_PIN_OUTPUT) { in mvebu_gpio_pin_configure() 163 pin->gp_flags |= GPIO_PIN_OUTPUT; in mvebu_gpio_pin_configure() 768 pin->gp_caps = GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | in mvebu_gpio_attach() 772 pin->gp_caps = GPIO_PIN_INPUT | GPIO_PIN_OUTPUT; in mvebu_gpio_attach() 775 GPIO_PIN_OUTPUT : GPIO_PIN_INPUT; in mvebu_gpio_attach()
|
| H A D | gpio.c | 65 #define GPIO_GENERIC_CAP (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | \ 560 if (((flags & mask) & (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT)) == in mv_gpio_configure() 561 (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT)) in mv_gpio_configure() 576 if ((mask & flags) & GPIO_PIN_OUTPUT) { in mv_gpio_configure()
|
| /f-stack/freebsd/arm/broadcom/bcm2835/ |
| H A D | raspberrypi_gpio.c | 54 #define RPI_FW_GPIO_DEFAULT_CAPS (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT) 97 } else if (flags & GPIO_PIN_OUTPUT) { in rpi_fw_gpio_pin_configure() 114 pin->gp_flags = GPIO_PIN_OUTPUT; in rpi_fw_gpio_pin_configure() 403 sc->sc_gpio_pins[i].gp_flags = GPIO_PIN_OUTPUT; in rpi_fw_gpio_attach()
|
| H A D | bcm2835_gpio.c | 70 #define BCM_GPIO_DEFAULT_CAPS (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | \ 266 return (GPIO_PIN_OUTPUT); in bcm_gpio_func_flag() 337 if (flags & (GPIO_PIN_INPUT|GPIO_PIN_OUTPUT)) { in bcm_gpio_pin_configure() 338 pin->gp_flags &= ~(GPIO_PIN_INPUT|GPIO_PIN_OUTPUT); in bcm_gpio_pin_configure() 339 if (flags & GPIO_PIN_OUTPUT) { in bcm_gpio_pin_configure() 340 pin->gp_flags |= GPIO_PIN_OUTPUT; in bcm_gpio_pin_configure()
|
| /f-stack/freebsd/mips/ingenic/ |
| H A D | jz4780_gpio.c | 155 sc->pins[pin].pin_flags &= ~(GPIO_PIN_INPUT | GPIO_PIN_OUTPUT); in jz4780_gpio_pin_set_func() 167 case GPIO_PIN_OUTPUT: in jz4780_gpio_pin_set_direction() 181 sc->pins[pin].pin_flags &= ~(GPIO_PIN_INPUT | GPIO_PIN_OUTPUT); in jz4780_gpio_pin_set_direction() 267 sc->pins[pin].pin_flags |= GPIO_PIN_OUTPUT; in jz4780_gpio_pin_probe() 332 sc->pins[i].pin_caps |= GPIO_PIN_INPUT | GPIO_PIN_OUTPUT; in jz4780_gpio_attach() 480 flags & (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT)); in jz4780_gpio_pin_setflags() 546 sc->pins[pin].pin_flags & GPIO_PIN_OUTPUT) { in jz4780_gpio_pin_toggle()
|
| /f-stack/freebsd/arm/nvidia/ |
| H A D | as3722_gpio.c | 358 flags = GPIO_PIN_OUTPUT; in as3722_gpio_pin_getflags() 362 flags = GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | GPIO_PIN_OPENDRAIN; in as3722_gpio_pin_getflags() 372 flags = GPIO_PIN_OUTPUT | GPIO_PIN_PULLDOWN; in as3722_gpio_pin_getflags() 560 pin->pin_caps = GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | in as3722_gpio_attach()
|
| H A D | tegra_gpio.c | 178 if ((flags & (GPIO_PIN_INPUT|GPIO_PIN_OUTPUT)) == 0) in tegra_gpio_pin_configure() 182 pin->gp_flags &= ~(GPIO_PIN_INPUT | GPIO_PIN_OUTPUT); in tegra_gpio_pin_configure() 183 if (flags & GPIO_PIN_OUTPUT) { in tegra_gpio_pin_configure() 184 pin->gp_flags |= GPIO_PIN_OUTPUT; in tegra_gpio_pin_configure() 776 sc->gpio_pins[i].gp_caps = GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | in tegra_gpio_attach() 785 GPIO_PIN_OUTPUT : GPIO_PIN_INPUT; in tegra_gpio_attach()
|
| /f-stack/freebsd/mips/mediatek/ |
| H A D | mtk_gpio_v2.c | 188 sc->pins[pin].pin_flags &= ~(GPIO_PIN_INPUT | GPIO_PIN_OUTPUT); in mtk_gpio_pin_set_direction() 234 sc->pins[pin].pin_flags |= GPIO_PIN_OUTPUT; in mtk_gpio_pin_probe() 285 sc->pins[i].pin_caps |= GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | in mtk_gpio_attach() 416 flags & (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT)); in mtk_gpio_pin_setflags() 482 if(!(sc->pins[pin].pin_flags & GPIO_PIN_OUTPUT)) { in mtk_gpio_pin_toggle()
|
| H A D | mtk_gpio_v1.c | 197 sc->pins[pin].pin_flags &= ~(GPIO_PIN_INPUT | GPIO_PIN_OUTPUT); in mtk_gpio_pin_set_direction() 243 sc->pins[pin].pin_flags |= GPIO_PIN_OUTPUT; in mtk_gpio_pin_probe() 294 sc->pins[i].pin_caps |= GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | in mtk_gpio_attach() 426 flags & (GPIO_PIN_INPUT | GPIO_PIN_OUTPUT)); in mtk_gpio_pin_setflags() 491 if (!(sc->pins[pin].pin_flags & GPIO_PIN_OUTPUT)) { in mtk_gpio_pin_toggle()
|
| /f-stack/freebsd/arm64/nvidia/tegra210/ |
| H A D | max77620_gpio.c | 472 *out_flags |= GPIO_PIN_OUTPUT; in max77620_gpio_get_mode() 474 *out_flags |= GPIO_PIN_OUTPUT | GPIO_PIN_INPUT; in max77620_gpio_get_mode() 553 } else if (((flags & GPIO_PIN_OUTPUT) && in max77620_gpio_pin_setflags() 708 pin->pin_caps = GPIO_PIN_INPUT | GPIO_PIN_OUTPUT | in max77620_gpio_attach()
|
| /f-stack/freebsd/sys/ |
| H A D | gpio.h | 69 #define GPIO_PIN_OUTPUT 0x00000002 /* output direction */ macro
|
| /f-stack/freebsd/arm/allwinner/ |
| H A D | axp209.c | 937 *caps = GPIO_PIN_INPUT | GPIO_PIN_OUTPUT; in axp2xx_gpio_pin_getcaps() 962 *flags = GPIO_PIN_OUTPUT; in axp2xx_gpio_pin_getflags() 987 if ((flags & (GPIO_PIN_INPUT|GPIO_PIN_OUTPUT)) != 0) { in axp2xx_gpio_pin_setflags() 988 if ((flags & GPIO_PIN_OUTPUT) == 0) in axp2xx_gpio_pin_setflags()
|
| H A D | axp81x.c | 1187 *caps = GPIO_PIN_INPUT | GPIO_PIN_OUTPUT; in axp8xx_gpio_pin_getcaps() 1212 *flags = GPIO_PIN_OUTPUT; in axp8xx_gpio_pin_getflags() 1237 if ((flags & (GPIO_PIN_INPUT|GPIO_PIN_OUTPUT)) != 0) { in axp8xx_gpio_pin_setflags() 1238 if ((flags & GPIO_PIN_OUTPUT) == 0) in axp8xx_gpio_pin_setflags()
|