Skip to content

Commit

Permalink
scsi: am53c974: Use module_pci_driver
Browse files Browse the repository at this point in the history
Remove boilerplate code by using macro module_pci_driver.

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
  • Loading branch information
YueHaibing authored and Martin K. Petersen committed May 2, 2018
1 parent 63aed10 commit 5f1c721
Showing 1 changed file with 1 addition and 12 deletions.
13 changes: 1 addition & 12 deletions drivers/scsi/am53c974.c
Original file line number Diff line number Diff line change
Expand Up @@ -556,15 +556,7 @@ static struct pci_driver am53c974_driver = {
.remove = pci_esp_remove_one,
};

static int __init am53c974_module_init(void)
{
return pci_register_driver(&am53c974_driver);
}

static void __exit am53c974_module_exit(void)
{
pci_unregister_driver(&am53c974_driver);
}
module_pci_driver(am53c974_driver);

MODULE_DESCRIPTION("AM53C974 SCSI driver");
MODULE_AUTHOR("Hannes Reinecke <hare@suse.de>");
Expand All @@ -577,6 +569,3 @@ MODULE_PARM_DESC(am53c974_debug, "Enable debugging");

module_param(am53c974_fenab, bool, 0444);
MODULE_PARM_DESC(am53c974_fenab, "Enable 24-bit DMA transfer sizes");

module_init(am53c974_module_init);
module_exit(am53c974_module_exit);

0 comments on commit 5f1c721

Please sign in to comment.