mtd_blkdevs: simplify blktrans_dev_get
authorChristoph Hellwig <hch@lst.de>
Mon, 23 Aug 2021 07:33:56 +0000 (09:33 +0200)
committerMiquel Raynal <miquel.raynal@bootlin.com>
Mon, 23 Aug 2021 08:01:09 +0000 (10:01 +0200)
commit89843828399ec825f8ec3e614634a428a951a2b3
tree8da3a7a6f6304f8b0679bdba57572e71e48fe914
parenta0faf5fdfb9967b33eda5eafcb55470180216af3
mtd_blkdevs: simplify blktrans_dev_get

->private_data is set before the disk is added and never cleared, so don't
bother trying to handle a NULL pointer there.

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-6-hch@lst.de
drivers/mtd/mtd_blkdevs.c