]> Git Repo - linux.git/commit
drivers/mmc/card/block.c: fix refcount leak in mmc_block_open()
authorAndrew Morton <[email protected]>
Fri, 5 Sep 2008 21:00:24 +0000 (14:00 -0700)
committerLinus Torvalds <[email protected]>
Fri, 5 Sep 2008 21:39:38 +0000 (14:39 -0700)
commit70bb08962ea9bd50797ae9f16b2493f5f7c65053
tree301692bce950f064633b80a93cbb808bead41351
parent22f30168d296dbb54a21ebad44c9d735bca6f67b
drivers/mmc/card/block.c: fix refcount leak in mmc_block_open()

mmc_block_open() increments md->usage although it returns with -EROFS when
default mounting a MMC/SD card with write protect switch on.  This
reference counting bug prevents /dev/mmcblkX from being released on card
removal, and situation worsen with reinsertion until the minor number
range runs out.

Reported-by: <[email protected]>
Acked-by: Pierre Ossman <[email protected]>
Cc: <[email protected]> [2.6.25.x, 2.6.26.x]
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
drivers/mmc/card/block.c
This page took 0.053549 seconds and 4 git commands to generate.