summaryrefslogtreecommitdiffstats
path: root/drivers/nfc/pn544
diff options
context:
space:
mode:
authorTomas Winkler <tomas.winkler@intel.com>2016-10-19 16:33:29 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-10-28 08:21:21 -0400
commit094dbffedcc593ad11436d61376b884156ee0bd9 (patch)
tree6818f0baa615b0871cb0d2d44b675971d55f1797 /drivers/nfc/pn544
parentb2a2f70863d2af5445b9a46b099c79cca981d002 (diff)
downloadlinux-094dbffedcc593ad11436d61376b884156ee0bd9.tar.bz2
nfc: mei: use module_mei_cl_driver macro
Replace boilerplate driver registration with module_mei_cl_driver macro in pn544 and microread devices. Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/nfc/pn544')
-rw-r--r--drivers/nfc/pn544/mei.c23
1 files changed, 1 insertions, 22 deletions
diff --git a/drivers/nfc/pn544/mei.c b/drivers/nfc/pn544/mei.c
index 46d0eb24eef9..ad57a8ec00d6 100644
--- a/drivers/nfc/pn544/mei.c
+++ b/drivers/nfc/pn544/mei.c
@@ -82,28 +82,7 @@ static struct mei_cl_driver pn544_driver = {
.remove = pn544_mei_remove,
};
-static int pn544_mei_init(void)
-{
- int r;
-
- pr_debug(DRIVER_DESC ": %s\n", __func__);
-
- r = mei_cldev_driver_register(&pn544_driver);
- if (r) {
- pr_err(PN544_DRIVER_NAME ": driver registration failed\n");
- return r;
- }
-
- return 0;
-}
-
-static void pn544_mei_exit(void)
-{
- mei_cldev_driver_unregister(&pn544_driver);
-}
-
-module_init(pn544_mei_init);
-module_exit(pn544_mei_exit);
+module_mei_cl_driver(pn544_driver);
MODULE_LICENSE("GPL");
MODULE_DESCRIPTION(DRIVER_DESC);