]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
gpio: Switch back to struct platform_driver::remove()
authorUwe Kleine-König <u.kleine-koenig@baylibre.com>
Wed, 16 Oct 2024 15:24:36 +0000 (17:24 +0200)
committerBartosz Golaszewski <bartosz.golaszewski@linaro.org>
Thu, 17 Oct 2024 07:00:48 +0000 (09:00 +0200)
After commit 0edb555a65d1 ("platform: Make platform_driver::remove()
return void") .remove() is (again) the right callback to implement for
platform drivers.

Convert all platform drivers below drivers/gpio/ to use .remove(), with
the eventual goal to drop struct platform_driver::remove_new(). As
.remove() and .remove_new() have the same prototypes, conversion is done
by just changing the structure member name in the driver initializer.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
Link: https://lore.kernel.org/r/20241016152435.38149-2-u.kleine-koenig@baylibre.com
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
22 files changed:
drivers/gpio/gpio-altera.c
drivers/gpio/gpio-brcmstb.c
drivers/gpio/gpio-cadence.c
drivers/gpio/gpio-dln2.c
drivers/gpio/gpio-ftgpio010.c
drivers/gpio/gpio-grgpio.c
drivers/gpio/gpio-lpc18xx.c
drivers/gpio/gpio-mb86s7x.c
drivers/gpio/gpio-mm-lantiq.c
drivers/gpio/gpio-mpc5200.c
drivers/gpio/gpio-mpc8xxx.c
drivers/gpio/gpio-omap.c
drivers/gpio/gpio-rcar.c
drivers/gpio/gpio-rockchip.c
drivers/gpio/gpio-sloppy-logic-analyzer.c
drivers/gpio/gpio-tb10x.c
drivers/gpio/gpio-ts5500.c
drivers/gpio/gpio-uniphier.c
drivers/gpio/gpio-xgene-sb.c
drivers/gpio/gpio-xgs-iproc.c
drivers/gpio/gpio-xilinx.c
drivers/gpio/gpio-zynq.c

index c2edfbb231fc4de83145219d56879dd3b815f1a2..6340134d68c6a9e18171d51692921bd88e190d47 100644 (file)
@@ -336,7 +336,7 @@ static struct platform_driver altera_gpio_driver = {
                .of_match_table = altera_gpio_of_match,
        },
        .probe          = altera_gpio_probe,
-       .remove_new     = altera_gpio_remove,
+       .remove         = altera_gpio_remove,
 };
 
 static int __init altera_gpio_init(void)
index 5762e517338eea0e4ee4bf2f2ed1261d0d2a7938..491b529d25f8d35ec33f015f87586d784dcac7c6 100644 (file)
@@ -751,7 +751,7 @@ static struct platform_driver brcmstb_gpio_driver = {
                .pm = &brcmstb_gpio_pm_ops,
        },
        .probe = brcmstb_gpio_probe,
-       .remove_new = brcmstb_gpio_remove,
+       .remove = brcmstb_gpio_remove,
        .shutdown = brcmstb_gpio_shutdown,
 };
 module_platform_driver(brcmstb_gpio_driver);
index 1b8ffd0ddab65b0349251d293bf7c98ea07703ef..e9dd2564c54f879cf1d49442dfa3db0004473d35 100644 (file)
@@ -277,7 +277,7 @@ static struct platform_driver cdns_gpio_driver = {
                .of_match_table = cdns_of_ids,
        },
        .probe = cdns_gpio_probe,
-       .remove_new = cdns_gpio_remove,
+       .remove = cdns_gpio_remove,
 };
 module_platform_driver(cdns_gpio_driver);
 
index 7ead1f51128ad9432746cef4d6123d4a3cdd0f89..596da59d4b13383ad0696286eb1330492e9dac2c 100644 (file)
@@ -512,7 +512,7 @@ static void dln2_gpio_remove(struct platform_device *pdev)
 static struct platform_driver dln2_gpio_driver = {
        .driver.name    = "dln2-gpio",
        .probe          = dln2_gpio_probe,
-       .remove_new     = dln2_gpio_remove,
+       .remove         = dln2_gpio_remove,
 };
 
 module_platform_driver(dln2_gpio_driver);
index 97d345b5935251b88aff90d2a2bf4fcbf60f835d..5b07749dbdff23d69556b33a1b3cc7630e5fca01 100644 (file)
@@ -350,6 +350,6 @@ static struct platform_driver ftgpio_gpio_driver = {
                .of_match_table = ftgpio_gpio_of_match,
        },
        .probe = ftgpio_gpio_probe,
-       .remove_new = ftgpio_gpio_remove,
+       .remove = ftgpio_gpio_remove,
 };
 builtin_platform_driver(ftgpio_gpio_driver);
index 017c7170eb57c4bc66b0a2c5e0b09fe86e11352c..aa089e195496ff9be0abc1954b5d4a3932308c1c 100644 (file)
@@ -455,7 +455,7 @@ static struct platform_driver grgpio_driver = {
                .of_match_table = grgpio_match,
        },
        .probe = grgpio_probe,
