thermal: intel: int340x: simplify the code with module_platform_driver()
The init/exit() of the driver only calls platform_driver_{un}register(), so it can be simpilfied by using module_platform_driver(). Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> [ rjw: Subject and changelog edits ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:
parent
b616959a59
commit
1a6e1004f3
@ -70,18 +70,7 @@ static struct platform_driver int3401_driver = {
|
||||
},
|
||||
};
|
||||
|
||||
static int __init proc_thermal_init(void)
|
||||
{
|
||||
return platform_driver_register(&int3401_driver);
|
||||
}
|
||||
|
||||
static void __exit proc_thermal_exit(void)
|
||||
{
|
||||
platform_driver_unregister(&int3401_driver);
|
||||
}
|
||||
|
||||
module_init(proc_thermal_init);
|
||||
module_exit(proc_thermal_exit);
|
||||
module_platform_driver(int3401_driver);
|
||||
|
||||
MODULE_AUTHOR("Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>");
|
||||
MODULE_DESCRIPTION("Processor Thermal Reporting Device Driver");
|
||||
|
Loading…
Reference in New Issue
Block a user