Lines Matching refs:gpio_chip
67 struct gpio_chip gpio_chip; member
79 static inline struct gpio_twl4030_priv *to_gpio_twl4030(struct gpio_chip *chip) in to_gpio_twl4030()
81 return container_of(chip, struct gpio_twl4030_priv, gpio_chip); in to_gpio_twl4030()
206 static int twl_request(struct gpio_chip *chip, unsigned offset) in twl_request()
274 static void twl_free(struct gpio_chip *chip, unsigned offset) in twl_free()
294 static int twl_direction_in(struct gpio_chip *chip, unsigned offset) in twl_direction_in()
313 static int twl_get(struct gpio_chip *chip, unsigned offset) in twl_get()
336 static void twl_set(struct gpio_chip *chip, unsigned offset, int value) in twl_set()
354 static int twl_direction_out(struct gpio_chip *chip, unsigned offset, int value) in twl_direction_out()
380 static int twl_to_irq(struct gpio_chip *chip, unsigned offset) in twl_to_irq()
389 static struct gpio_chip template_chip = {
509 priv->gpio_chip = template_chip; in gpio_twl4030_probe()
510 priv->gpio_chip.base = -1; in gpio_twl4030_probe()
511 priv->gpio_chip.ngpio = TWL4030_GPIO_MAX; in gpio_twl4030_probe()
512 priv->gpio_chip.dev = &pdev->dev; in gpio_twl4030_probe()
545 priv->gpio_chip.ngpio += 2; in gpio_twl4030_probe()
547 ret = gpiochip_add(&priv->gpio_chip); in gpio_twl4030_probe()
550 priv->gpio_chip.ngpio = 0; in gpio_twl4030_probe()
560 status = pdata->setup(&pdev->dev, priv->gpio_chip.base, in gpio_twl4030_probe()
578 status = pdata->teardown(&pdev->dev, priv->gpio_chip.base, in gpio_twl4030_remove()
586 gpiochip_remove(&priv->gpio_chip); in gpio_twl4030_remove()