Lines Matching refs:offset

86 #define giu_read(offset)		readw(giu_base + (offset))  argument
87 #define giu_write(offset, value) writew((value), giu_base + (offset)) argument
93 static inline u16 giu_set(u16 offset, u16 set) in giu_set() argument
97 data = giu_read(offset); in giu_set()
99 giu_write(offset, data); in giu_set()
104 static inline u16 giu_clear(u16 offset, u16 clear) in giu_clear() argument
108 data = giu_read(offset); in giu_clear()
110 giu_write(offset, data); in giu_clear()
335 u16 offset, mask, reg; in giu_set_direction() local
342 offset = GIUIOSELL; in giu_set_direction()
345 offset = GIUIOSELH; in giu_set_direction()
349 offset = GIUPODATEN; in giu_set_direction()
354 offset = GIUPODATH; in giu_set_direction()
358 offset = GIUPODATH; in giu_set_direction()
369 reg = giu_read(offset); in giu_set_direction()
374 giu_write(offset, reg); in giu_set_direction()
449 u16 offset, mask, reg; in vr41xx_gpio_set() local
456 offset = GIUPIODL; in vr41xx_gpio_set()
459 offset = GIUPIODH; in vr41xx_gpio_set()
462 offset = GIUPODATL; in vr41xx_gpio_set()
465 offset = GIUPODATH; in vr41xx_gpio_set()
471 reg = giu_read(offset); in vr41xx_gpio_set()
476 giu_write(offset, reg); in vr41xx_gpio_set()
482 static int vr41xx_gpio_direction_input(struct gpio_chip *chip, unsigned offset) in vr41xx_gpio_direction_input() argument
484 return giu_set_direction(chip, offset, GPIO_INPUT); in vr41xx_gpio_direction_input()
487 static int vr41xx_gpio_direction_output(struct gpio_chip *chip, unsigned offset, in vr41xx_gpio_direction_output() argument
490 vr41xx_gpio_set(chip, offset, value); in vr41xx_gpio_direction_output()
492 return giu_set_direction(chip, offset, GPIO_OUTPUT); in vr41xx_gpio_direction_output()
495 static int vr41xx_gpio_to_irq(struct gpio_chip *chip, unsigned offset) in vr41xx_gpio_to_irq() argument
497 if (offset >= chip->ngpio) in vr41xx_gpio_to_irq()
500 return GIU_IRQ_BASE + offset; in vr41xx_gpio_to_irq()