Skip to content

Commit

Permalink
net/ethernet/amd/amd8111e: Use module_pci_driver to register driver
Browse files Browse the repository at this point in the history
Removing some boilerplate by using module_pci_driver instead of calling
register and unregister in the otherwise empty init/exit functions.

Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Peter Hüwe authored and David S. Miller committed May 22, 2013
1 parent 5119ad0 commit a46e6cc
Showing 1 changed file with 1 addition and 12 deletions.
13 changes: 1 addition & 12 deletions drivers/net/ethernet/amd/amd8111e.c
Original file line number Diff line number Diff line change
Expand Up @@ -1981,15 +1981,4 @@ static struct pci_driver amd8111e_driver = {
.resume = amd8111e_resume
};

static int __init amd8111e_init(void)
{
return pci_register_driver(&amd8111e_driver);
}

static void __exit amd8111e_cleanup(void)
{
pci_unregister_driver(&amd8111e_driver);
}

module_init(amd8111e_init);
module_exit(amd8111e_cleanup);
module_pci_driver(amd8111e_driver);

0 comments on commit a46e6cc

Please sign in to comment.