Lines Matching refs:wm831x

25 	struct wm831x *wm831x;  member
32 struct wm831x *wm831x = wm831x_gpio->wm831x; in wm831x_gpio_direction_in() local
35 if (wm831x->has_gpio_ena) in wm831x_gpio_direction_in()
38 return wm831x_set_bits(wm831x, WM831X_GPIO1_CONTROL + offset, in wm831x_gpio_direction_in()
46 struct wm831x *wm831x = wm831x_gpio->wm831x; in wm831x_gpio_get() local
49 ret = wm831x_reg_read(wm831x, WM831X_GPIO_LEVEL); in wm831x_gpio_get()
62 struct wm831x *wm831x = wm831x_gpio->wm831x; in wm831x_gpio_set() local
64 wm831x_set_bits(wm831x, WM831X_GPIO_LEVEL, 1 << offset, in wm831x_gpio_set()
72 struct wm831x *wm831x = wm831x_gpio->wm831x; in wm831x_gpio_direction_out() local
76 if (wm831x->has_gpio_ena) in wm831x_gpio_direction_out()
79 ret = wm831x_set_bits(wm831x, WM831X_GPIO1_CONTROL + offset, in wm831x_gpio_direction_out()
94 struct wm831x *wm831x = wm831x_gpio->wm831x; in wm831x_gpio_to_irq() local
96 return irq_create_mapping(wm831x->irq_domain, in wm831x_gpio_to_irq()
100 static int wm831x_gpio_set_debounce(struct wm831x *wm831x, unsigned offset, in wm831x_gpio_set_debounce() argument
106 ret = wm831x_reg_read(wm831x, reg); in wm831x_gpio_set_debounce()
126 return wm831x_set_bits(wm831x, reg, WM831X_GPN_FN_MASK, fn); in wm831x_gpio_set_debounce()
133 struct wm831x *wm831x = wm831x_gpio->wm831x; in wm831x_set_config() local
138 return wm831x_set_bits(wm831x, reg, in wm831x_set_config()
141 return wm831x_set_bits(wm831x, reg, in wm831x_set_config()
144 return wm831x_gpio_set_debounce(wm831x, offset, in wm831x_set_config()
157 struct wm831x *wm831x = wm831x_gpio->wm831x; in wm831x_gpio_dbg_show() local
176 reg = wm831x_reg_read(wm831x, WM831X_GPIO1_CONTROL + i); in wm831x_gpio_dbg_show()
178 dev_err(wm831x->dev, in wm831x_gpio_dbg_show()
227 if (wm831x->has_gpio_ena) in wm831x_gpio_dbg_show()
261 struct wm831x *wm831x = dev_get_drvdata(pdev->dev.parent); in wm831x_gpio_probe() local
262 struct wm831x_pdata *pdata = &wm831x->pdata; in wm831x_gpio_probe()
272 wm831x_gpio->wm831x = wm831x; in wm831x_gpio_probe()
274 wm831x_gpio->gpio_chip.ngpio = wm831x->num_gpio; in wm831x_gpio_probe()