/linux-2.6.39/sound/soc/ |
D | soc-jack.c | 295 struct snd_soc_jack_gpio *gpios) in snd_soc_jack_add_gpios() argument 300 if (!gpio_is_valid(gpios[i].gpio)) { in snd_soc_jack_add_gpios() 302 gpios[i].gpio); in snd_soc_jack_add_gpios() 306 if (!gpios[i].name) { in snd_soc_jack_add_gpios() 308 gpios[i].gpio); in snd_soc_jack_add_gpios() 313 ret = gpio_request(gpios[i].gpio, gpios[i].name); in snd_soc_jack_add_gpios() 317 ret = gpio_direction_input(gpios[i].gpio); in snd_soc_jack_add_gpios() 321 INIT_DELAYED_WORK(&gpios[i].work, gpio_work); in snd_soc_jack_add_gpios() 322 gpios[i].jack = jack; in snd_soc_jack_add_gpios() 324 ret = request_any_context_irq(gpio_to_irq(gpios[i].gpio), in snd_soc_jack_add_gpios() [all …]
|
/linux-2.6.39/drivers/mmc/host/ |
D | of_mmc_spi.c | 37 int gpios[NUM_GPIOS]; member 52 bool value = gpio_get_value(oms->gpios[gpio_num]); in of_mmc_spi_read_gpio() 121 for (i = 0; i < ARRAY_SIZE(oms->gpios); i++) { in mmc_spi_get_pdata() 124 oms->gpios[i] = of_get_gpio_flags(np, i, &gpio_flags); in mmc_spi_get_pdata() 125 if (!gpio_is_valid(oms->gpios[i])) in mmc_spi_get_pdata() 128 ret = gpio_request(oms->gpios[i], dev_name(dev)); in mmc_spi_get_pdata() 130 oms->gpios[i] = -EINVAL; in mmc_spi_get_pdata() 138 if (gpio_is_valid(oms->gpios[CD_GPIO])) in mmc_spi_get_pdata() 140 if (gpio_is_valid(oms->gpios[WP_GPIO])) in mmc_spi_get_pdata() 169 for (i = 0; i < ARRAY_SIZE(oms->gpios); i++) { in mmc_spi_put_pdata() [all …]
|
/linux-2.6.39/drivers/power/ |
D | collie_battery.c | 285 } gpios[] = { variable 323 for (i = 0; i < ARRAY_SIZE(gpios); i++) { in collie_bat_probe() 324 ret = gpio_request(gpios[i].gpio, gpios[i].name); in collie_bat_probe() 330 if (gpios[i].output) in collie_bat_probe() 331 ret = gpio_direction_output(gpios[i].gpio, in collie_bat_probe() 332 gpios[i].value); in collie_bat_probe() 334 ret = gpio_direction_input(gpios[i].gpio); in collie_bat_probe() 370 gpio_free(gpios[i].gpio); in collie_bat_probe() 391 for (i = ARRAY_SIZE(gpios) - 1; i >= 0; i--) in collie_bat_remove() 392 gpio_free(gpios[i].gpio); in collie_bat_remove()
|
D | tosa_battery.c | 315 } gpios[] = { variable 358 for (i = 0; i < ARRAY_SIZE(gpios); i++) { in tosa_bat_probe() 359 ret = gpio_request(gpios[i].gpio, gpios[i].name); in tosa_bat_probe() 365 if (gpios[i].output) in tosa_bat_probe() 366 ret = gpio_direction_output(gpios[i].gpio, in tosa_bat_probe() 367 gpios[i].value); in tosa_bat_probe() 369 ret = gpio_direction_input(gpios[i].gpio); in tosa_bat_probe() 430 gpio_free(gpios[i].gpio); in tosa_bat_probe() 454 for (i = ARRAY_SIZE(gpios) - 1; i >= 0; i--) in tosa_bat_remove() 455 gpio_free(gpios[i].gpio); in tosa_bat_remove()
|
/linux-2.6.39/arch/arm/mach-pxa/ |
D | am300epd.c | 93 static int gpios[] = { PWR_GPIO_PIN, CFG_GPIO_PIN, RDY_GPIO_PIN, DC_GPIO_PIN, variable 112 for (i = 0; i < ARRAY_SIZE(gpios); i++) { in am300_init_gpio_regs() 113 err = gpio_request(gpios[i], gpio_names[i]); in am300_init_gpio_regs() 162 i = ARRAY_SIZE(gpios); in am300_init_gpio_regs() 165 gpio_free(gpios[i]); in am300_init_gpio_regs() 181 for (i = 0; i < ARRAY_SIZE(gpios); i++) in am300_cleanup() 182 gpio_free(gpios[i]); in am300_cleanup()
|
D | am200epd.c | 101 static int gpios[] = { LED_GPIO_PIN , STDBY_GPIO_PIN , RST_GPIO_PIN, variable 110 for (i = 0; i < ARRAY_SIZE(gpios); i++) { in am200_init_gpio_regs() 111 err = gpio_request(gpios[i], gpio_names[i]); in am200_init_gpio_regs() 132 gpio_free(gpios[i]); in am200_init_gpio_regs() 143 for (i = 0; i < ARRAY_SIZE(gpios); i++) in am200_cleanup() 144 gpio_free(gpios[i]); in am200_cleanup()
|
D | mioa701.c | 191 static int mio_gpio_request(struct gpio_ress *gpios, int size) in mio_gpio_request() argument 198 gpio = gpios[i].gpio; in mio_gpio_request() 199 dir = gpios[i].dir; in mio_gpio_request() 200 rc = gpio_request(gpio, gpios[i].desc); in mio_gpio_request() 203 gpio, gpios[i].desc, rc); in mio_gpio_request() 207 gpio_direction_output(gpio, gpios[i].init); in mio_gpio_request() 212 gpio_free(gpios[i].gpio); in mio_gpio_request() 216 static void mio_gpio_free(struct gpio_ress *gpios, int size) in mio_gpio_free() argument 221 gpio_free(gpios[i].gpio); in mio_gpio_free()
|
D | hx4700.c | 149 static int hx4700_gpio_request(struct gpio_ress *gpios, int size) in hx4700_gpio_request() argument 156 gpio = gpios[i].gpio; in hx4700_gpio_request() 157 dir = gpios[i].dir; in hx4700_gpio_request() 158 rc = gpio_request(gpio, gpios[i].desc); in hx4700_gpio_request() 161 gpio, gpios[i].desc, rc); in hx4700_gpio_request() 165 gpio_direction_output(gpio, gpios[i].init); in hx4700_gpio_request() 170 gpio_free(gpios[i].gpio); in hx4700_gpio_request()
|
/linux-2.6.39/drivers/sh/ |
D | pfc.c | 136 struct pinmux_gpio *gpiop = &gpioc->gpios[gpio]; in setup_data_reg() 190 struct pinmux_gpio *gpiop = &gpioc->gpios[gpio]; in get_data_reg() 237 pinmux_enum_t enum_id = gpioc->gpios[gpio].enum_id; in get_gpio_enum_id() 426 if ((gpioc->gpios[offset].flags & PINMUX_FLAG_TYPE) != PINMUX_TYPE_NONE) in sh_gpio_request() 448 gpioc->gpios[offset].flags &= ~PINMUX_FLAG_TYPE; in sh_gpio_request() 449 gpioc->gpios[offset].flags |= pinmux_type; in sh_gpio_request() 469 pinmux_type = gpioc->gpios[offset].flags & PINMUX_FLAG_TYPE; in sh_gpio_free() 471 gpioc->gpios[offset].flags &= ~PINMUX_FLAG_TYPE; in sh_gpio_free() 472 gpioc->gpios[offset].flags |= PINMUX_TYPE_NONE; in sh_gpio_free() 486 pinmux_type = gpioc->gpios[gpio].flags & PINMUX_FLAG_TYPE; in pinmux_direction() [all …]
|
/linux-2.6.39/drivers/mtd/maps/ |
D | gpio-addr-flash.c | 196 struct resource *gpios; in gpio_flash_probe() local 201 gpios = platform_get_resource(pdev, IORESOURCE_IRQ, 0); in gpio_flash_probe() 203 if (!memory || !gpios || !gpios->end) in gpio_flash_probe() 206 arr_size = sizeof(int) * gpios->end; in gpio_flash_probe() 215 state->gpio_count = gpios->end; in gpio_flash_probe() 216 state->gpio_addrs = (void *)(unsigned long)gpios->start; in gpio_flash_probe()
|
/linux-2.6.39/drivers/i2c/muxes/ |
D | gpio-i2cmux.c | 31 gpio_set_value(mux->data.gpios[i], val & (1 << i)); in gpiomux_set() 98 ret = gpio_request(pdata->gpios[i], "gpio-i2cmux"); in gpiomux_probe() 101 gpio_direction_output(pdata->gpios[i], in gpiomux_probe() 130 gpio_free(pdata->gpios[i - 1]); in gpiomux_probe() 149 gpio_free(mux->data.gpios[i]); in gpiomux_remove()
|
/linux-2.6.39/Documentation/devicetree/bindings/gpio/ |
D | led.txt | 10 - gpios : Should specify the LED's GPIO, see "Specifying GPIO information 37 gpios = <&mcu_pio 0 1>; /* Active low */ 42 gpios = <&mcu_pio 1 0>; 51 gpios = <&mpc8572 6 0>; 55 gpios = <&mpc8572 7 0>;
|
D | gpio.txt | 4 1) gpios property 7 Nodes that makes use of GPIOs should define them using `gpios' property, 22 gpios = <&qe_pio_e 18 0>;
|
/linux-2.6.39/Documentation/devicetree/bindings/powerpc/fsl/cpm_qe/ |
D | serial.txt | 10 Modem control lines connected to GPIO controllers are listed in the gpios 16 The gpios property is optional and can be left out when control lines are 30 gpios = <&gpio_c 15 0
|
/linux-2.6.39/drivers/spi/ |
D | spi_ppc4xx.c | 133 int *gpios; member 289 if (!hw->master->num_chipselect || hw->gpios[cs] == -EEXIST) in spi_ppc4xx_chipsel() 296 gpio_set_value(hw->gpios[cs], cspol); in spi_ppc4xx_chipsel() 382 if (gpio_is_valid(hw->gpios[i])) in free_gpios() 383 gpio_free(hw->gpios[i]); in free_gpios() 385 kfree(hw->gpios); in free_gpios() 386 hw->gpios = NULL; in free_gpios() 426 hw->gpios = kzalloc(sizeof(int) * num_gpios, GFP_KERNEL); in spi_ppc4xx_of_probe() 427 if (!hw->gpios) { in spi_ppc4xx_of_probe() 437 hw->gpios[i] = gpio; in spi_ppc4xx_of_probe()
|
D | spi_fsl_spi.c | 940 int gpio = pinfo->gpios[cs]; in fsl_spi_cs_control() 965 pinfo->gpios = kmalloc(ngpios * sizeof(*pinfo->gpios), GFP_KERNEL); in of_fsl_spi_get_chipselects() 966 if (!pinfo->gpios) in of_fsl_spi_get_chipselects() 968 memset(pinfo->gpios, -1, ngpios * sizeof(*pinfo->gpios)); in of_fsl_spi_get_chipselects() 994 pinfo->gpios[i] = gpio; in of_fsl_spi_get_chipselects() 997 ret = gpio_direction_output(pinfo->gpios[i], in of_fsl_spi_get_chipselects() 1013 if (gpio_is_valid(pinfo->gpios[i])) in of_fsl_spi_get_chipselects() 1014 gpio_free(pinfo->gpios[i]); in of_fsl_spi_get_chipselects() 1021 kfree(pinfo->gpios); in of_fsl_spi_get_chipselects() 1022 pinfo->gpios = NULL; in of_fsl_spi_get_chipselects() [all …]
|
/linux-2.6.39/drivers/gpio/ |
D | adp5520-gpio.c | 95 int ret, i, gpios; in adp5520_gpio_probe() local 116 for (gpios = 0, i = 0; i < ADP5520_MAXGPIOS; i++) in adp5520_gpio_probe() 118 dev->lut[gpios++] = 1 << i; in adp5520_gpio_probe() 120 if (gpios < 1) { in adp5520_gpio_probe() 133 gc->ngpio = gpios; in adp5520_gpio_probe()
|
/linux-2.6.39/Documentation/devicetree/bindings/net/ |
D | mdio-gpio.txt | 7 gpios property as described in section VIII.1 in the following order: 17 gpios = <&qe_pio_a 11
|
/linux-2.6.39/drivers/hwmon/ |
D | ltc4245.c | 67 int gpios[3]; member 86 data->gpios[0] = data->vregs[LTC4245_GPIOADC - 0x10]; in ltc4245_update_gpios() 96 for (i = 0; i < ARRAY_SIZE(data->gpios); i++) in ltc4245_update_gpios() 97 data->gpios[i] = -EAGAIN; in ltc4245_update_gpios() 112 data->gpios[gpio_curr] = data->vregs[LTC4245_GPIOADC - 0x10]; in ltc4245_update_gpios() 115 gpio_next = (gpio_curr + 1) % ARRAY_SIZE(data->gpios); in ltc4245_update_gpios() 310 int val = data->gpios[attr->index]; in ltc4245_show_gpio()
|
/linux-2.6.39/Documentation/devicetree/bindings/spi/ |
D | fsl-spi.txt | 19 - gpios : specifies the gpio pins to be used for chipselects. 20 The gpios will be referred to as reg = <index> in the SPI child nodes. 31 gpios = <&gpio 18 1 // device reg=<0>
|
/linux-2.6.39/Documentation/devicetree/bindings/mtd/ |
D | fsl-upm-nand.txt | 15 - gpios : may specify optional GPIOs connected to the Ready-Not-Busy pins 19 read registers (tR). Required if property "gpios" is not used 29 gpios = <&qe_pio_e 18 0>;
|
/linux-2.6.39/Documentation/devicetree/bindings/mmc/ |
D | mmc-spi-slot.txt | 12 - gpios : may specify GPIOs in this order: Card-Detect GPIO, 24 gpios = <&qe_pio_d 14 1
|
/linux-2.6.39/drivers/usb/host/ |
D | fhci-hub.c | 45 int gpio = fhci->gpios[gpio_nr]; in fhci_gpio_set_value() 136 gpio_direction_output(fhci->gpios[GPIO_USBOE], 0); in fhci_io_port_generate_reset() 137 gpio_direction_output(fhci->gpios[GPIO_USBTP], 0); in fhci_io_port_generate_reset() 138 gpio_direction_output(fhci->gpios[GPIO_USBTN], 0); in fhci_io_port_generate_reset()
|
D | fhci-hcd.c | 155 if (!gpio_get_value(fhci->gpios[GPIO_USBOE])) in fhci_ioports_check_bus_state() 159 if (gpio_get_value(fhci->gpios[GPIO_USBRP])) in fhci_ioports_check_bus_state() 163 if (gpio_get_value(fhci->gpios[GPIO_USBRN])) in fhci_ioports_check_bus_state() 638 fhci->gpios[i] = gpio; in of_fhci_probe() 769 if (gpio_is_valid(fhci->gpios[i])) in of_fhci_probe() 770 gpio_free(fhci->gpios[i]); in of_fhci_probe() 792 if (!gpio_is_valid(fhci->gpios[i])) in fhci_remove() 794 gpio_free(fhci->gpios[i]); in fhci_remove()
|
/linux-2.6.39/drivers/tty/serial/cpm_uart/ |
D | cpm_uart_core.c | 106 if (pinfo->gpios[GPIO_RTS] >= 0) in cpm_uart_set_mctrl() 107 gpio_set_value(pinfo->gpios[GPIO_RTS], !(mctrl & TIOCM_RTS)); in cpm_uart_set_mctrl() 109 if (pinfo->gpios[GPIO_DTR] >= 0) in cpm_uart_set_mctrl() 110 gpio_set_value(pinfo->gpios[GPIO_DTR], !(mctrl & TIOCM_DTR)); in cpm_uart_set_mctrl() 118 if (pinfo->gpios[GPIO_CTS] >= 0) { in cpm_uart_get_mctrl() 119 if (gpio_get_value(pinfo->gpios[GPIO_CTS])) in cpm_uart_get_mctrl() 123 if (pinfo->gpios[GPIO_DSR] >= 0) { in cpm_uart_get_mctrl() 124 if (gpio_get_value(pinfo->gpios[GPIO_DSR])) in cpm_uart_get_mctrl() 128 if (pinfo->gpios[GPIO_DCD] >= 0) { in cpm_uart_get_mctrl() 129 if (gpio_get_value(pinfo->gpios[GPIO_DCD])) in cpm_uart_get_mctrl() [all …]
|