Skip to content

Commit

Permalink
staging/et131x: use module_pci_driver macro
Browse files Browse the repository at this point in the history
remove code duplicating module_pci_driver
and also the obvious comments about the _init and _exit points.

Signed-off-by: Devendra Naga <devendra.aaru@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Devendra Naga authored and Greg Kroah-Hartman committed Jul 12, 2012
1 parent 8e4763f commit 89812b1
Showing 1 changed file with 1 addition and 21 deletions.
22 changes: 1 addition & 21 deletions drivers/staging/et131x/et131x.c
Original file line number Diff line number Diff line change
Expand Up @@ -5445,24 +5445,4 @@ static struct pci_driver et131x_driver = {
.driver.pm = ET131X_PM_OPS,
};

/**
* et131x_init_module - The "main" entry point called on driver initialization
*
* Returns 0 on success, errno on failure (as defined in errno.h)
*/
static int __init et131x_init_module(void)
{
return pci_register_driver(&et131x_driver);
}

/**
* et131x_cleanup_module - The entry point called on driver cleanup
*/
static void __exit et131x_cleanup_module(void)
{
pci_unregister_driver(&et131x_driver);
}

module_init(et131x_init_module);
module_exit(et131x_cleanup_module);

module_pci_driver(et131x_driver);

0 comments on commit 89812b1

Please sign in to comment.