Lines Matching refs:gpio_chip
30 struct gpio_chip gpio_chip; member
34 static int moxtet_gpio_get_value(struct gpio_chip *gc, unsigned int offset) in moxtet_gpio_get_value()
55 static void moxtet_gpio_set_value(struct gpio_chip *gc, unsigned int offset, in moxtet_gpio_set_value()
75 static int moxtet_gpio_get_direction(struct gpio_chip *gc, unsigned int offset) in moxtet_gpio_get_direction()
88 static int moxtet_gpio_direction_input(struct gpio_chip *gc, in moxtet_gpio_direction_input()
101 static int moxtet_gpio_direction_output(struct gpio_chip *gc, in moxtet_gpio_direction_output()
135 chip->gpio_chip.parent = dev; in moxtet_gpio_probe()
140 chip->gpio_chip.label = dev_name(dev); in moxtet_gpio_probe()
141 chip->gpio_chip.get_direction = moxtet_gpio_get_direction; in moxtet_gpio_probe()
142 chip->gpio_chip.direction_input = moxtet_gpio_direction_input; in moxtet_gpio_probe()
143 chip->gpio_chip.direction_output = moxtet_gpio_direction_output; in moxtet_gpio_probe()
144 chip->gpio_chip.get = moxtet_gpio_get_value; in moxtet_gpio_probe()
145 chip->gpio_chip.set = moxtet_gpio_set_value; in moxtet_gpio_probe()
146 chip->gpio_chip.base = -1; in moxtet_gpio_probe()
148 chip->gpio_chip.ngpio = MOXTET_GPIO_NGPIOS; in moxtet_gpio_probe()
150 chip->gpio_chip.can_sleep = true; in moxtet_gpio_probe()
151 chip->gpio_chip.owner = THIS_MODULE; in moxtet_gpio_probe()
153 return devm_gpiochip_add_data(dev, &chip->gpio_chip, chip); in moxtet_gpio_probe()