From b8f70badb8cd7c928f7e076b6143aeb66fe13c8b Mon Sep 17 00:00:00 2001 From: Brian Norris Date: Wed, 11 Nov 2015 19:13:30 -0800 Subject: mtd: kill off MTD partition parser boilerplate Most parsers can be handled with our new boilerplate-reducing macro. There are a few that can't be (cmdlineparts and ofpart). Also kill off the owner assignments, since register_mtd_parser() now takes care of that. Signed-off-by: Brian Norris --- drivers/mtd/bcm63xxpart.c | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) (limited to 'drivers/mtd/bcm63xxpart.c') diff --git a/drivers/mtd/bcm63xxpart.c b/drivers/mtd/bcm63xxpart.c index b2443f7..cf02135 100644 --- a/drivers/mtd/bcm63xxpart.c +++ b/drivers/mtd/bcm63xxpart.c @@ -214,24 +214,10 @@ static int bcm63xx_parse_cfe_partitions(struct mtd_info *master, }; static struct mtd_part_parser bcm63xx_cfe_parser = { - .owner = THIS_MODULE, .parse_fn = bcm63xx_parse_cfe_partitions, .name = "bcm63xxpart", }; - -static int __init bcm63xx_cfe_parser_init(void) -{ - register_mtd_parser(&bcm63xx_cfe_parser); - return 0; -} - -static void __exit bcm63xx_cfe_parser_exit(void) -{ - deregister_mtd_parser(&bcm63xx_cfe_parser); -} - -module_init(bcm63xx_cfe_parser_init); -module_exit(bcm63xx_cfe_parser_exit); +module_mtd_part_parser(bcm63xx_cfe_parser); MODULE_LICENSE("GPL"); MODULE_AUTHOR("Daniel Dickinson "); -- cgit v1.1