提交 395a5738 编写于 作者: A alex.bluesman.smirnov@gmail.com 提交者: David S. Miller

drivers/ieee802154/at86rf230: replace the code under _init and _exit by macro

The code under _init and _exit functions is similar to the code of
module_spi_driver macro, which is a wrapper to the module_driver macro,
so use it instead.
Signed-off-by: NAlexander Smirnov <alex.bluesman.smirnov@gmail.com>
Cc: Devendra Naga <develkernel412222@gmail.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 9eca2eb9
......@@ -952,17 +952,7 @@ static struct spi_driver at86rf230_driver = {
.resume = at86rf230_resume,
};
static int __init at86rf230_init(void)
{
return spi_register_driver(&at86rf230_driver);
}
module_init(at86rf230_init);
static void __exit at86rf230_exit(void)
{
spi_unregister_driver(&at86rf230_driver);
}
module_exit(at86rf230_exit);
module_spi_driver(at86rf230_driver);
MODULE_DESCRIPTION("AT86RF230 Transceiver Driver");
MODULE_LICENSE("GPL v2");
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册