linux-block.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] zram: fix two races
@ 2021-10-15 12:16 Ming Lei
  2021-10-15 12:16 ` [PATCH 1/3] zram: replace fsync_bdev with sync_blockdev Ming Lei
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Ming Lei @ 2021-10-15 12:16 UTC (permalink / raw)
  To: Jens Axboe
  Cc: linux-block, Luis Chamberlain, Minchan Kim, Greg Kroah-Hartman,
	Ming Lei

Hello,

Fixes the following two issues reported by Luis Chamberlain by simpler
approach, meantime it is sort of simplification of handling resetting/removing
device vs. open().

- zram leak during unloading module, which is one race between resetting
and removing device

- zram resource leak in case that disksize_store is done after resetting
and before deleting gendisk in zram_remove()


Ming Lei (3):
  zram: replace fsync_bdev with sync_blockdev
  zram: simplify handling reset_store/remove vs. open
  zram: avoid race between zram_remove and disksize_store

 drivers/block/zram/zram_drv.c | 62 ++++++++++++++++-------------------
 drivers/block/zram/zram_drv.h |  4 ---
 2 files changed, 28 insertions(+), 38 deletions(-)

-- 
2.31.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-10-15 17:33 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-10-15 12:16 [PATCH 0/3] zram: fix two races Ming Lei
2021-10-15 12:16 ` [PATCH 1/3] zram: replace fsync_bdev with sync_blockdev Ming Lei
2021-10-15 12:16 ` [PATCH 2/3] zram: simplify handling reset_store/remove vs. open Ming Lei
2021-10-15 12:16 ` [PATCH 3/3] zram: avoid race between zram_remove and disksize_store Ming Lei
2021-10-15 17:32 ` [PATCH 0/3] zram: fix two races Luis Chamberlain

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).