summaryrefslogtreecommitdiffstats
path: root/drivers/w1
diff options
context:
space:
mode:
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>2023-12-04 23:05:22 +0100
committerKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>2023-12-07 14:28:36 +0100
commitdeaba3d687b7cb1a2868bd514fd665ee5efcaaf3 (patch)
tree2a1a4d506e1241428932e568ca35a0762aef223b /drivers/w1
parentw1: gpio: Don't use platform data for driver data (diff)
downloadlinux-deaba3d687b7cb1a2868bd514fd665ee5efcaaf3.tar.xz
linux-deaba3d687b7cb1a2868bd514fd665ee5efcaaf3.zip
w1: gpio: Drop unused enable_external_pullup from driver data
This member is always NULL, so drop it. That makes the suspend and resume callbacks empty, so they can be dropped, too. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Link: https://lore.kernel.org/r/7009fc53745c8e0336e9379022ce648a60c519f8.1701727212.git.u.kleine-koenig@pengutronix.de Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Diffstat (limited to 'drivers/w1')
-rw-r--r--drivers/w1/masters/w1-gpio.c32
1 files changed, 0 insertions, 32 deletions
diff --git a/drivers/w1/masters/w1-gpio.c b/drivers/w1/masters/w1-gpio.c
index 8d65db65178c..67596428f69b 100644
--- a/drivers/w1/masters/w1-gpio.c
+++ b/drivers/w1/masters/w1-gpio.c
@@ -20,7 +20,6 @@
struct w1_gpio_ddata {
struct gpio_desc *gpiod;
struct gpio_desc *pullup_gpiod;
- void (*enable_external_pullup)(int enable);
unsigned int pullup_duration;
};
@@ -134,9 +133,6 @@ static int w1_gpio_probe(struct platform_device *pdev)
return err;
}
- if (pdata->enable_external_pullup)
- pdata->enable_external_pullup(1);
-
if (pdata->pullup_gpiod)
gpiod_set_value(pdata->pullup_gpiod, 1);
@@ -150,9 +146,6 @@ static int w1_gpio_remove(struct platform_device *pdev)
struct w1_bus_master *master = platform_get_drvdata(pdev);
struct w1_gpio_ddata *pdata = master->data;
- if (pdata->enable_external_pullup)
- pdata->enable_external_pullup(0);
-
if (pdata->pullup_gpiod)
gpiod_set_value(pdata->pullup_gpiod, 0);
@@ -161,34 +154,9 @@ static int w1_gpio_remove(struct platform_device *pdev)
return 0;
}
-static int __maybe_unused w1_gpio_suspend(struct device *dev)
-{
- struct w1_bus_master *master = dev_get_drvdata(dev);
- struct w1_gpio_ddata *pdata = master->data;
-
- if (pdata->enable_external_pullup)
- pdata->enable_external_pullup(0);
-
- return 0;
-}
-
-static int __maybe_unused w1_gpio_resume(struct device *dev)
-{
- struct w1_bus_master *master = dev_get_drvdata(dev);
- struct w1_gpio_ddata *pdata = master->data;
-
- if (pdata->enable_external_pullup)
- pdata->enable_external_pullup(1);
-
- return 0;
-}
-
-static SIMPLE_DEV_PM_OPS(w1_gpio_pm_ops, w1_gpio_suspend, w1_gpio_resume);
-
static struct platform_driver w1_gpio_driver = {
.driver = {
.name = "w1-gpio",
- .pm = &w1_gpio_pm_ops,
.of_match_table = of_match_ptr(w1_gpio_dt_ids),
},
.probe = w1_gpio_probe,