Simplify the code by using module_platform_driver macro

for ftmac100

Signed-off-by: Zhichao Cai <caizhichao@yulong.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Zhichao Cai 2021-03-24 10:30:47 +08:00 committed by David S. Miller
parent 69cdfb530f
commit d280a2c2b7

View File

@ -1177,18 +1177,7 @@ static struct platform_driver ftmac100_driver = {
/******************************************************************************
* initialization / finalization
*****************************************************************************/
static int __init ftmac100_init(void)
{
return platform_driver_register(&ftmac100_driver);
}
static void __exit ftmac100_exit(void)
{
platform_driver_unregister(&ftmac100_driver);
}
module_init(ftmac100_init);
module_exit(ftmac100_exit);
module_platform_driver(ftmac100_driver);
MODULE_AUTHOR("Po-Yu Chuang <ratbert@faraday-tech.com>");
MODULE_DESCRIPTION("FTMAC100 driver");