mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2024-12-28 16:53:49 +00:00
iio: 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/iio/ 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 several files.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
Link: https://patch.msgid.link/20241009060056.502059-2-u.kleine-koenig@baylibre.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
This commit is contained in:
parent
92accba976
commit
6a9262edff
@ -451,7 +451,7 @@ static struct platform_driver hid_accel_3d_platform_driver = {
|
||||
.pm = &hid_sensor_pm_ops,
|
||||
},
|
||||
.probe = hid_accel_3d_probe,
|
||||
.remove_new = hid_accel_3d_remove,
|
||||
.remove = hid_accel_3d_remove,
|
||||
};
|
||||
module_platform_driver(hid_accel_3d_platform_driver);
|
||||
|
||||
|
@ -1194,7 +1194,7 @@ static DEFINE_RUNTIME_DEV_PM_OPS(ab8500_gpadc_pm_ops,
|
||||
|
||||
static struct platform_driver ab8500_gpadc_driver = {
|
||||
.probe = ab8500_gpadc_probe,
|
||||
.remove_new = ab8500_gpadc_remove,
|
||||
.remove = ab8500_gpadc_remove,
|
||||
.driver = {
|
||||
.name = "ab8500-gpadc",
|
||||
.pm = pm_ptr(&ab8500_gpadc_pm_ops),
|
||||
|
@ -2625,7 +2625,7 @@ MODULE_DEVICE_TABLE(of, at91_adc_dt_match);
|
||||
|
||||
static struct platform_driver at91_adc_driver = {
|
||||
.probe = at91_adc_probe,
|
||||
.remove_new = at91_adc_remove,
|
||||
.remove = at91_adc_remove,
|
||||
.driver = {
|
||||
.name = "at91-sama5d2_adc",
|
||||
.of_match_table = at91_adc_dt_match,
|
||||
|
@ -1341,7 +1341,7 @@ MODULE_DEVICE_TABLE(of, at91_adc_dt_ids);
|
||||
|
||||
static struct platform_driver at91_adc_driver = {
|
||||
.probe = at91_adc_probe,
|
||||
.remove_new = at91_adc_remove,
|
||||
.remove = at91_adc_remove,
|
||||
.driver = {
|
||||
.name = DRIVER_NAME,
|
||||
.of_match_table = at91_adc_dt_ids,
|
||||
|
@ -1182,7 +1182,7 @@ static struct platform_driver axp20x_adc_driver = {
|
||||
},
|
||||
.id_table = axp20x_adc_id_match,
|
||||
.probe = axp20x_probe,
|
||||
.remove_new = axp20x_remove,
|
||||
.remove = axp20x_remove,
|
||||
};
|
||||
|
||||
module_platform_driver(axp20x_adc_driver);
|
||||
|
@ -611,10 +611,10 @@ static const struct of_device_id iproc_adc_of_match[] = {
|
||||
MODULE_DEVICE_TABLE(of, iproc_adc_of_match);
|
||||
|
||||
static struct platform_driver iproc_adc_driver = {
|
||||
.probe = iproc_adc_probe,
|
||||
.remove_new = iproc_adc_remove,
|
||||
.driver = {
|
||||
.name = "iproc-static-adc",
|
||||
.probe = iproc_adc_probe,
|
||||
.remove = iproc_adc_remove,
|
||||
.driver = {
|
||||
.name = "iproc-static-adc",
|
||||
.of_match_table = iproc_adc_of_match,
|
||||
},
|
||||
};
|
||||
|
@ -700,7 +700,7 @@ static void dln2_adc_remove(struct platform_device *pdev)
|
||||
static struct platform_driver dln2_adc_driver = {
|
||||
.driver.name = DLN2_ADC_MOD_NAME,
|
||||
.probe = dln2_adc_probe,
|
||||
.remove_new = dln2_adc_remove,
|
||||
.remove = dln2_adc_remove,
|
||||
};
|
||||
|
||||
module_platform_driver(dln2_adc_driver);
|
||||
|
@ -238,7 +238,7 @@ static struct platform_driver ep93xx_adc_driver = {
|
||||
.of_match_table = ep93xx_adc_of_ids,
|
||||
},
|
||||
.probe = ep93xx_adc_probe,
|
||||
.remove_new = ep93xx_adc_remove,
|
||||
.remove = ep93xx_adc_remove,
|
||||
};
|
||||
module_platform_driver(ep93xx_adc_driver);
|
||||
|
||||
|
@ -1008,7 +1008,7 @@ static DEFINE_SIMPLE_DEV_PM_OPS(exynos_adc_pm_ops, exynos_adc_suspend,
|
||||
|
||||
static struct platform_driver exynos_adc_driver = {
|
||||
.probe = exynos_adc_probe,
|
||||
.remove_new = exynos_adc_remove,
|
||||
.remove = exynos_adc_remove,
|
||||
.driver = {
|
||||
.name = "exynos-adc",
|
||||
.of_match_table = exynos_adc_match,
|
||||
|
@ -487,7 +487,7 @@ MODULE_DEVICE_TABLE(of, imx8qxp_adc_match);
|
||||
|
||||
static struct platform_driver imx8qxp_adc_driver = {
|
||||
.probe = imx8qxp_adc_probe,
|
||||
.remove_new = imx8qxp_adc_remove,
|
||||
.remove = imx8qxp_adc_remove,
|
||||
.driver = {
|
||||
.name = ADC_DRIVER_NAME,
|
||||
.of_match_table = imx8qxp_adc_match,
|
||||
|
@ -470,7 +470,7 @@ MODULE_DEVICE_TABLE(of, imx93_adc_match);
|
||||
|
||||
static struct platform_driver imx93_adc_driver = {
|
||||
.probe = imx93_adc_probe,
|
||||
.remove_new = imx93_adc_remove,
|
||||
.remove = imx93_adc_remove,
|
||||
.driver = {
|
||||
.name = IMX93_ADC_DRIVER_NAME,
|
||||
.of_match_table = imx93_adc_match,
|
||||
|
@ -1483,7 +1483,7 @@ static DEFINE_SIMPLE_DEV_PM_OPS(meson_sar_adc_pm_ops,
|
||||
|
||||
static struct platform_driver meson_sar_adc_driver = {
|
||||
.probe = meson_sar_adc_probe,
|
||||
.remove_new = meson_sar_adc_remove,
|
||||
.remove = meson_sar_adc_remove,
|
||||
.driver = {
|
||||
.name = "meson-saradc",
|
||||
.of_match_table = meson_sar_adc_of_match,
|
||||
|
@ -195,7 +195,7 @@ static struct platform_driver mp2629_adc_driver = {
|
||||
.of_match_table = mp2629_adc_of_match,
|
||||
},
|
||||
.probe = mp2629_adc_probe,
|
||||
.remove_new = mp2629_adc_remove,
|
||||
.remove = mp2629_adc_remove,
|
||||
};
|
||||
module_platform_driver(mp2629_adc_driver);
|
||||
|
||||
|
@ -819,10 +819,10 @@ static void mxs_lradc_adc_remove(struct platform_device *pdev)
|
||||
|
||||
static struct platform_driver mxs_lradc_adc_driver = {
|
||||
.driver = {
|
||||
.name = "mxs-lradc-adc",
|
||||
.name = "mxs-lradc-adc",
|
||||
},
|
||||
.probe = mxs_lradc_adc_probe,
|
||||
.remove_new = mxs_lradc_adc_remove,
|
||||
.probe = mxs_lradc_adc_probe,
|
||||
.remove = mxs_lradc_adc_remove,
|
||||
};
|
||||
module_platform_driver(mxs_lradc_adc_driver);
|
||||
|
||||
|
@ -337,7 +337,7 @@ static void npcm_adc_remove(struct platform_device *pdev)
|
||||
|
||||
static struct platform_driver npcm_adc_driver = {
|
||||
.probe = npcm_adc_probe,
|
||||
.remove_new = npcm_adc_remove,
|
||||
.remove = npcm_adc_remove,
|
||||
.driver = {
|
||||
.name = "npcm_adc",
|
||||
.of_match_table = npcm_adc_match,
|
||||
|
@ -1014,7 +1014,7 @@ static struct platform_driver pm8xxx_xoadc_driver = {
|
||||
.of_match_table = pm8xxx_xoadc_id_table,
|
||||
},
|
||||
.probe = pm8xxx_xoadc_probe,
|
||||
.remove_new = pm8xxx_xoadc_remove,
|
||||
.remove = pm8xxx_xoadc_remove,
|
||||
};
|
||||
module_platform_driver(pm8xxx_xoadc_driver);
|
||||
|
||||
|
@ -592,7 +592,7 @@ static const struct dev_pm_ops rcar_gyroadc_pm_ops = {
|
||||
|
||||
static struct platform_driver rcar_gyroadc_driver = {
|
||||
.probe = rcar_gyroadc_probe,
|
||||
.remove_new = rcar_gyroadc_remove,
|
||||
.remove = rcar_gyroadc_remove,
|
||||
.driver = {
|
||||
.name = DRIVER_NAME,
|
||||
.of_match_table = rcar_gyroadc_match,
|
||||
|
@ -906,7 +906,7 @@ MODULE_DEVICE_TABLE(of, stm32_adc_of_match);
|
||||
|
||||
static struct platform_driver stm32_adc_driver = {
|
||||
.probe = stm32_adc_probe,
|
||||
.remove_new = stm32_adc_remove,
|
||||
.remove = stm32_adc_remove,
|
||||
.driver = {
|
||||
.name = "stm32-adc-core",
|
||||
.of_match_table = stm32_adc_of_match,
|
||||
|
@ -2644,7 +2644,7 @@ MODULE_DEVICE_TABLE(of, stm32_adc_of_match);
|
||||
|
||||
static struct platform_driver stm32_adc_driver = {
|
||||
.probe = stm32_adc_probe,
|
||||
.remove_new = stm32_adc_remove,
|
||||
.remove = stm32_adc_remove,
|
||||
.driver = {
|
||||
.name = "stm32-adc",
|
||||
.of_match_table = stm32_adc_of_match,
|
||||
|
@ -1890,7 +1890,7 @@ static struct platform_driver stm32_dfsdm_adc_driver = {
|
||||
.pm = pm_sleep_ptr(&stm32_dfsdm_adc_pm_ops),
|
||||
},
|
||||
.probe = stm32_dfsdm_adc_probe,
|
||||
.remove_new = stm32_dfsdm_adc_remove,
|
||||
.remove = stm32_dfsdm_adc_remove,
|
||||
};
|
||||
module_platform_driver(stm32_dfsdm_adc_driver);
|
||||
|
||||
|
@ -506,7 +506,7 @@ static const struct dev_pm_ops stm32_dfsdm_core_pm_ops = {
|
||||
|
||||
static struct platform_driver stm32_dfsdm_driver = {
|
||||
.probe = stm32_dfsdm_probe,
|
||||
.remove_new = stm32_dfsdm_core_remove,
|
||||
.remove = stm32_dfsdm_core_remove,
|
||||
.driver = {
|
||||
.name = "stm32-dfsdm",
|
||||
.of_match_table = stm32_dfsdm_of_match,
|
||||
|
@ -697,7 +697,7 @@ static struct platform_driver sun4i_gpadc_driver = {
|
||||
},
|
||||
.id_table = sun4i_gpadc_id,
|
||||
.probe = sun4i_gpadc_probe,
|
||||
.remove_new = sun4i_gpadc_remove,
|
||||
.remove = sun4i_gpadc_remove,
|
||||
};
|
||||
MODULE_DEVICE_TABLE(of, sun4i_gpadc_of_id);
|
||||
|
||||
|
@ -740,12 +740,12 @@ MODULE_DEVICE_TABLE(of, ti_adc_dt_ids);
|
||||
|
||||
static struct platform_driver tiadc_driver = {
|
||||
.driver = {
|
||||
.name = "TI-am335x-adc",
|
||||
.pm = pm_sleep_ptr(&tiadc_pm_ops),
|
||||
.name = "TI-am335x-adc",
|
||||
.pm = pm_sleep_ptr(&tiadc_pm_ops),
|
||||
.of_match_table = ti_adc_dt_ids,
|
||||
},
|
||||
.probe = tiadc_probe,
|
||||
.remove_new = tiadc_remove,
|
||||
.probe = tiadc_probe,
|
||||
.remove = tiadc_remove,
|
||||
};
|
||||
module_platform_driver(tiadc_driver);
|
||||
|
||||
|
@ -914,7 +914,7 @@ MODULE_DEVICE_TABLE(of, twl_madc_of_match);
|
||||
|
||||
static struct platform_driver twl4030_madc_driver = {
|
||||
.probe = twl4030_madc_probe,
|
||||
.remove_new = twl4030_madc_remove,
|
||||
.remove = twl4030_madc_remove,
|
||||
.driver = {
|
||||
.name = "twl4030_madc",
|
||||
.of_match_table = twl_madc_of_match,
|
||||
|
@ -1003,7 +1003,7 @@ static DEFINE_SIMPLE_DEV_PM_OPS(twl6030_gpadc_pm_ops, twl6030_gpadc_suspend,
|
||||
|
||||
static struct platform_driver twl6030_gpadc_driver = {
|
||||
.probe = twl6030_gpadc_probe,
|
||||
.remove_new = twl6030_gpadc_remove,
|
||||
.remove = twl6030_gpadc_remove,
|
||||
.driver = {
|
||||
.name = DRIVER_NAME,
|
||||
.pm = pm_sleep_ptr(&twl6030_gpadc_pm_ops),
|
||||
|
@ -972,7 +972,7 @@ static DEFINE_SIMPLE_DEV_PM_OPS(vf610_adc_pm_ops, vf610_adc_suspend,
|
||||
|
||||
static struct platform_driver vf610_adc_driver = {
|
||||
.probe = vf610_adc_probe,
|
||||
.remove_new = vf610_adc_remove,
|
||||
.remove = vf610_adc_remove,
|
||||
.driver = {
|
||||
.name = DRIVER_NAME,
|
||||
.of_match_table = vf610_adc_match,
|
||||
|
@ -243,7 +243,7 @@ MODULE_DEVICE_TABLE(of, dpot_dac_match);
|
||||
|
||||
static struct platform_driver dpot_dac_driver = {
|
||||
.probe = dpot_dac_probe,
|
||||
.remove_new = dpot_dac_remove,
|
||||
.remove = dpot_dac_remove,
|
||||
.driver = {
|
||||
.name = "iio-dpot-dac",
|
||||
.of_match_table = dpot_dac_match,
|
||||
|
@ -184,9 +184,9 @@ static const struct of_device_id lpc18xx_dac_match[] = {
|
||||
MODULE_DEVICE_TABLE(of, lpc18xx_dac_match);
|
||||
|
||||
static struct platform_driver lpc18xx_dac_driver = {
|
||||
.probe = lpc18xx_dac_probe,
|
||||
.remove_new = lpc18xx_dac_remove,
|
||||
.driver = {
|
||||
.probe = lpc18xx_dac_probe,
|
||||
.remove = lpc18xx_dac_remove,
|
||||
.driver = {
|
||||
.name = "lpc18xx-dac",
|
||||
.of_match_table = lpc18xx_dac_match,
|
||||
},
|
||||
|
@ -245,7 +245,7 @@ MODULE_DEVICE_TABLE(of, stm32_dac_of_match);
|
||||
|
||||
static struct platform_driver stm32_dac_driver = {
|
||||
.probe = stm32_dac_probe,
|
||||
.remove_new = stm32_dac_remove,
|
||||
.remove = stm32_dac_remove,
|
||||
.driver = {
|
||||
.name = "stm32-dac-core",
|
||||
.of_match_table = stm32_dac_of_match,
|
||||
|
@ -398,7 +398,7 @@ MODULE_DEVICE_TABLE(of, stm32_dac_of_match);
|
||||
|
||||
static struct platform_driver stm32_dac_driver = {
|
||||
.probe = stm32_dac_probe,
|
||||
.remove_new = stm32_dac_remove,
|
||||
.remove = stm32_dac_remove,
|
||||
.driver = {
|
||||
.name = "stm32-dac",
|
||||
.of_match_table = stm32_dac_of_match,
|
||||
|
@ -272,7 +272,7 @@ static DEFINE_SIMPLE_DEV_PM_OPS(vf610_dac_pm_ops, vf610_dac_suspend,
|
||||
|
||||
static struct platform_driver vf610_dac_driver = {
|
||||
.probe = vf610_dac_probe,
|
||||
.remove_new = vf610_dac_remove,
|
||||
.remove = vf610_dac_remove,
|
||||
.driver = {
|
||||
.name = "vf610-dac",
|
||||
.of_match_table = vf610_dac_match,
|
||||
|
@ -386,7 +386,7 @@ static struct platform_driver hid_gyro_3d_platform_driver = {
|
||||
.pm = &hid_sensor_pm_ops,
|
||||
},
|
||||
.probe = hid_gyro_3d_probe,
|
||||
.remove_new = hid_gyro_3d_remove,
|
||||
.remove = hid_gyro_3d_remove,
|
||||
};
|
||||
module_platform_driver(hid_gyro_3d_platform_driver);
|
||||
|
||||
|
@ -287,7 +287,7 @@ static struct platform_driver hid_humidity_platform_driver = {
|
||||
.pm = &hid_sensor_pm_ops,
|
||||
},
|
||||
.probe = hid_humidity_probe,
|
||||
.remove_new = hid_humidity_remove,
|
||||
.remove = hid_humidity_remove,
|
||||
};
|
||||
module_platform_driver(hid_humidity_platform_driver);
|
||||
|
||||
|
@ -318,7 +318,7 @@ static struct platform_driver cm3605_driver = {
|
||||
.pm = pm_sleep_ptr(&cm3605_dev_pm_ops),
|
||||
},
|
||||
.probe = cm3605_probe,
|
||||
.remove_new = cm3605_remove,
|
||||
.remove = cm3605_remove,
|
||||
};
|
||||
module_platform_driver(cm3605_driver);
|
||||
|
||||
|
@ -467,7 +467,7 @@ static struct platform_driver hid_als_platform_driver = {
|
||||
.pm = &hid_sensor_pm_ops,
|
||||
},
|
||||
.probe = hid_als_probe,
|
||||
.remove_new = hid_als_remove,
|
||||
.remove = hid_als_remove,
|
||||
};
|
||||
module_platform_driver(hid_als_platform_driver);
|
||||
|
||||
|
@ -344,7 +344,7 @@ static struct platform_driver hid_prox_platform_driver = {
|
||||
.pm = &hid_sensor_pm_ops,
|
||||
},
|
||||
.probe = hid_prox_probe,
|
||||
.remove_new = hid_prox_remove,
|
||||
.remove = hid_prox_remove,
|
||||
};
|
||||
module_platform_driver(hid_prox_platform_driver);
|
||||
|
||||
|
@ -912,7 +912,7 @@ static struct platform_driver lm3533_als_driver = {
|
||||
.name = "lm3533-als",
|
||||
},
|
||||
.probe = lm3533_als_probe,
|
||||
.remove_new = lm3533_als_remove,
|
||||
.remove = lm3533_als_remove,
|
||||
};
|
||||
module_platform_driver(lm3533_als_driver);
|
||||
|
||||
|
@ -574,7 +574,7 @@ static struct platform_driver hid_magn_3d_platform_driver = {
|
||||
.pm = &hid_sensor_pm_ops,
|
||||
},
|
||||
.probe = hid_magn_3d_probe,
|
||||
.remove_new = hid_magn_3d_remove,
|
||||
.remove = hid_magn_3d_remove,
|
||||
};
|
||||
module_platform_driver(hid_magn_3d_platform_driver);
|
||||
|
||||
|
@ -410,7 +410,7 @@ static struct platform_driver hid_incl_3d_platform_driver = {
|
||||
.pm = &hid_sensor_pm_ops,
|
||||
},
|
||||
.probe = hid_incl_3d_probe,
|
||||
.remove_new = hid_incl_3d_remove,
|
||||
.remove = hid_incl_3d_remove,
|
||||
};
|
||||
module_platform_driver(hid_incl_3d_platform_driver);
|
||||
|
||||
|
@ -362,7 +362,7 @@ static struct platform_driver hid_dev_rot_platform_driver = {
|
||||
.pm = &hid_sensor_pm_ops,
|
||||
},
|
||||
.probe = hid_dev_rot_probe,
|
||||
.remove_new = hid_dev_rot_remove,
|
||||
.remove = hid_dev_rot_remove,
|
||||
};
|
||||
module_platform_driver(hid_dev_rot_platform_driver);
|
||||
|
||||
|
@ -369,7 +369,7 @@ static struct platform_driver hid_hinge_platform_driver = {
|
||||
.pm = &hid_sensor_pm_ops,
|
||||
},
|
||||
.probe = hid_hinge_probe,
|
||||
.remove_new = hid_hinge_remove,
|
||||
.remove = hid_hinge_remove,
|
||||
};
|
||||
module_platform_driver(hid_hinge_platform_driver);
|
||||
|
||||
|
@ -350,7 +350,7 @@ static struct platform_driver hid_press_platform_driver = {
|
||||
.pm = &hid_sensor_pm_ops,
|
||||
},
|
||||
.probe = hid_press_probe,
|
||||
.remove_new = hid_press_remove,
|
||||
.remove = hid_press_remove,
|
||||
};
|
||||
module_platform_driver(hid_press_platform_driver);
|
||||
|
||||
|
@ -261,7 +261,7 @@ static struct platform_driver cros_ec_mkbp_proximity_driver = {
|
||||
.pm = pm_sleep_ptr(&cros_ec_mkbp_proximity_pm_ops),
|
||||
},
|
||||
.probe = cros_ec_mkbp_proximity_probe,
|
||||
.remove_new = cros_ec_mkbp_proximity_remove,
|
||||
.remove = cros_ec_mkbp_proximity_remove,
|
||||
};
|
||||
module_platform_driver(cros_ec_mkbp_proximity_driver);
|
||||
|
||||
|
@ -389,7 +389,7 @@ static const struct dev_pm_ops srf04_pm_ops = {
|
||||
|
||||
static struct platform_driver srf04_driver = {
|
||||
.probe = srf04_probe,
|
||||
.remove_new = srf04_remove,
|
||||
.remove = srf04_remove,
|
||||
.driver = {
|
||||
.name = "srf04-gpio",
|
||||
.of_match_table = of_srf04_match,
|
||||
|
@ -283,7 +283,7 @@ static struct platform_driver hid_temperature_platform_driver = {
|
||||
.pm = &hid_sensor_pm_ops,
|
||||
},
|
||||
.probe = hid_temperature_probe,
|
||||
.remove_new = hid_temperature_remove,
|
||||
.remove = hid_temperature_remove,
|
||||
};
|
||||
module_platform_driver(hid_temperature_platform_driver);
|
||||
|
||||
|
@ -96,7 +96,7 @@ static void iio_interrupt_trigger_remove(struct platform_device *pdev)
|
||||
|
||||
static struct platform_driver iio_interrupt_trigger_driver = {
|
||||
.probe = iio_interrupt_trigger_probe,
|
||||
.remove_new = iio_interrupt_trigger_remove,
|
||||
.remove = iio_interrupt_trigger_remove,
|
||||
.driver = {
|
||||
.name = "iio_interrupt_trigger",
|
||||
},
|
||||
|
@ -900,7 +900,7 @@ MODULE_DEVICE_TABLE(of, stm32_trig_of_match);
|
||||
|
||||
static struct platform_driver stm32_timer_trigger_driver = {
|
||||
.probe = stm32_timer_trigger_probe,
|
||||
.remove_new = stm32_timer_trigger_remove,
|
||||
.remove = stm32_timer_trigger_remove,
|
||||
.driver = {
|
||||
.name = "stm32-timer-trigger",
|
||||
.of_match_table = stm32_trig_of_match,
|
||||
|
Loading…
Reference in New Issue
Block a user