Re: [PATCH] block: flush writeback dwork before detaching a bdev inode from it

2016-06-21 Thread Dmitry Vyukov
On Mon, Jun 20, 2016 at 7:40 PM, Tejun Heo wrote: > Hello, > > On Mon, Jun 20, 2016 at 03:38:41PM +0200, Dmitry Vyukov wrote: >> > Sorry for the late reply but now when thinking about the patch I don't >> > think it is quite right. Writeback can happen from other contexts than just >> > the worker

Re: [PATCH] block: flush writeback dwork before detaching a bdev inode from it

2016-06-20 Thread Tejun Heo
Hello, On Mon, Jun 20, 2016 at 03:38:41PM +0200, Dmitry Vyukov wrote: > > Sorry for the late reply but now when thinking about the patch I don't > > think it is quite right. Writeback can happen from other contexts than just > > the worker one (e.g. kswapd can do writeback, or in some out-of-memor

Re: [PATCH] block: flush writeback dwork before detaching a bdev inode from it

2016-06-20 Thread Dmitry Vyukov
On Mon, Jun 20, 2016 at 3:31 PM, Jan Kara wrote: > Hi, > > On Fri 17-06-16 12:04:05, Tejun Heo wrote: >> 43d1c0eb7e11 ("block: detach bdev inode from its wb in >> __blkdev_put()") detached bdev inode from its wb as the bdev inode may >> outlive the underlying bdi and thus the wb. This is accompli

Re: [PATCH] block: flush writeback dwork before detaching a bdev inode from it

2016-06-20 Thread Jan Kara
Hi, On Fri 17-06-16 12:04:05, Tejun Heo wrote: > 43d1c0eb7e11 ("block: detach bdev inode from its wb in > __blkdev_put()") detached bdev inode from its wb as the bdev inode may > outlive the underlying bdi and thus the wb. This is accomplished by > invoking inode_detach_wb() from __blkdev_put();