Skip to contentSkip to conversation

mtd: parsers: ofpart: fix building as module

PATCH New Rafał Miłecki 1 participant 1 message Feb 15, 2021 Memory technology devices (MTD)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mtd: parsers: ofpart: fix building as module

From: Rafał Miłecki <[email protected]>

This fixes:
ERROR: modpost: missing MODULE_LICENSE() in drivers/mtd/parsers/bcm4908-partitions.o
ERROR: modpost: "bcm4908_partitions_post_parse" [drivers/mtd/parsers/ofpart.ko] undefined!

Fixes 09cf6ee6d21c ("mtd: parsers: ofpart: support BCM4908 fixed partitions")
---
 drivers/mtd/parsers/Makefile             | 2 +-
 drivers/mtd/parsers/bcm4908-partitions.c | 2 ++
 2 files changed, 3 insertions(+), 1 deletion(-)
drivers/mtd/parsers/Makefile +1 -1
index 01972a5edc5c..bf58a5221730 100644
@@ -4,7 +4,7 @@ obj-$(CONFIG_MTD_BCM47XX_PARTS)		+= bcm47xxpart.o
 obj-$(CONFIG_MTD_BCM63XX_PARTS)		+= bcm63xxpart.o
 obj-$(CONFIG_MTD_CMDLINE_PARTS)		+= cmdlinepart.o
 obj-$(CONFIG_MTD_OF_PARTS)		+= ofpart.o
-obj-$(CONFIG_MTD_OF_PARTS)		+= bcm4908-partitions.o
+ofpart-objs				:= bcm4908-partitions.o
 obj-$(CONFIG_MTD_PARSER_IMAGETAG)	+= parser_imagetag.o
 obj-$(CONFIG_MTD_AFS_PARTS)		+= afs.o
 obj-$(CONFIG_MTD_PARSER_TRX)		+= parser_trx.o
drivers/mtd/parsers/bcm4908-partitions.c +2 -0
index 40eb3b3801c3..ac69a2169763 100644
@@ -62,3 +62,5 @@ int bcm4908_partitions_post_parse(struct mtd_info *mtd, struct mtd_partition *pa
 
 	return 0;
 }
+
+MODULE_LICENSE("GPL");
Signature · 6 lines
2.26.2


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/