Lines Matching refs:offset
39 static int gpio2_get(struct gpio_chip *chip, unsigned offset)
41 return alchemy_gpio2_get_value(offset + ALCHEMY_GPIO2_BASE);
44 static void gpio2_set(struct gpio_chip *chip, unsigned offset, int value)
46 alchemy_gpio2_set_value(offset + ALCHEMY_GPIO2_BASE, value);
49 static int gpio2_direction_input(struct gpio_chip *chip, unsigned offset)
51 return alchemy_gpio2_direction_input(offset + ALCHEMY_GPIO2_BASE);
54 static int gpio2_direction_output(struct gpio_chip *chip, unsigned offset,
57 return alchemy_gpio2_direction_output(offset + ALCHEMY_GPIO2_BASE,
61 static int gpio2_to_irq(struct gpio_chip *chip, unsigned offset)
63 return alchemy_gpio2_to_irq(offset + ALCHEMY_GPIO2_BASE);
67 static int gpio1_get(struct gpio_chip *chip, unsigned offset)
69 return alchemy_gpio1_get_value(offset + ALCHEMY_GPIO1_BASE);
73 unsigned offset, int value)
75 alchemy_gpio1_set_value(offset + ALCHEMY_GPIO1_BASE, value);
78 static int gpio1_direction_input(struct gpio_chip *chip, unsigned offset)
80 return alchemy_gpio1_direction_input(offset + ALCHEMY_GPIO1_BASE);
84 unsigned offset, int value)
86 return alchemy_gpio1_direction_output(offset + ALCHEMY_GPIO1_BASE,
90 static int gpio1_to_irq(struct gpio_chip *chip, unsigned offset)
92 return alchemy_gpio1_to_irq(offset + ALCHEMY_GPIO1_BASE);