mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2024-12-28 16:53:49 +00:00
hwmon: 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/hwmonto 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>
Message-ID: <20241017155900.137357-2-u.kleine-koenig@baylibre.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
This commit is contained in:
parent
0eed6fc3d2
commit
6126f7bb60
@ -1531,7 +1531,7 @@ static struct platform_driver abituguru_driver = {
|
||||
.pm = pm_sleep_ptr(&abituguru_pm),
|
||||
},
|
||||
.probe = abituguru_probe,
|
||||
.remove_new = abituguru_remove,
|
||||
.remove = abituguru_remove,
|
||||
};
|
||||
|
||||
static int __init abituguru_detect(void)
|
||||
|
@ -1147,12 +1147,12 @@ static int abituguru3_resume(struct device *dev)
|
||||
static DEFINE_SIMPLE_DEV_PM_OPS(abituguru3_pm, abituguru3_suspend, abituguru3_resume);
|
||||
|
||||
static struct platform_driver abituguru3_driver = {
|
||||
.driver = {
|
||||
.driver = {
|
||||
.name = ABIT_UGURU3_NAME,
|
||||
.pm = pm_sleep_ptr(&abituguru3_pm),
|
||||
},
|
||||
.probe = abituguru3_probe,
|
||||
.remove_new = abituguru3_remove,
|
||||
.remove = abituguru3_remove,
|
||||
};
|
||||
|
||||
static int __init abituguru3_dmi_detect(void)
|
||||
|
@ -534,7 +534,7 @@ MODULE_DEVICE_TABLE(of, aspeed_pwm_tach_match);
|
||||
|
||||
static struct platform_driver aspeed_pwm_tach_driver = {
|
||||
.probe = aspeed_pwm_tach_probe,
|
||||
.remove_new = aspeed_pwm_tach_remove,
|
||||
.remove = aspeed_pwm_tach_remove,
|
||||
.driver = {
|
||||
.name = "aspeed-g6-pwm-tach",
|
||||
.of_match_table = aspeed_pwm_tach_match,
|
||||
|
@ -473,7 +473,7 @@ static void da9052_hwmon_remove(struct platform_device *pdev)
|
||||
|
||||
static struct platform_driver da9052_hwmon_driver = {
|
||||
.probe = da9052_hwmon_probe,
|
||||
.remove_new = da9052_hwmon_remove,
|
||||
.remove = da9052_hwmon_remove,
|
||||
.driver = {
|
||||
.name = "da9052-hwmon",
|
||||
},
|
||||
|
@ -2721,7 +2721,7 @@ static struct platform_driver dme1737_isa_driver = {
|
||||
.name = "dme1737",
|
||||
},
|
||||
.probe = dme1737_isa_probe,
|
||||
.remove_new = dme1737_isa_remove,
|
||||
.remove = dme1737_isa_remove,
|
||||
};
|
||||
|
||||
/* ---------------------------------------------------------------------
|
||||
|
@ -1497,7 +1497,7 @@ static struct platform_driver f71805f_driver = {
|
||||
.name = DRVNAME,
|
||||
},
|
||||
.probe = f71805f_probe,
|
||||
.remove_new = f71805f_remove,
|
||||
.remove = f71805f_remove,
|
||||
};
|
||||
|
||||
static int __init f71805f_device_add(unsigned short address,
|
||||
|
@ -2658,7 +2658,7 @@ static struct platform_driver f71882fg_driver = {
|
||||
.name = DRVNAME,
|
||||
},
|
||||
.probe = f71882fg_probe,
|
||||
.remove_new = f71882fg_remove,
|
||||
.remove = f71882fg_remove,
|
||||
};
|
||||
|
||||
static int __init f71882fg_init(void)
|
||||
|
@ -568,7 +568,7 @@ static struct platform_driver i5k_amb_driver = {
|
||||
.name = DRVNAME,
|
||||
},
|
||||
.probe = i5k_amb_probe,
|
||||
.remove_new = i5k_amb_remove,
|
||||
.remove = i5k_amb_remove,
|
||||
};
|
||||
|
||||
static int __init i5k_amb_init(void)
|
||||
|
@ -332,7 +332,7 @@ static struct platform_driver max197_driver = {
|
||||
.name = "max197",
|
||||
},
|
||||
.probe = max197_probe,
|
||||
.remove_new = max197_remove,
|
||||
.remove = max197_remove,
|
||||
.id_table = max197_device_ids,
|
||||
};
|
||||
module_platform_driver(max197_driver);
|
||||
|
@ -315,7 +315,7 @@ static const struct platform_device_id mc13783_adc_idtable[] = {
|
||||
MODULE_DEVICE_TABLE(platform, mc13783_adc_idtable);
|
||||
|
||||
static struct platform_driver mc13783_adc_driver = {
|
||||
.remove_new = mc13783_adc_remove,
|
||||
.remove = mc13783_adc_remove,
|
||||
.driver = {
|
||||
.name = DRIVER_NAME,
|
||||
},
|
||||
|
@ -192,8 +192,8 @@ static struct platform_driver p9_sbe_occ_driver = {
|
||||
.name = "occ-hwmon",
|
||||
.of_match_table = p9_sbe_occ_of_match,
|
||||
},
|
||||
.probe = p9_sbe_occ_probe,
|
||||
.remove_new = p9_sbe_occ_remove,
|
||||
.probe = p9_sbe_occ_probe,
|
||||
.remove = p9_sbe_occ_remove,
|
||||
};
|
||||
|
||||
module_platform_driver(p9_sbe_occ_driver);
|
||||
|
@ -1606,7 +1606,7 @@ static struct platform_driver pc87360_driver = {
|
||||
.name = DRIVER_NAME,
|
||||
},
|
||||
.probe = pc87360_probe,
|
||||
.remove_new = pc87360_remove,
|
||||
.remove = pc87360_remove,
|
||||
};
|
||||
|
||||
/*
|
||||
|
@ -1129,7 +1129,7 @@ static struct platform_driver pc87427_driver = {
|
||||
.name = DRVNAME,
|
||||
},
|
||||
.probe = pc87427_probe,
|
||||
.remove_new = pc87427_remove,
|
||||
.remove = pc87427_remove,
|
||||
};
|
||||
|
||||
static int __init pc87427_device_add(const struct pc87427_sio_data *sio_data)
|
||||
|
@ -512,7 +512,7 @@ static struct platform_driver sch5636_driver = {
|
||||
.name = DRVNAME,
|
||||
},
|
||||
.probe = sch5636_probe,
|
||||
.remove_new = sch5636_remove,
|
||||
.remove = sch5636_remove,
|
||||
.id_table = sch5636_device_id,
|
||||
};
|
||||
|
||||
|
@ -1051,7 +1051,7 @@ static struct platform_driver sht15_driver = {
|
||||
.of_match_table = of_match_ptr(sht15_dt_match),
|
||||
},
|
||||
.probe = sht15_probe,
|
||||
.remove_new = sht15_remove,
|
||||
.remove = sht15_remove,
|
||||
.id_table = sht15_device_ids,
|
||||
};
|
||||
module_platform_driver(sht15_driver);
|
||||
|
@ -784,7 +784,7 @@ static struct platform_driver sis5595_driver = {
|
||||
.name = DRIVER_NAME,
|
||||
},
|
||||
.probe = sis5595_probe,
|
||||
.remove_new = sis5595_remove,
|
||||
.remove = sis5595_remove,
|
||||
};
|
||||
|
||||
static int sis5595_pci_probe(struct pci_dev *dev,
|
||||
|
@ -858,7 +858,7 @@ static struct platform_driver smsc47m1_driver __refdata = {
|
||||
.driver = {
|
||||
.name = DRVNAME,
|
||||
},
|
||||
.remove_new = __exit_p(smsc47m1_remove),
|
||||
.remove = __exit_p(smsc47m1_remove),
|
||||
};
|
||||
|
||||
static int __init smsc47m1_device_add(unsigned short address,
|
||||
|
@ -317,7 +317,7 @@ static struct platform_driver env_driver = {
|
||||
.of_match_table = env_match,
|
||||
},
|
||||
.probe = env_probe,
|
||||
.remove_new = env_remove,
|
||||
.remove = env_remove,
|
||||
};
|
||||
|
||||
module_platform_driver(env_driver);
|
||||
|
@ -197,7 +197,7 @@ static struct platform_driver via_cputemp_driver = {
|
||||
.name = DRVNAME,
|
||||
},
|
||||
.probe = via_cputemp_probe,
|
||||
.remove_new = via_cputemp_remove,
|
||||
.remove = via_cputemp_remove,
|
||||
};
|
||||
|
||||
struct pdev_entry {
|
||||
|
@ -799,7 +799,7 @@ static struct platform_driver via686a_driver = {
|
||||
.name = DRIVER_NAME,
|
||||
},
|
||||
.probe = via686a_probe,
|
||||
.remove_new = via686a_remove,
|
||||
.remove = via686a_remove,
|
||||
};
|
||||
|
||||
static const struct pci_device_id via686a_pci_ids[] = {
|
||||
|
@ -1221,7 +1221,7 @@ static struct platform_driver vt1211_driver = {
|
||||
.name = DRVNAME,
|
||||
},
|
||||
.probe = vt1211_probe,
|
||||
.remove_new = vt1211_remove,
|
||||
.remove = vt1211_remove,
|
||||
};
|
||||
|
||||
static int __init vt1211_device_add(unsigned short address)
|
||||
|
@ -910,11 +910,11 @@ static void vt8231_remove(struct platform_device *pdev)
|
||||
|
||||
|
||||
static struct platform_driver vt8231_driver = {
|
||||
.driver = {
|
||||
.driver = {
|
||||
.name = DRIVER_NAME,
|
||||
},
|
||||
.probe = vt8231_probe,
|
||||
.remove_new = vt8231_remove,
|
||||
.remove = vt8231_remove,
|
||||
};
|
||||
|
||||
static const struct pci_device_id vt8231_pci_ids[] = {
|
||||
|
@ -1844,7 +1844,7 @@ static struct platform_driver w83627hf_driver = {
|
||||
.pm = W83627HF_DEV_PM_OPS,
|
||||
},
|
||||
.probe = w83627hf_probe,
|
||||
.remove_new = w83627hf_remove,
|
||||
.remove = w83627hf_remove,
|
||||
};
|
||||
|
||||
static int __init w83627hf_find(int sioaddr, unsigned short *addr,
|
||||
|
@ -1828,7 +1828,7 @@ static struct platform_driver w83781d_isa_driver = {
|
||||
.name = "w83781d",
|
||||
},
|
||||
.probe = w83781d_isa_probe,
|
||||
.remove_new = w83781d_isa_remove,
|
||||
.remove = w83781d_isa_remove,
|
||||
};
|
||||
|
||||
/* return 1 if a supported chip is found, 0 otherwise */
|
||||
|
@ -772,7 +772,7 @@ MODULE_DEVICE_TABLE(of, xgene_hwmon_of_match);
|
||||
|
||||
static struct platform_driver xgene_hwmon_driver = {
|
||||
.probe = xgene_hwmon_probe,
|
||||
.remove_new = xgene_hwmon_remove,
|
||||
.remove = xgene_hwmon_remove,
|
||||
.driver = {
|
||||
.name = "xgene-slimpro-hwmon",
|
||||
.of_match_table = xgene_hwmon_of_match,
|
||||
|
Loading…
Reference in New Issue
Block a user