-       .remove_new = grgpio_remove,
+       .remove = grgpio_remove,
 };
 module_platform_driver(grgpio_driver);
 
index e7c0ef6e54fabc272fc957f3e833d37b5e435d46..2cf9fb4637a2bbc7b97b26b4d2c69ba071e9638f 100644 (file)
@@ -388,7 +388,7 @@ MODULE_DEVICE_TABLE(of, lpc18xx_gpio_match);
 
 static struct platform_driver lpc18xx_gpio_driver = {
        .probe  = lpc18xx_gpio_probe,
-       .remove_new = lpc18xx_gpio_remove,
+       .remove = lpc18xx_gpio_remove,
        .driver = {
                .name           = "lpc18xx-gpio",
                .of_match_table = lpc18xx_gpio_match,
index ccbb63c21d6f0591628f4a60ec001825100da61a..7efc9fc6f4cdf0e6a4635796fa3d61664c144686 100644 (file)
@@ -227,7 +227,7 @@ static struct platform_driver mb86s70_gpio_driver = {
                .acpi_match_table = ACPI_PTR(mb86s70_gpio_acpi_ids),
        },
        .probe = mb86s70_gpio_probe,
-       .remove_new = mb86s70_gpio_remove,
+       .remove = mb86s70_gpio_remove,
 };
 module_platform_driver(mb86s70_gpio_driver);
 
index e855c68c981bed57e2a8b25bad217bb50d09c402..14ae257834381186faba94446ea326cb3be99ca2 100644 (file)
@@ -136,7 +136,7 @@ MODULE_DEVICE_TABLE(of, ltq_mm_match);
 
 static struct platform_driver ltq_mm_driver = {
        .probe = ltq_mm_probe,
-       .remove_new = ltq_mm_remove,
+       .remove = ltq_mm_remove,
        .driver = {
                .name = "gpio-mm-ltq",
                .of_match_table = ltq_mm_match,
index a199dce3394a2ef344b51793b03a13024b88374e..091d96f2d682941378d251e95eed88ff16bd39c2 100644 (file)
@@ -183,7 +183,7 @@ static struct platform_driver mpc52xx_wkup_gpiochip_driver = {
                .of_match_table = mpc52xx_wkup_gpiochip_match,
        },
        .probe = mpc52xx_wkup_gpiochip_probe,
-       .remove_new = mpc52xx_gpiochip_remove,
+       .remove = mpc52xx_gpiochip_remove,
 };
 
 /*
@@ -336,7 +336,7 @@ static struct platform_driver mpc52xx_simple_gpiochip_driver = {
                .of_match_table = mpc52xx_simple_gpiochip_match,
        },
        .probe = mpc52xx_simple_gpiochip_probe,
-       .remove_new = mpc52xx_gpiochip_remove,
+       .remove = mpc52xx_gpiochip_remove,
 };
 
 static struct platform_driver * const drivers[] = {
index 2f66e24127f4b2e3b3902cbc514a483b85c8c7b5..24417c3247b0a832ad15fe93e9ba0339eac3b883 100644 (file)
@@ -460,7 +460,7 @@ MODULE_DEVICE_TABLE(acpi, gpio_acpi_ids);
 
 static struct platform_driver mpc8xxx_plat_driver = {
        .probe          = mpc8xxx_probe,
-       .remove_new     = mpc8xxx_remove,
+       .remove         = mpc8xxx_remove,
        .driver         = {
                .name = "gpio-mpc8xxx",
                .of_match_table = mpc8xxx_gpio_ids,
index 76d5d87e9681ebdf3e51653408a7e05ac8db903f..7ad45340549622e49fc3faa6d2cbc4a19425ad92 100644 (file)
@@ -1557,7 +1557,7 @@ static const struct dev_pm_ops gpio_pm_ops = {
 
 static struct platform_driver omap_gpio_driver = {
        .probe          = omap_gpio_probe,
-       .remove_new     = omap_gpio_remove,
+       .remove         = omap_gpio_remove,
        .driver         = {
                .name   = "omap_gpio",
                .pm     = &gpio_pm_ops,
index 6159fda38d5da1bb19b72d83f31c33e503c433bb..2ecee3269a0cc308e06a1ddcac8337eb1ff7b700 100644 (file)
@@ -657,7 +657,7 @@ static SIMPLE_DEV_PM_OPS(gpio_rcar_pm_ops, gpio_rcar_suspend, gpio_rcar_resume);
 
 static struct platform_driver gpio_rcar_device_driver = {
        .probe          = gpio_rcar_probe,
-       .remove_new     = gpio_rcar_remove,
+       .remove         = gpio_rcar_remove,
        .driver         = {
                .name   = "gpio_rcar",
                .pm     = &gpio_rcar_pm_ops,
index 365ab947983cafa998f8c2188044046b4829da8a..a7e115e4352adcf548b682a68c6929e4d024abb5 100644 (file)
@@ -795,7 +795,7 @@ static const struct of_device_id rockchip_gpio_match[] = {
 
 static struct platform_driver rockchip_gpio_driver = {
        .probe          = rockchip_gpio_probe,
-       .remove_new     = rockchip_gpio_remove,
+       .remove         = rockchip_gpio_remove,
        .driver         = {
                .name   = "rockchip-gpio",
                .of_match_table = rockchip_gpio_match,
index 07e0d7180579ccaec1adbd4c62139881c6438f9c..64f2ca4a72b250bbc6d56caa47b5397dd220f5e1 100644 (file)
@@ -311,7 +311,7 @@ MODULE_DEVICE_TABLE(of, gpio_la_poll_of_match);
 
 static struct platform_driver gpio_la_poll_device_driver = {
        .probe = gpio_la_poll_probe,
-       .remove_new = gpio_la_poll_remove,
+       .remove = gpio_la_poll_remove,
        .driver = {
                .name = GPIO_LA_NAME,
                .of_match_table = gpio_la_poll_of_match,
index e8c1485b9c735600a37ad74007d023fd76c976a5..b6335cde455f72f8dcb83940253abf00011d63d4 100644 (file)
@@ -235,7 +235,7 @@ MODULE_DEVICE_TABLE(of, tb10x_gpio_dt_ids);
 
 static struct platform_driver tb10x_gpio_driver = {
        .probe          = tb10x_gpio_probe,
-       .remove_new     = tb10x_gpio_remove,
+       .remove         = tb10x_gpio_remove,
        .driver = {
                .name   = "tb10x-gpio",
                .of_match_table = tb10x_gpio_dt_ids,
index 90f8e9e9915e179d0d0c252cf2e9b9fb70b932f9..61cbec5c06a75bec9c6d940dae2659c4c2554a08 100644 (file)
@@ -433,7 +433,7 @@ static struct platform_driver ts5500_dio_driver = {
                .name = "ts5500-dio",
        },
        .probe = ts5500_dio_probe,
-       .remove_new = ts5500_dio_remove,
+       .remove = ts5500_dio_remove,
        .id_table = ts5500_dio_ids,
 };
 
index da99ba13e82d0c51062553ff7a75317d8dc42cbe..d738da8718f9cf52286ebf14dd4d0ae60466db2e 100644 (file)
@@ -481,7 +481,7 @@ MODULE_DEVICE_TABLE(of, uniphier_gpio_match);
 
 static struct platform_driver uniphier_gpio_driver = {
        .probe = uniphier_gpio_probe,
-       .remove_new = uniphier_gpio_remove,
+       .remove = uniphier_gpio_remove,
        .driver = {
                .name = "uniphier-gpio",
                .of_match_table = uniphier_gpio_match,
index bd5befa807c3281275ab38f43d60a75e80c8107e..836fcf1c82fec50013d35ce8bfcb6f0a3266e85d 100644 (file)
@@ -325,7 +325,7 @@ static struct platform_driver xgene_gpio_sb_driver = {
                   .acpi_match_table = ACPI_PTR(xgene_gpio_sb_acpi_match),
                   },
        .probe = xgene_gpio_sb_probe,
-       .remove_new = xgene_gpio_sb_remove,
+       .remove = xgene_gpio_sb_remove,
 };
 module_platform_driver(xgene_gpio_sb_driver);
 
index d445eea036879673d2cf793ab05837dce567639a..0f9d1f61fee360cb5c6ee4c5c1a71c611e98db5c 100644 (file)
@@ -316,7 +316,7 @@ static struct platform_driver bcm_iproc_gpio_driver = {
                .of_match_table = bcm_iproc_gpio_of_match,
        },
        .probe = iproc_gpio_probe,
-       .remove_new = iproc_gpio_remove,
+       .remove = iproc_gpio_remove,
 };
 
 module_platform_driver(bcm_iproc_gpio_driver);
index 31bb02e133fa0a226864d440d8272bcc801ae2a8..c6a8f2c8268001e344f93da3396d59534b0a581e 100644 (file)
@@ -702,7 +702,7 @@ MODULE_DEVICE_TABLE(of, xgpio_of_match);
 
 static struct platform_driver xgpio_plat_driver = {
        .probe          = xgpio_probe,
-       .remove_new     = xgpio_remove,
+       .remove         = xgpio_remove,
        .driver         = {
                        .name = "gpio-xilinx",
                        .of_match_table = xgpio_of_match,
index 1a42336dfc1d4a1ee4b35b25383948eae48dff71..be81fa2b17abc614c45b1c5a9b4677d281c5217a 100644 (file)
@@ -1023,7 +1023,7 @@ static struct platform_driver zynq_gpio_driver = {
                .of_match_table = zynq_gpio_of_match,
        },
        .probe = zynq_gpio_probe,
-       .remove_new = zynq_gpio_remove,
+       .remove = zynq_gpio_remove,
 };
 
 module_platform_driver(zynq_gpio_driver);