All of lore.kernel.org
 help / color / mirror / Atom feed
* fix block device size update serialization
@ 2020-08-21  8:55 ` Christoph Hellwig
  0 siblings, 0 replies; 13+ messages in thread
From: Christoph Hellwig @ 2020-08-21  8:55 UTC (permalink / raw)
  To: Jens Axboe
  Cc: Justin Sanders, Josef Bacik, Xianting Tian, linux-block,
	dm-devel, Stefan Haberland, Jan Hoeppner, linux-kernel, nbd,
	linux-nvme, linux-s390

Hi Jens,

this series fixes how we update i_size for the block device inodes (and
thus the block device).  Different helpers use two different locks
(bd_mutex and i_rwsem) to protect the update, and it appears device
mapper uses yet another internal lock.  A lot of the drivers do the
update handcrafted in often crufty ways.  And in addition to that mess
it turns out that the "main" lock, bd_mutex is pretty dead lock prone
vs other spots in the block layer that acquire it during revalidation
operations, as reported by Xianting.

Fix all that by adding a dedicated spinlock just for the size updates.

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

end of thread, other threads:[~2020-08-23  9:09 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-21  8:55 fix block device size update serialization Christoph Hellwig
2020-08-21  8:55 ` Christoph Hellwig
2020-08-21  8:55 ` [PATCH 1/2] block: replace bd_set_size with bd_set_nr_sectors Christoph Hellwig
2020-08-21  8:55   ` Christoph Hellwig
2020-08-21  9:24   ` Hannes Reinecke
2020-08-21  9:24     ` Hannes Reinecke
2020-08-21  8:56 ` [PATCH 2/2] block: fix locking for struct block_device size updates Christoph Hellwig
2020-08-21  8:56   ` Christoph Hellwig
2020-08-21  9:26   ` Hannes Reinecke
2020-08-21  9:26     ` Hannes Reinecke
2020-08-21 10:02     ` 
2020-08-23  9:09       ` Christoph Hellwig
2020-08-23  9:09         ` Christoph Hellwig

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.