Message ID | 1442582708.30083.1.camel@ingics.com (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
diff --git a/drivers/nvdimm/e820.c b/drivers/nvdimm/e820.c index 8282db2..fb38836 100644 --- a/drivers/nvdimm/e820.c +++ b/drivers/nvdimm/e820.c @@ -70,18 +70,8 @@ static struct platform_driver e820_pmem_driver = { }, }; -static __init int e820_pmem_init(void) -{ - return platform_driver_register(&e820_pmem_driver); -} - -static __exit void e820_pmem_exit(void) -{ - platform_driver_unregister(&e820_pmem_driver); -} +module_platform_driver(e820_pmem_driver); MODULE_ALIAS("platform:e820_pmem*"); MODULE_LICENSE("GPL v2"); MODULE_AUTHOR("Intel Corporation"); -module_init(e820_pmem_init); -module_exit(e820_pmem_exit);
Use module_platform_driver to simplify the code. Signed-off-by: Axel Lin <axel.lin@ingics.com> --- drivers/nvdimm/e820.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-)