diff options
author | Christoph Hellwig | 2021-08-23 09:33:55 +0200 |
---|---|---|
committer | Miquel Raynal | 2021-08-23 10:01:06 +0200 |
commit | a0faf5fdfb9967b33eda5eafcb55470180216af3 (patch) | |
tree | f58fe3e884929dee88c9924777f16c881017ae51 /drivers/mtd | |
parent | ffd18c97fcb6bf37bb749cfc53c5e698017cbc95 (diff) |
mtd/rfd_ftl: don't cast away the type when calling add_mtd_blktrans_dev
Pass the actual mtd_blktrans_dev instead of casting the containing
structure to void *.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20210823073359.705281-5-hch@lst.de
Diffstat (limited to 'drivers/mtd')
-rw-r--r-- | drivers/mtd/rfd_ftl.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mtd/rfd_ftl.c b/drivers/mtd/rfd_ftl.c index af20a0a71108..c546f8c5f24d 100644 --- a/drivers/mtd/rfd_ftl.c +++ b/drivers/mtd/rfd_ftl.c @@ -783,7 +783,7 @@ static void rfd_ftl_add_mtd(struct mtd_blktrans_ops *tr, struct mtd_info *mtd) printk(KERN_INFO PREFIX "name: '%s' type: %d flags %x\n", mtd->name, mtd->type, mtd->flags); - if (!add_mtd_blktrans_dev((void*)part)) + if (!add_mtd_blktrans_dev(&part->mbd)) return; } out: |