Input: switch back to struct platform_driver::remove()

After commit 0edb555a65 ("platform: Make platform_driver::remove()
return void") .remove() is (again) the right callback to implement for
platform drivers.

Convert all platform drivers below drivers/input/ 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.

While touching these files, make indention of the struct initializer
consistent in a few drivers.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
Link: https://lore.kernel.org/r/20241008090009.462836-2-u.kleine-koenig@baylibre.com
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
This commit is contained in:
Uwe Kleine-König
2024-10-08 11:00:10 +02:00
committed by Dmitry Torokhov
parent 1ec46bf0e4
commit 2c19d01599
51 changed files with 56 additions and 56 deletions

View File

@@ -181,7 +181,7 @@ static struct platform_driver adp5520_keys_driver = {
.name = "adp5520-keys",
},
.probe = adp5520_keys_probe,
.remove_new = adp5520_keys_remove,
.remove = adp5520_keys_remove,
};
module_platform_driver(adp5520_keys_driver);

View File

@@ -770,7 +770,7 @@ static DEFINE_SIMPLE_DEV_PM_OPS(cros_ec_keyb_pm_ops, NULL, cros_ec_keyb_resume);
static struct platform_driver cros_ec_keyb_driver = {
.probe = cros_ec_keyb_probe,
.remove_new = cros_ec_keyb_remove,
.remove = cros_ec_keyb_remove,
.driver = {
.name = "cros-ec-keyb",
.dev_groups = cros_ec_keyb_groups,

View File

@@ -315,7 +315,7 @@ static struct platform_driver ep93xx_keypad_driver = {
.pm = pm_sleep_ptr(&ep93xx_keypad_pm_ops),
},
.probe = ep93xx_keypad_probe,
.remove_new = ep93xx_keypad_remove,
.remove = ep93xx_keypad_remove,
};
module_platform_driver(ep93xx_keypad_driver);

View File

@@ -323,7 +323,7 @@ static struct platform_driver iqs62x_keys_platform_driver = {
.name = "iqs62x-keys",
},
.probe = iqs62x_keys_probe,
.remove_new = iqs62x_keys_remove,
.remove = iqs62x_keys_remove,
};
module_platform_driver(iqs62x_keys_platform_driver);

View File

