Skip to content

Commit 6e95268

Browse files
kvaneeshbbrezillon
authored andcommitted
mtd: Use mtd->name when registering nvmem device
With this patch, we use the mtd->name instead of concatenating the name with '0'. Fixes: c4dfa25 ("mtd: add support for reading MTD devices via the nvmem API") Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.ibm.com> Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
1 parent d139371 commit 6e95268

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/mtd/mtdcore.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -507,6 +507,7 @@ static int mtd_nvmem_add(struct mtd_info *mtd)
507507
{
508508
struct nvmem_config config = {};
509509

510+
config.id = -1;
510511
config.dev = &mtd->dev;
511512
config.name = mtd->name;
512513
config.owner = THIS_MODULE;

0 commit comments

Comments
 (0)