/drivers/gpio/ |
D | gpio-lpc32xx.c | 169 unsigned pin, int input) in __set_gpio_dir_p012() argument 172 __raw_writel(GPIO012_PIN_TO_BIT(pin), in __set_gpio_dir_p012() 175 __raw_writel(GPIO012_PIN_TO_BIT(pin), in __set_gpio_dir_p012() 180 unsigned pin, int input) in __set_gpio_dir_p3() argument 182 u32 u = GPIO3_PIN_TO_BIT(pin); in __set_gpio_dir_p3() 191 unsigned pin, int high) in __set_gpio_level_p012() argument 194 __raw_writel(GPIO012_PIN_TO_BIT(pin), in __set_gpio_level_p012() 197 __raw_writel(GPIO012_PIN_TO_BIT(pin), in __set_gpio_level_p012() 202 unsigned pin, int high) in __set_gpio_level_p3() argument 204 u32 u = GPIO3_PIN_TO_BIT(pin); in __set_gpio_level_p3() [all …]
|
D | gpio-vr41xx.c | 126 unsigned int pin; in mask_ack_giuint_low() local 128 pin = GPIO_PIN_OF_IRQ(d->irq); in mask_ack_giuint_low() 129 giu_clear(GIUINTENL, 1 << pin); in mask_ack_giuint_low() 130 giu_write(GIUINTSTATL, 1 << pin); in mask_ack_giuint_low() 159 unsigned int pin; in mask_ack_giuint_high() local 161 pin = GPIO_PIN_OF_IRQ(d->irq) - GIUINT_HIGH_OFFSET; in mask_ack_giuint_high() 162 giu_clear(GIUINTENH, 1 << pin); in mask_ack_giuint_high() 163 giu_write(GIUINTSTATH, 1 << pin); in mask_ack_giuint_high() 212 void vr41xx_set_irq_trigger(unsigned int pin, irq_trigger_t trigger, in vr41xx_set_irq_trigger() argument 217 if (pin < GIUINT_HIGH_OFFSET) { in vr41xx_set_irq_trigger() [all …]
|
D | gpio-ks8695.c | 40 static void ks8695_gpio_mode(unsigned int pin, short gpio) in ks8695_gpio_mode() argument 45 if (pin > KS8695_GPIO_5) /* only GPIO 0..5 have internal functions */ in ks8695_gpio_mode() 52 x &= ~enable[pin]; in ks8695_gpio_mode() 54 x |= enable[pin]; in ks8695_gpio_mode() 66 int ks8695_gpio_interrupt(unsigned int pin, unsigned int type) in ks8695_gpio_interrupt() argument 70 if (pin > KS8695_GPIO_3) /* only GPIO 0..3 can generate IRQ */ in ks8695_gpio_interrupt() 77 x &= ~IOPM(pin); in ks8695_gpio_interrupt() 83 irq_set_irq_type(gpio_irq[pin], type); in ks8695_gpio_interrupt() 86 ks8695_gpio_mode(pin, 0); in ks8695_gpio_interrupt() 99 static int ks8695_gpio_direction_input(struct gpio_chip *gc, unsigned int pin) in ks8695_gpio_direction_input() argument [all …]
|
D | gpio-samsung.c | 1076 static int s3c64xx_gpiolib_mbank_to_irq(struct gpio_chip *chip, unsigned pin) in s3c64xx_gpiolib_mbank_to_irq() argument 1078 return pin < 5 ? IRQ_EINT(23) + pin : -ENXIO; in s3c64xx_gpiolib_mbank_to_irq() 1081 static int s3c64xx_gpiolib_lbank_to_irq(struct gpio_chip *chip, unsigned pin) in s3c64xx_gpiolib_lbank_to_irq() argument 1083 return pin >= 8 ? IRQ_EINT(16) + pin - 8 : -ENXIO; in s3c64xx_gpiolib_lbank_to_irq() 2663 unsigned int pin; in exynos_gpio_xlate() local 2674 pin = gc->base + gpiospec->args[0]; in exynos_gpio_xlate() 2676 if (s3c_gpio_cfgpin(pin, S3C_GPIO_SFN(gpiospec->args[1]))) in exynos_gpio_xlate() 2678 if (s3c_gpio_setpull(pin, gpiospec->args[2])) in exynos_gpio_xlate() 2680 if (s5p_gpio_set_drvstr(pin, gpiospec->args[3])) in exynos_gpio_xlate() 2991 int s3c_gpio_cfgpin(unsigned int pin, unsigned int config) in s3c_gpio_cfgpin() argument [all …]
|
/drivers/acpi/ |
D | pci_irq.c | 51 u8 pin; member 59 static inline char pin_name(int pin) in pin_name() argument 61 return 'A' + pin - 1; in pin_name() 69 int pin) in acpi_pci_irq_find_prt_entry() argument 81 && (pin == entry->pin)) { in acpi_pci_irq_find_prt_entry() 132 unsigned char pin; member 173 entry->pin == quirk->pin && in do_prt_fixups() 180 entry->id.device, pin_name(entry->pin), in do_prt_fixups() 204 entry->pin = prt->pin + 1; in acpi_pci_irq_add_entry() 237 entry->id.device, pin_name(entry->pin), in acpi_pci_irq_add_entry() [all …]
|
/drivers/pinctrl/ |
D | pinconf.c | 57 int pin_config_get_for_pin(struct pinctrl_dev *pctldev, unsigned pin, in pin_config_get_for_pin() argument 68 return ops->pin_config_get(pctldev, pin, config); in pin_config_get_for_pin() 83 int pin; in pin_config_get() local 89 pin = -EINVAL; in pin_config_get() 93 pin = pin_get_from_name(pctldev, name); in pin_config_get() 94 if (pin < 0) in pin_config_get() 97 pin = pin_config_get_for_pin(pctldev, pin, config); in pin_config_get() 101 return pin; in pin_config_get() 105 static int pin_config_set_for_pin(struct pinctrl_dev *pctldev, unsigned pin, in pin_config_set_for_pin() argument 117 ret = ops->pin_config_set(pctldev, pin, config); in pin_config_set_for_pin() [all …]
|
D | pinctrl-pxa3xx.c | 107 int i, pin, ret = 0; in match_group_mux() local 109 pin = grp->pins[i]; in match_group_mux() 110 ret = match_mux(&info->mfp[pin], mux); in match_group_mux() 113 mux, pin); in match_group_mux() 126 int i, mfpr, pin, pin_func; in pxa3xx_pmx_enable() local 134 pin = pin_grp->pins[i]; in pxa3xx_pmx_enable() 135 pin_func = match_mux(&info->mfp[pin], pin_grp->mux); in pxa3xx_pmx_enable() 136 mfpr = info->mfp[pin].mfpr; in pxa3xx_pmx_enable() 152 unsigned pin) in pxa3xx_pmx_request_gpio() argument 158 pin_func = match_mux(&info->mfp[pin], PXA3xx_MUX_GPIO); in pxa3xx_pmx_request_gpio() [all …]
|
D | pinmux.c | 81 int pin, const char *owner, in pin_request() 88 dev_dbg(pctldev->dev, "request pin %d for %s\n", pin, owner); in pin_request() 90 desc = pin_desc_get(pctldev, pin); in pin_request() 124 pin); in pin_request() 135 status = ops->gpio_request_enable(pctldev, gpio_range, pin); in pin_request() 137 status = ops->request(pctldev, pin); in pin_request() 143 pctldev->desc->name, pin); in pin_request() 160 pin, owner, status); in pin_request() 176 static const char *pin_free(struct pinctrl_dev *pctldev, int pin, in pin_free() argument 183 desc = pin_desc_get(pctldev, pin); in pin_free() [all …]
|
D | pinmux.h | 21 unsigned pin, unsigned gpio); 22 void pinmux_free_gpio(struct pinctrl_dev *pctldev, unsigned pin, 26 unsigned pin, bool input); 54 unsigned pin, unsigned gpio) in pinmux_request_gpio() argument 60 unsigned pin, in pinmux_free_gpio() argument 67 unsigned pin, bool input) in pinmux_gpio_direction() argument
|
D | Kconfig | 15 bool "Support pin multiplexing controllers" 18 bool "Support pin configuration controllers" 35 bool "MMP2 pin controller driver" 41 bool "PXA168 pin controller driver" 47 bool "PXA910 pin controller driver" 53 bool "CSR SiRFprimaII pin controller driver" 73 bool "U300 pin controller driver"
|
D | core.c | 108 unsigned i, pin; in pin_get_from_name() local 114 pin = pctldev->desc->pins[i].number; in pin_get_from_name() 115 desc = pin_desc_get(pctldev, pin); in pin_get_from_name() 120 return pin; in pin_get_from_name() 134 bool pin_is_valid(struct pinctrl_dev *pctldev, int pin) in pin_is_valid() argument 138 if (pin < 0) in pin_is_valid() 142 pindesc = pin_desc_get(pctldev, pin); in pin_is_valid() 356 int pin; in pinctrl_request_gpio() local 367 pin = gpio - range->base + range->pin_base; in pinctrl_request_gpio() 369 ret = pinmux_request_gpio(pctldev, range, pin, gpio); in pinctrl_request_gpio() [all …]
|
/drivers/media/dvb/dvb-usb/ |
D | mxl111sf-gpio.c | 35 static int mxl111sf_set_gpo_state(struct mxl111sf_state *state, u8 pin, u8 val) in mxl111sf_set_gpo_state() argument 40 mxl_debug_adv("(%d, %d)", pin, val); in mxl111sf_set_gpo_state() 42 if ((pin > 0) && (pin < 8)) { in mxl111sf_set_gpo_state() 46 tmp &= ~(1 << (pin - 1)); in mxl111sf_set_gpo_state() 47 tmp |= (val << (pin - 1)); in mxl111sf_set_gpo_state() 51 } else if (pin <= 10) { in mxl111sf_set_gpo_state() 52 if (pin == 0) in mxl111sf_set_gpo_state() 53 pin += 7; in mxl111sf_set_gpo_state() 57 tmp &= ~(1 << (pin - 3)); in mxl111sf_set_gpo_state() 58 tmp |= (val << (pin - 3)); in mxl111sf_set_gpo_state() [all …]
|
/drivers/input/misc/ |
D | ixp4xx-beeper.c | 32 static void ixp4xx_spkr_control(unsigned int pin, unsigned int count) in ixp4xx_spkr_control() argument 39 gpio_line_config(pin, IXP4XX_GPIO_OUT); in ixp4xx_spkr_control() 40 gpio_line_set(pin, IXP4XX_GPIO_LOW); in ixp4xx_spkr_control() 44 gpio_line_config(pin, IXP4XX_GPIO_IN); in ixp4xx_spkr_control() 45 gpio_line_set(pin, IXP4XX_GPIO_HIGH); in ixp4xx_spkr_control() 55 unsigned int pin = (unsigned int) input_get_drvdata(dev); in ixp4xx_spkr_event() local 74 ixp4xx_spkr_control(pin, count); in ixp4xx_spkr_event() 138 unsigned int pin = (unsigned int) input_get_drvdata(input_dev); in ixp4xx_spkr_remove() local 145 ixp4xx_spkr_control(pin, 0); in ixp4xx_spkr_remove() 155 unsigned int pin = (unsigned int) input_get_drvdata(input_dev); in ixp4xx_spkr_shutdown() local [all …]
|
/drivers/input/mouse/ |
D | gpio_mouse.c | 54 int pin, i; in gpio_mouse_probe() local 70 pin = pdata->pins[i]; in gpio_mouse_probe() 72 if (pin < 0) { in gpio_mouse_probe() 86 error = gpio_request(pin, "gpio_mouse"); in gpio_mouse_probe() 89 pin, i); in gpio_mouse_probe() 93 gpio_direction_input(pin); in gpio_mouse_probe() 145 pin = pdata->pins[i]; in gpio_mouse_probe() 146 if (pin) in gpio_mouse_probe() 147 gpio_free(pin); in gpio_mouse_probe() 157 int pin, i; in gpio_mouse_remove() local [all …]
|
/drivers/pci/ |
D | setup-irq.c | 26 u8 pin, slot; in pdev_fixup_irq() local 35 pci_read_config_byte(dev, PCI_INTERRUPT_PIN, &pin); in pdev_fixup_irq() 37 if (pin > 4) in pdev_fixup_irq() 38 pin = 1; in pdev_fixup_irq() 40 if (pin != 0) { in pdev_fixup_irq() 42 slot = (*swizzle)(dev, &pin); in pdev_fixup_irq() 44 irq = (*map_irq)(dev, slot, pin); in pdev_fixup_irq()
|
/drivers/gpu/drm/vmwgfx/ |
D | vmwgfx_dmabuf.c | 96 bool pin, bool interruptible) in vmw_dmabuf_to_vram_or_gmr() argument 107 if (pin) in vmw_dmabuf_to_vram_or_gmr() 121 if (pin) in vmw_dmabuf_to_vram_or_gmr() 136 if (pin) in vmw_dmabuf_to_vram_or_gmr() 167 bool pin, bool interruptible) in vmw_dmabuf_to_vram() argument 171 if (pin) in vmw_dmabuf_to_vram() 199 bool pin, bool interruptible) in vmw_dmabuf_to_start_of_vram() argument 206 if (pin) in vmw_dmabuf_to_start_of_vram() 216 if (pin) in vmw_dmabuf_to_start_of_vram() 300 void vmw_bo_pin(struct ttm_buffer_object *bo, bool pin) in vmw_bo_pin() argument [all …]
|
/drivers/w1/masters/ |
D | w1-gpio.c | 26 gpio_direction_input(pdata->pin); in w1_gpio_write_bit_dir() 28 gpio_direction_output(pdata->pin, 0); in w1_gpio_write_bit_dir() 35 gpio_set_value(pdata->pin, bit); in w1_gpio_write_bit_val() 42 return gpio_get_value(pdata->pin) ? 1 : 0; in w1_gpio_read_bit() 58 err = gpio_request(pdata->pin, "w1"); in w1_gpio_probe() 66 gpio_direction_output(pdata->pin, 1); in w1_gpio_probe() 69 gpio_direction_input(pdata->pin); in w1_gpio_probe() 85 gpio_free(pdata->pin); in w1_gpio_probe() 101 gpio_free(pdata->pin); in w1_gpio_remove()
|
/drivers/input/keyboard/ |
D | adp5588-keys.c | 164 pin_used[kpad->gpimap[i].pin - GPI_PIN_BASE] = true; in adp5588_build_gpiomap() 269 if (key_val == kpad->gpimap[j].pin) { in adp5588_report_events() 342 unsigned short pin = pdata->gpimap[i].pin; in adp5588_setup() local 344 if (pin <= GPI_PIN_ROW_END) { in adp5588_setup() 345 evt_mode1 |= (1 << (pin - GPI_PIN_ROW_BASE)); in adp5588_setup() 347 evt_mode2 |= ((1 << (pin - GPI_PIN_COL_BASE)) & 0xFF); in adp5588_setup() 348 evt_mode3 |= ((1 << (pin - GPI_PIN_COL_BASE)) >> 8); in adp5588_setup() 393 unsigned short pin = kpad->gpimap[i].pin; in adp5588_report_switch_state() local 395 if (pin <= GPI_PIN_ROW_END) { in adp5588_report_switch_state() 397 pin_loc = pin - GPI_PIN_ROW_BASE; in adp5588_report_switch_state() [all …]
|
D | adp5589-keys.c | 481 pin_used[kpad->gpimap[i].pin - kpad->var->gpi_pin_base] = true; in adp5589_build_gpiomap() 592 if (key_val == kpad->gpimap[i].pin) { in adp5589_report_switches() 692 unsigned short pin = pdata->gpimap[i].pin; in adp5589_setup() local 694 if (pin <= kpad->var->gpi_pin_row_end) { in adp5589_setup() 695 evt_mode1 |= (1 << (pin - kpad->var->gpi_pin_row_base)); in adp5589_setup() 698 ((1 << (pin - kpad->var->gpi_pin_col_base)) & 0xFF); in adp5589_setup() 700 evt_mode3 |= ((1 << (pin - in adp5589_setup() 835 unsigned short pin = kpad->gpimap[i].pin; in adp5589_report_switch_state() local 837 if (pin <= kpad->var->gpi_pin_row_end) { in adp5589_report_switch_state() 839 pin_loc = pin - kpad->var->gpi_pin_row_base; in adp5589_report_switch_state() [all …]
|
/drivers/char/ |
D | tb0219.c | 100 static inline char get_gpio_input_pin(unsigned int pin) in get_gpio_input_pin() argument 105 if (values & (1 << pin)) in get_gpio_input_pin() 111 static inline char get_gpio_output_pin(unsigned int pin) in get_gpio_output_pin() argument 116 if (values & (1 << pin)) in get_gpio_output_pin() 122 static inline char get_dip_switch(unsigned int pin) in get_dip_switch() argument 127 if (values & (1 << pin)) in get_dip_switch() 140 static inline int set_gpio_output_pin(unsigned int pin, char command) in set_gpio_output_pin() argument 151 value &= ~(1 << pin); in set_gpio_output_pin() 153 value |= 1 << pin; in set_gpio_output_pin()
|
/drivers/staging/panel/ |
D | Kconfig | 166 int "Parallel port pin number & polarity connected to the LCD E signal (-17...17) " 170 This describes the number of the parallel port pin to which the LCD 'E' 175 -1..-17 : connected to the same pin through an inverter (eg: transistor). 177 Default for the 'E' pin in custom profile is '14' (AUTOFEED). 181 int "Parallel port pin number & polarity connected to the LCD RS signal (-17...17) " 185 This describes the number of the parallel port pin to which the LCD 'RS' 190 -1..-17 : connected to the same pin through an inverter (eg: transistor). 192 Default for the 'RS' pin in custom profile is '17' (SELECT IN). 196 int "Parallel port pin number & polarity connected to the LCD RW signal (-17...17) " 200 This describes the number of the parallel port pin to which the LCD 'RW' [all …]
|
/drivers/leds/ |
D | leds-netxbig.c | 41 int pin; in gpio_ext_set_addr() local 43 for (pin = 0; pin < gpio_ext->num_addr; pin++) in gpio_ext_set_addr() 44 gpio_set_value(gpio_ext->addr[pin], (addr >> pin) & 1); in gpio_ext_set_addr() 49 int pin; in gpio_ext_set_data() local 51 for (pin = 0; pin < gpio_ext->num_data; pin++) in gpio_ext_set_data() 52 gpio_set_value(gpio_ext->data[pin], (data >> pin) & 1); in gpio_ext_set_data()
|
/drivers/staging/android/ |
D | ashmem.c | 588 struct ashmem_pin pin; in ashmem_pin_unpin() local 595 if (unlikely(copy_from_user(&pin, p, sizeof(pin)))) in ashmem_pin_unpin() 599 if (!pin.len) in ashmem_pin_unpin() 600 pin.len = PAGE_ALIGN(asma->size) - pin.offset; in ashmem_pin_unpin() 602 if (unlikely((pin.offset | pin.len) & ~PAGE_MASK)) in ashmem_pin_unpin() 605 if (unlikely(((__u32) -1) - pin.offset < pin.len)) in ashmem_pin_unpin() 608 if (unlikely(PAGE_ALIGN(asma->size) < pin.offset + pin.len)) in ashmem_pin_unpin() 611 pgstart = pin.offset / PAGE_SIZE; in ashmem_pin_unpin() 612 pgend = pgstart + (pin.len / PAGE_SIZE) - 1; in ashmem_pin_unpin()
|
/drivers/of/ |
D | of_pci_irq.c | 25 u8 pin; in of_irq_map_pci() local 42 rc = pci_read_config_byte(pdev, PCI_INTERRUPT_PIN, &pin); in of_irq_map_pci() 46 if (pin == 0) in of_irq_map_pci() 50 lspec = pin; in of_irq_map_pci()
|
/drivers/pcmcia/ |
D | sa1111_jornada720.c | 99 unsigned int pin = GPIO_A0 | GPIO_A1 | GPIO_A2 | GPIO_A3; in pcmcia_jornada720_init() local 104 sa1111_set_io_dir(dev, pin, 0, 0); in pcmcia_jornada720_init() 105 sa1111_set_io(dev, pin, 0); in pcmcia_jornada720_init() 106 sa1111_set_sleep_io(dev, pin, 0); in pcmcia_jornada720_init()
|