Lines Matching defs:offset
37 static int tc3589x_gpio_get(struct gpio_chip *chip, unsigned int offset)
41 u8 reg = TC3589x_GPIODATA0 + (offset / 8) * 2;
42 u8 mask = BIT(offset % 8);
52 static void tc3589x_gpio_set(struct gpio_chip *chip, unsigned int offset, int val)
56 u8 reg = TC3589x_GPIODATA0 + (offset / 8) * 2;
57 unsigned int pos = offset % 8;
64 unsigned int offset, int val)
68 u8 reg = TC3589x_GPIODIR0 + offset / 8;
69 unsigned int pos = offset % 8;
71 tc3589x_gpio_set(chip, offset, val);
77 unsigned int offset)
81 u8 reg = TC3589x_GPIODIR0 + offset / 8;
82 unsigned int pos = offset % 8;
88 unsigned int offset)
92 u8 reg = TC3589x_GPIODIR0 + offset / 8;
93 unsigned int pos = offset % 8;
106 static int tc3589x_gpio_set_config(struct gpio_chip *chip, unsigned int offset,
116 u8 odmreg = TC3589x_GPIOODM0 + (offset / 8) * 2;
117 u8 odereg = TC3589x_GPIOODE0 + (offset / 8) * 2;
118 unsigned int pos = offset % 8;
161 int offset = d->hwirq;
162 int regoffset = offset / 8;
163 int mask = BIT(offset % 8);
227 int offset = d->hwirq;
228 int regoffset = offset / 8;
229 int mask = BIT(offset % 8);
233 gpiochip_disable_irq(gc, offset);
240 int offset = d->hwirq;
241 int regoffset = offset / 8;
242 int mask = BIT(offset % 8);
244 gpiochip_enable_irq(gc, offset);