@@ -290,7 +290,7 @@ static void omap_kp_remove(struct platform_device *pdev)
static struct platform_driver omap_kp_driver = {
.probe = omap_kp_probe,
.remove_new = omap_kp_remove,
.remove = omap_kp_remove,
.driver = {
.name = "omap-keypad",
.dev_groups = omap_kp_groups,

View File

@@ -485,7 +485,7 @@ MODULE_DEVICE_TABLE(of, omap_keypad_dt_match);
static struct platform_driver omap4_keypad_driver = {
.probe = omap4_keypad_probe,
.remove_new = omap4_keypad_remove,
.remove = omap4_keypad_remove,
.driver = {
.name = "omap4-keypad",
.of_match_table = omap_keypad_dt_match,

View File

@@ -587,7 +587,7 @@ MODULE_DEVICE_TABLE(platform, samsung_keypad_driver_ids);
static struct platform_driver samsung_keypad_driver = {
.probe = samsung_keypad_probe,
.remove_new = samsung_keypad_remove,
.remove = samsung_keypad_remove,
.driver = {
.name = "samsung-keypad",
.of_match_table = of_match_ptr(samsung_keypad_dt_match),

View File

@@ -319,7 +319,7 @@ static DEFINE_SIMPLE_DEV_PM_OPS(sh_keysc_dev_pm_ops,
static struct platform_driver sh_keysc_device_driver = {
.probe = sh_keysc_probe,
.remove_new = sh_keysc_remove,
.remove = sh_keysc_remove,
.driver = {
.name = "sh_keysc",
.pm = pm_sleep_ptr(&sh_keysc_dev_pm_ops),

View File

@@ -414,7 +414,7 @@ static void stmpe_keypad_remove(struct platform_device *pdev)
static struct platform_driver stmpe_keypad_driver = {
.driver.name = "stmpe-keypad",
.probe = stmpe_keypad_probe,
.remove_new = stmpe_keypad_remove,
.remove = stmpe_keypad_remove,
};
module_platform_driver(stmpe_keypad_driver);

View File

@@ -141,7 +141,7 @@ static struct platform_driver pm80x_onkey_driver = {
.pm = &pm80x_onkey_pm_ops,
},
.probe = pm80x_onkey_probe,
.remove_new = pm80x_onkey_remove,
.remove = pm80x_onkey_remove,
};
module_platform_driver(pm80x_onkey_driver);

View File

@@ -140,8 +140,8 @@ static void da9052_onkey_remove(struct platform_device *pdev)
static struct platform_driver da9052_onkey_driver = {
.probe = da9052_onkey_probe,
.remove_new = da9052_onkey_remove,
.driver = {
.remove = da9052_onkey_remove,
.driver = {
.name = "da9052-onkey",
},
};

View File

@@ -145,8 +145,8 @@ static void da9055_onkey_remove(struct platform_device *pdev)
static struct platform_driver da9055_onkey_driver = {
.probe = da9055_onkey_probe,
.remove_new = da9055_onkey_remove,
.driver = {
.remove = da9055_onkey_remove,
.driver = {
.name = "da9055-onkey",
},
};

View File

@@ -255,7 +255,7 @@ static struct platform_driver slidebar_drv = {
.driver = {
.name = "ideapad_slidebar",
},
.remove_new = ideapad_remove,
.remove = ideapad_remove,
};
static int __init ideapad_dmi_check(const struct dmi_system_id *id)

View File

@@ -95,7 +95,7 @@ static struct platform_driver m68kspkr_platform_driver = {
.name = "m68kspkr",
},
.probe = m68kspkr_probe,
.remove_new = m68kspkr_remove,
.remove = m68kspkr_remove,
.shutdown = m68kspkr_shutdown,
};

View File

@@ -384,7 +384,7 @@ static struct platform_driver max8997_haptic_driver = {
.pm = pm_sleep_ptr(&max8997_haptic_pm_ops),
},
.probe = max8997_haptic_probe,
.remove_new = max8997_haptic_remove,
.remove = max8997_haptic_remove,
.id_table = max8997_haptic_id,
};
module_platform_driver(max8997_haptic_driver);

View File

@@ -253,7 +253,7 @@ static void mc13783_pwrbutton_remove(struct platform_device *pdev)
static struct platform_driver mc13783_pwrbutton_driver = {
.probe = mc13783_pwrbutton_probe,
.remove_new = mc13783_pwrbutton_remove,
.remove = mc13783_pwrbutton_remove,
.driver = {
.name = "mc13783-pwrbutton",
},

View File

@@ -310,7 +310,7 @@ MODULE_DEVICE_TABLE(of, of_palmas_pwr_match);
static struct platform_driver palmas_pwron_driver = {
.probe = palmas_pwron_probe,
.remove_new = palmas_pwron_remove,
.remove = palmas_pwron_remove,
.driver = {
.name = "palmas_pwrbutton",
.of_match_table = of_match_ptr(of_palmas_pwr_match),

View File

@@ -112,7 +112,7 @@ static void pcap_keys_remove(struct platform_device *pdev)
static struct platform_driver pcap_keys_device_driver = {
.probe = pcap_keys_probe,
.remove_new = pcap_keys_remove,
.remove = pcap_keys_remove,
.driver = {
.name = "pcap-keys",
}

View File

@@ -103,7 +103,7 @@ static struct platform_driver pcf50633_input_driver = {
.name = "pcf50633-input",
},
.probe = pcf50633_input_probe,
.remove_new = pcf50633_input_remove,
.remove = pcf50633_input_remove,
};
module_platform_driver(pcf50633_input_driver);

View File

@@ -127,7 +127,7 @@ static struct platform_driver pcspkr_platform_driver = {
.pm = &pcspkr_pm_ops,
},
.probe = pcspkr_probe,
.remove_new = pcspkr_remove,
.remove = pcspkr_remove,
.shutdown = pcspkr_shutdown,
};
module_platform_driver(pcspkr_platform_driver);

View File

@@ -465,7 +465,7 @@ MODULE_DEVICE_TABLE(of, pm8941_pwr_key_id_table);
static struct platform_driver pm8941_pwrkey_driver = {
.probe = pm8941_pwrkey_probe,
.remove_new = pm8941_pwrkey_remove,
.remove = pm8941_pwrkey_remove,
.driver = {
.name = "pm8941-pwrkey",
.pm = pm_sleep_ptr(&pm8941_pwr_key_pm_ops),

View File

@@ -612,7 +612,7 @@ MODULE_DEVICE_TABLE(acpi, soc_button_acpi_match);
static struct platform_driver soc_button_driver = {
.probe = soc_button_probe,
.remove_new = soc_button_remove,
.remove = soc_button_remove,
.driver = {
.name = KBUILD_MODNAME,
.acpi_match_table = ACPI_PTR(soc_button_acpi_match),

View File

@@ -256,7 +256,7 @@ static struct platform_driver bbc_beep_driver = {
.of_match_table = bbc_beep_match,
},
.probe = bbc_beep_probe,
.remove_new = bbc_remove,
.remove = bbc_remove,
.shutdown = sparcspkr_shutdown,
};
@@ -334,7 +334,7 @@ static struct platform_driver grover_beep_driver = {
.of_match_table = grover_beep_match,
},
.probe = grover_beep_probe,
.remove_new = grover_remove,
.remove = grover_remove,
.shutdown = sparcspkr_shutdown,
};

View File

@@ -137,7 +137,7 @@ MODULE_DEVICE_TABLE(platform, tps65219_pwrbtn_id_table);
static struct platform_driver tps65219_pb_driver = {
.probe = tps65219_pb_probe,
.remove_new = tps65219_pb_remove,
.remove = tps65219_pb_remove,
.driver = {
.name = "tps65219_pwrbutton",
},

View File

@@ -1334,7 +1334,7 @@ static struct platform_driver wistron_driver = {
.pm = pm_sleep_ptr(&wistron_pm_ops),
},
.probe = wistron_probe,
.remove_new = wistron_remove,
.remove = wistron_remove,
};
static int __init wb_module_init(void)

View File

@@ -134,7 +134,7 @@ static void wm831x_on_remove(struct platform_device *pdev)
static struct platform_driver wm831x_on_driver = {
.probe = wm831x_on_probe,
.remove_new = wm831x_on_remove,
.remove = wm831x_on_remove,
.driver = {
.name = "wm831x-on",
},

View File

@@ -139,7 +139,7 @@ static void __exit amimouse_remove(struct platform_device *pdev)
* triggering a section mismatch warning.
*/
static struct platform_driver amimouse_driver __refdata = {
.remove_new = __exit_p(amimouse_remove),
.remove = __exit_p(amimouse_remove),
.driver = {
.name = "amiga-mouse",
},

View File

@@ -146,7 +146,7 @@ MODULE_DEVICE_TABLE(of, altera_ps2_match);
*/
static struct platform_driver altera_ps2_driver = {
.probe = altera_ps2_probe,
.remove_new = altera_ps2_remove,
.remove = altera_ps2_remove,
.driver = {
.name = DRV_NAME,
.of_match_table = of_match_ptr(altera_ps2_match),

View File

@@ -182,7 +182,7 @@ static void ams_delta_serio_exit(struct platform_device *pdev)
static struct platform_driver ams_delta_serio_driver = {
.probe = ams_delta_serio_init,
.remove_new = ams_delta_serio_exit,
.remove = ams_delta_serio_exit,
.driver = {
.name = DRIVER_NAME
},

View File

@@ -208,7 +208,7 @@ static struct platform_driver apbps2_of_driver = {
.of_match_table = apbps2_of_match,
},
.probe = apbps2_of_probe,
.remove_new = apbps2_of_remove,
.remove = apbps2_of_remove,
};
module_platform_driver(apbps2_of_driver);

View File

@@ -260,7 +260,7 @@ static struct platform_driver arc_ps2_driver = {
.of_match_table = of_match_ptr(arc_ps2_match),
},
.probe = arc_ps2_probe,
.remove_new = arc_ps2_remove,
.remove = arc_ps2_remove,
};
module_platform_driver(arc_ps2_driver);

View File

@@ -190,7 +190,7 @@ static struct platform_driver ct82c710_driver = {
.name = "ct82c710",
},
.probe = ct82c710_probe,
.remove_new = ct82c710_remove,
.remove = ct82c710_remove,
};

View File

@@ -101,7 +101,7 @@ static struct platform_driver sparc_i8042_driver = {
.of_match_table = sparc_i8042_match,
},
.probe = sparc_i8042_probe,
.remove_new = sparc_i8042_remove,
.remove = sparc_i8042_remove,
};
static bool i8042_is_mr_coffee(void)

View File

@@ -1590,7 +1590,7 @@ static struct platform_driver i8042_driver = {
#endif
},
.probe = i8042_probe,
.remove_new = i8042_remove,
.remove = i8042_remove,
.shutdown = i8042_shutdown,
};

View File

@@ -208,7 +208,7 @@ MODULE_DEVICE_TABLE(platform, ioc3kbd_id_table);
static struct platform_driver ioc3kbd_driver = {
.probe = ioc3kbd_probe,
.remove_new = ioc3kbd_remove,
.remove = ioc3kbd_remove,
.id_table = ioc3kbd_id_table,
.driver = {
.name = "ioc3-kbd",

View File

@@ -159,7 +159,7 @@ static struct platform_driver maceps2_driver = {
.name = "maceps2",
},
.probe = maceps2_probe,
.remove_new = maceps2_remove,
.remove = maceps2_remove,
};
static int __init maceps2_init(void)

View File

@@ -256,7 +256,7 @@ MODULE_DEVICE_TABLE(of, olpc_apsp_dt_ids);
static struct platform_driver olpc_apsp_driver = {
.probe = olpc_apsp_probe,
.remove_new = olpc_apsp_remove,
.remove = olpc_apsp_remove,
.driver = {
.name = "olpc-apsp",
.of_match_table = olpc_apsp_dt_ids,

View File

@@ -491,7 +491,7 @@ MODULE_DEVICE_TABLE(of, ps2_gpio_match);
static struct platform_driver ps2_gpio_driver = {
.probe = ps2_gpio_probe,
.remove_new = ps2_gpio_remove,
.remove = ps2_gpio_remove,
.driver = {
.name = DRIVER_NAME,
.of_match_table = of_match_ptr(ps2_gpio_match),

View File

@@ -160,7 +160,7 @@ static struct platform_driver q40kbd_driver = {
.driver = {
.name = "q40kbd",
},
.remove_new = q40kbd_remove,
.remove = q40kbd_remove,
};
module_platform_driver_probe(q40kbd_driver, q40kbd_probe);

View File

@@ -144,7 +144,7 @@ static void rpckbd_remove(struct platform_device *dev)
static struct platform_driver rpckbd_driver = {
.probe = rpckbd_probe,
.remove_new = rpckbd_remove,
.remove = rpckbd_remove,
.driver = {
.name = "kart",
},

View File

@@ -318,7 +318,7 @@ MODULE_DEVICE_TABLE(of, sun4i_ps2_match);
static struct platform_driver sun4i_ps2_driver = {
.probe = sun4i_ps2_probe,
.remove_new = sun4i_ps2_remove,
.remove = sun4i_ps2_remove,
.driver = {
.name = DRIVER_NAME,
.of_match_table = sun4i_ps2_match,

View File

@@ -353,7 +353,7 @@ static struct platform_driver xps2_of_driver = {
.of_match_table = xps2_of_match,
},
.probe = xps2_of_probe,
.remove_new = xps2_of_remove,
.remove = xps2_of_remove,
};
module_platform_driver(xps2_of_driver);

View File

@@ -326,7 +326,7 @@ static void da9052_ts_remove(struct platform_device *pdev)
static struct platform_driver da9052_tsi_driver = {
.probe = da9052_ts_probe,
.remove_new = da9052_ts_remove,
.remove = da9052_ts_remove,
.driver = {
.name = "da9052-tsi",
},

View File

@@ -261,7 +261,7 @@ static void mainstone_wm97xx_remove(struct platform_device *pdev)
static struct platform_driver mainstone_wm97xx_driver = {
.probe = mainstone_wm97xx_probe,
.remove_new = mainstone_wm97xx_remove,
.remove = mainstone_wm97xx_remove,
.driver = {
.name = "wm97xx-touch",
},

View File

@@ -226,7 +226,7 @@ static void mc13783_ts_remove(struct platform_device *pdev)
}
static struct platform_driver mc13783_ts_driver = {
.remove_new = mc13783_ts_remove,
.remove = mc13783_ts_remove,
.driver = {
.name = MC13783_TS_NAME,
},

View File

@@ -238,7 +238,7 @@ static const struct dev_pm_ops pcap_ts_pm_ops = {
static struct platform_driver pcap_ts_driver = {
.probe = pcap_ts_probe,
.remove_new = pcap_ts_remove,
.remove = pcap_ts_remove,
.driver = {
.name = "pcap-ts",
.pm = PCAP_TS_PM_OPS,

View File

@@ -362,7 +362,7 @@ static struct platform_driver stmpe_ts_driver = {
.name = STMPE_TS_NAME,
},
.probe = stmpe_input_probe,
.remove_new = stmpe_ts_remove,
.remove = stmpe_ts_remove,
};
module_platform_driver(stmpe_ts_driver);

View File

@@ -396,12 +396,12 @@ static const struct of_device_id sun4i_ts_of_match[] = {
MODULE_DEVICE_TABLE(of, sun4i_ts_of_match);
static struct platform_driver sun4i_ts_driver = {
.driver = {
.driver = {
.name = "sun4i-ts",
.of_match_table = sun4i_ts_of_match,
},
.probe = sun4i_ts_probe,
.remove_new = sun4i_ts_remove,
.remove = sun4i_ts_remove,
};
module_platform_driver(sun4i_ts_driver);

View File

@@ -550,9 +550,9 @@ MODULE_DEVICE_TABLE(of, ti_tsc_dt_ids);
static struct platform_driver ti_tsc_driver = {
.probe = titsc_probe,
.remove_new = titsc_remove,
.remove = titsc_remove,
.driver = {
.name = "TI-am335x-tsc",
.name = "TI-am335x-tsc",
.pm = pm_sleep_ptr(&titsc_pm_ops),
.of_match_table = ti_tsc_dt_ids,
},

View File

@@ -387,7 +387,7 @@ static struct platform_driver wm831x_ts_driver = {
.name = "wm831x-touch",
},
.probe = wm831x_ts_probe,
.remove_new = wm831x_ts_remove,
.remove = wm831x_ts_remove,
};
module_platform_driver(wm831x_ts_driver);

View File

@@ -876,7 +876,7 @@ static struct platform_driver wm97xx_mfd_driver = {
.pm = pm_sleep_ptr(&wm97xx_pm_ops),
},
.probe = wm97xx_mfd_probe,
.remove_new = wm97xx_mfd_remove,
.remove = wm97xx_mfd_remove,
};
static int __init wm97xx_init(void)