Skip to content

Commit 4606048

Browse files
bigguinessgregkh
authored andcommitted
drivers/ata: use module_pcmcia_driver() in pcmcia drivers
Use the new module_pcmcia_driver() macro to remove the boilerplate module init/exit code in the pcmcia drivers. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 6ed7ffd commit 4606048

1 file changed

Lines changed: 1 addition & 13 deletions

File tree

‎drivers/ata/pata_pcmcia.c‎

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -387,21 +387,9 @@ static struct pcmcia_driver pcmcia_driver = {
387387
.probe = pcmcia_init_one,
388388
.remove = pcmcia_remove_one,
389389
};
390-
391-
static int __init pcmcia_init(void)
392-
{
393-
return pcmcia_register_driver(&pcmcia_driver);
394-
}
395-
396-
static void __exit pcmcia_exit(void)
397-
{
398-
pcmcia_unregister_driver(&pcmcia_driver);
399-
}
390+
module_pcmcia_driver(pcmcia_driver);
400391

401392
MODULE_AUTHOR("Alan Cox");
402393
MODULE_DESCRIPTION("low-level driver for PCMCIA ATA");
403394
MODULE_LICENSE("GPL");
404395
MODULE_VERSION(DRV_VERSION);
405-
406-
module_init(pcmcia_init);
407-
module_exit(pcmcia_exit);

0 commit comments

Comments
 (0)