Lines Matching refs:tc3589x_gpio

27 struct tc3589x_gpio {  struct
39 struct tc3589x_gpio *tc3589x_gpio = gpiochip_get_data(chip); in tc3589x_gpio_get() local
40 struct tc3589x *tc3589x = tc3589x_gpio->tc3589x; in tc3589x_gpio_get()
54 struct tc3589x_gpio *tc3589x_gpio = gpiochip_get_data(chip); in tc3589x_gpio_set() local
55 struct tc3589x *tc3589x = tc3589x_gpio->tc3589x; in tc3589x_gpio_set()
66 struct tc3589x_gpio *tc3589x_gpio = gpiochip_get_data(chip); in tc3589x_gpio_direction_output() local
67 struct tc3589x *tc3589x = tc3589x_gpio->tc3589x; in tc3589x_gpio_direction_output()
79 struct tc3589x_gpio *tc3589x_gpio = gpiochip_get_data(chip); in tc3589x_gpio_direction_input() local
80 struct tc3589x *tc3589x = tc3589x_gpio->tc3589x; in tc3589x_gpio_direction_input()
90 struct tc3589x_gpio *tc3589x_gpio = gpiochip_get_data(chip); in tc3589x_gpio_get_direction() local
91 struct tc3589x *tc3589x = tc3589x_gpio->tc3589x; in tc3589x_gpio_get_direction()
109 struct tc3589x_gpio *tc3589x_gpio = gpiochip_get_data(chip); in tc3589x_gpio_set_config() local
110 struct tc3589x *tc3589x = tc3589x_gpio->tc3589x; in tc3589x_gpio_set_config()
160 struct tc3589x_gpio *tc3589x_gpio = gpiochip_get_data(gc); in tc3589x_gpio_irq_set_type() local
166 tc3589x_gpio->regs[REG_IBE][regoffset] |= mask; in tc3589x_gpio_irq_set_type()
170 tc3589x_gpio->regs[REG_IBE][regoffset] &= ~mask; in tc3589x_gpio_irq_set_type()
173 tc3589x_gpio->regs[REG_IS][regoffset] |= mask; in tc3589x_gpio_irq_set_type()
175 tc3589x_gpio->regs[REG_IS][regoffset] &= ~mask; in tc3589x_gpio_irq_set_type()
178 tc3589x_gpio->regs[REG_IEV][regoffset] |= mask; in tc3589x_gpio_irq_set_type()
180 tc3589x_gpio->regs[REG_IEV][regoffset] &= ~mask; in tc3589x_gpio_irq_set_type()
188 struct tc3589x_gpio *tc3589x_gpio = gpiochip_get_data(gc); in tc3589x_gpio_irq_lock() local
190 mutex_lock(&tc3589x_gpio->irq_lock); in tc3589x_gpio_irq_lock()
196 struct tc3589x_gpio *tc3589x_gpio = gpiochip_get_data(gc); in tc3589x_gpio_irq_sync_unlock() local
197 struct tc3589x *tc3589x = tc3589x_gpio->tc3589x; in tc3589x_gpio_irq_sync_unlock()
209 u8 old = tc3589x_gpio->oldregs[i][j]; in tc3589x_gpio_irq_sync_unlock()
210 u8 new = tc3589x_gpio->regs[i][j]; in tc3589x_gpio_irq_sync_unlock()
215 tc3589x_gpio->oldregs[i][j] = new; in tc3589x_gpio_irq_sync_unlock()
220 mutex_unlock(&tc3589x_gpio->irq_lock); in tc3589x_gpio_irq_sync_unlock()
226 struct tc3589x_gpio *tc3589x_gpio = gpiochip_get_data(gc); in tc3589x_gpio_irq_mask() local
231 tc3589x_gpio->regs[REG_IE][regoffset] &= ~mask; in tc3589x_gpio_irq_mask()
232 tc3589x_gpio->regs[REG_DIRECT][regoffset] |= mask; in tc3589x_gpio_irq_mask()
239 struct tc3589x_gpio *tc3589x_gpio = gpiochip_get_data(gc); in tc3589x_gpio_irq_unmask() local
245 tc3589x_gpio->regs[REG_IE][regoffset] |= mask; in tc3589x_gpio_irq_unmask()
246 tc3589x_gpio->regs[REG_DIRECT][regoffset] &= ~mask; in tc3589x_gpio_irq_unmask()
262 struct tc3589x_gpio *tc3589x_gpio = dev; in tc3589x_gpio_irq() local
263 struct tc3589x *tc3589x = tc3589x_gpio->tc3589x; in tc3589x_gpio_irq()
281 int irq = irq_find_mapping(tc3589x_gpio->chip.irq.domain, in tc3589x_gpio_irq()
298 struct tc3589x_gpio *tc3589x_gpio; in tc3589x_gpio_probe() local
312 tc3589x_gpio = devm_kzalloc(&pdev->dev, sizeof(struct tc3589x_gpio), in tc3589x_gpio_probe()
314 if (!tc3589x_gpio) in tc3589x_gpio_probe()
317 mutex_init(&tc3589x_gpio->irq_lock); in tc3589x_gpio_probe()
319 tc3589x_gpio->dev = &pdev->dev; in tc3589x_gpio_probe()
320 tc3589x_gpio->tc3589x = tc3589x; in tc3589x_gpio_probe()
322 tc3589x_gpio->chip = template_chip; in tc3589x_gpio_probe()
323 tc3589x_gpio->chip.ngpio = tc3589x->num_gpio; in tc3589x_gpio_probe()
324 tc3589x_gpio->chip.parent = &pdev->dev; in tc3589x_gpio_probe()
325 tc3589x_gpio->chip.base = -1; in tc3589x_gpio_probe()
327 girq = &tc3589x_gpio->chip.irq; in tc3589x_gpio_probe()
357 tc3589x_gpio); in tc3589x_gpio_probe()
363 return devm_gpiochip_add_data(&pdev->dev, &tc3589x_gpio->chip, tc3589x_gpio); in tc3589x_gpio_probe()