mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-17 09:14:19 +08:00
net: dsa: qca8k: use mdio_module_driver to simplify the code
mdio_module_driver() makes the code simpler by eliminating boilerplate code. Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
fcfbfd68b3
commit
a084ab3354
@ -1032,19 +1032,7 @@ static struct mdio_driver qca8kmdio_driver = {
|
||||
},
|
||||
};
|
||||
|
||||
static int __init
|
||||
qca8kmdio_driver_register(void)
|
||||
{
|
||||
return mdio_driver_register(&qca8kmdio_driver);
|
||||
}
|
||||
module_init(qca8kmdio_driver_register);
|
||||
|
||||
static void __exit
|
||||
qca8kmdio_driver_unregister(void)
|
||||
{
|
||||
mdio_driver_unregister(&qca8kmdio_driver);
|
||||
}
|
||||
module_exit(qca8kmdio_driver_unregister);
|
||||
mdio_module_driver(qca8kmdio_driver);
|
||||
|
||||
MODULE_AUTHOR("Mathieu Olivari, John Crispin <john@phrozen.org>");
|
||||
MODULE_DESCRIPTION("Driver for QCA8K ethernet switch family");
|
||||
|
Loading…
Reference in New Issue
Block a user