Lines Matching +full:gpo +full:- +full:config +full:-
11 * This driver is based on the gpio-tps65912 implementation.
30 struct tps65218 *tps65218 = tps65218_gpio->tps65218; in tps65218_gpio_get()
34 ret = regmap_read(tps65218->regmap, TPS65218_REG_ENABLE2, &val); in tps65218_gpio_get()
45 struct tps65218 *tps65218 = tps65218_gpio->tps65218; in tps65218_gpio_set()
68 return -EPERM; in tps65218_gpio_input()
74 struct tps65218 *tps65218 = tps65218_gpio->tps65218; in tps65218_gpio_request()
78 dev_err(gc->parent, "can't work as open source\n"); in tps65218_gpio_request()
79 return -EINVAL; in tps65218_gpio_request()
85 dev_err(gc->parent, "GPO1 works only as open drain\n"); in tps65218_gpio_request()
86 return -EINVAL; in tps65218_gpio_request()
116 dev_err(gc->parent, "GPO3 works only as open drain\n"); in tps65218_gpio_request()
117 return -EINVAL; in tps65218_gpio_request()
136 return -EINVAL; in tps65218_gpio_request()
143 unsigned long config) in tps65218_gpio_set_config() argument
146 struct tps65218 *tps65218 = tps65218_gpio->tps65218; in tps65218_gpio_set_config()
147 enum pin_config_param param = pinconf_to_config_param(config); in tps65218_gpio_set_config()
155 return -ENOTSUPP; in tps65218_gpio_set_config()
157 /* GPO2 is push-pull by default, can be set as open drain. */ in tps65218_gpio_set_config()
169 return -ENOTSUPP; in tps65218_gpio_set_config()
173 return -ENOTSUPP; in tps65218_gpio_set_config()
177 .label = "gpio-tps65218",
187 .base = -1,
192 struct tps65218 *tps65218 = dev_get_drvdata(pdev->dev.parent); in tps65218_gpio_probe()
196 tps65218_gpio = devm_kzalloc(&pdev->dev, sizeof(*tps65218_gpio), in tps65218_gpio_probe()
199 return -ENOMEM; in tps65218_gpio_probe()
201 tps65218_gpio->tps65218 = tps65218; in tps65218_gpio_probe()
202 tps65218_gpio->gpio_chip = template_chip; in tps65218_gpio_probe()
203 tps65218_gpio->gpio_chip.parent = &pdev->dev; in tps65218_gpio_probe()
205 tps65218_gpio->gpio_chip.of_node = pdev->dev.of_node; in tps65218_gpio_probe()
208 ret = devm_gpiochip_add_data(&pdev->dev, &tps65218_gpio->gpio_chip, in tps65218_gpio_probe()
211 dev_err(&pdev->dev, "Failed to register gpiochip, %d\n", ret); in tps65218_gpio_probe()
221 { .compatible = "ti,tps65218-gpio" },
227 { "tps65218-gpio", },
234 .name = "tps65218-gpio",
244 MODULE_DESCRIPTION("GPO interface for TPS65218 PMICs");
246 MODULE_ALIAS("platform:tps65218-gpio");