Lines Matching refs:gpio
49 struct lp873x_gpio *gpio = gpiochip_get_data(chip); in lp873x_gpio_direction_output() local
52 return regmap_update_bits(gpio->lp873->regmap, LP873X_REG_GPO_CTRL, in lp873x_gpio_direction_output()
59 struct lp873x_gpio *gpio = gpiochip_get_data(chip); in lp873x_gpio_get() local
62 ret = regmap_read(gpio->lp873->regmap, LP873X_REG_GPO_CTRL, &val); in lp873x_gpio_get()
72 struct lp873x_gpio *gpio = gpiochip_get_data(chip); in lp873x_gpio_set() local
74 regmap_update_bits(gpio->lp873->regmap, LP873X_REG_GPO_CTRL, in lp873x_gpio_set()
81 struct lp873x_gpio *gpio = gpiochip_get_data(gc); in lp873x_gpio_request() local
90 ret = regmap_update_bits(gpio->lp873->regmap, LP873X_REG_CONFIG, in lp873x_gpio_request()
107 struct lp873x_gpio *gpio = gpiochip_get_data(gc); in lp873x_gpio_set_single_ended() local
111 return regmap_update_bits(gpio->lp873->regmap, in lp873x_gpio_set_single_ended()
118 return regmap_update_bits(gpio->lp873->regmap, in lp873x_gpio_set_single_ended()
144 struct lp873x_gpio *gpio; in lp873x_gpio_probe() local
147 gpio = devm_kzalloc(&pdev->dev, sizeof(*gpio), GFP_KERNEL); in lp873x_gpio_probe()
148 if (!gpio) in lp873x_gpio_probe()
151 platform_set_drvdata(pdev, gpio); in lp873x_gpio_probe()
153 gpio->lp873 = dev_get_drvdata(pdev->dev.parent); in lp873x_gpio_probe()
154 gpio->chip = template_chip; in lp873x_gpio_probe()
155 gpio->chip.parent = gpio->lp873->dev; in lp873x_gpio_probe()
157 ret = devm_gpiochip_add_data(&pdev->dev, &gpio->chip, gpio); in lp873x_gpio_probe()