Re: [PATCH 2/2] block: fix locking for struct block_device size updates

2020-08-23 Thread Christoph Hellwig
On Fri, Aug 21, 2020 at 06:02:32PM +0800, 田 wrote: > thanks Hellwig for your kindly reply and your fix and add report by me :) I found an issue with the patch, and will send a new version in a bit. If this works for your reproducer, can you add a Tested-by: tag?

Re: [PATCH 2/2] block: fix locking for struct block_device size updates

2020-08-21 Thread Hannes Reinecke
On 8/21/20 10:56 AM, Christoph Hellwig wrote: > Two different callers use two different mutexes for updating the > block device size, which obviously doesn't help to actually protect > against concurrent updates from the different callers. In addition > one of the locks, bd_mutex is rather prone

[PATCH 2/2] block: fix locking for struct block_device size updates

2020-08-21 Thread Christoph Hellwig
Two different callers use two different mutexes for updating the block device size, which obviously doesn't help to actually protect against concurrent updates from the different callers. In addition one of the locks, bd_mutex is rather prone to deadlocks with other parts of the block stack that