writeback: don't warn on an unregistered BDI in __mark_inode_dirty
PATCH 1/1 writeback: don't warn on an unregistered BDI in __mark_inode_dirty
BDIs get unregistered during device removal, and this WARN can be trivially triggered by hot-removing a NVMe device while running fsx It is otherwise harmless as we still hold a BDI reference, and the writeback has been shut down already.
---
I have a vague memory someone else sent this patch alredy, but couldn't find it in my mailing list folder. But given that my current NVMe tests trigger it easily I'd rather get it fixed ASAP.
fs/fs-writeback.c | 4 ---- 1 file changed, 4 deletions(-)
fs/fs-writeback.c +0 -4
@@ -2321,10 +2321,6 @@ void __mark_inode_dirty(struct inode *inode, int flags) wb =locked_inode_to_wb_and_lock_list (inode); -WARN ((wb->bdi->capabilities &BDI_CAP_WRITEBACK ) && - !test_bit (WB_registered, &wb->state), -"bdi-%s not registered\n" ,bdi_dev_name (wb->bdi)); - inode->dirtied_when = jiffies;if (dirtytime) inode->dirtied_time_when = jiffies;
Signature · 1 line
2.28.0
Quoted 11 lines · Christoph Hellwig
BDIs get unregistered during device removal, and this WARN can be trivially triggered by hot-removing a NVMe device while running fsx It is otherwise harmless as we still hold a BDI reference, and the writeback has been shut down already.
Signed-off-by Christoph Hellwig <[email protected]>---
I have a vague memory someone else sent this patch alredy, but couldn't find it in my mailing list folder. But given that my current NVMe tests trigger it easily I'd rather get it fixed ASAP.
Did this patch get lost? I don't see it upstream or in Jens' tree. FWIW I agree the warning may result in false positive so I'm OK with removing it. So feel free to add:
Honza
Quoted 22 lines
fs/fs-writeback.c | 4 ---- 1 file changed, 4 deletions(-)fs/fs-writeback.c +0
-4@@ -2321,10 +2321,6 @@ void __mark_inode_dirty(struct inode *inode, int flags) wb =locked_inode_to_wb_and_lock_list (inode); -WARN ((wb->bdi->capabilities &BDI_CAP_WRITEBACK ) && - !test_bit (WB_registered, &wb->state), -"bdi-%s not registered\n" ,bdi_dev_name (wb->bdi)); - inode->dirtied_when = jiffies;if (dirtytime) inode->dirtied_time_when = jiffies;Signature · 1 line
2.28.0
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
Quoted 9 lines · Jan Kara
Quoted 3 lines
I have a vague memory someone else sent this patch alredy, but couldn't find it in my mailing list folder. But given that my current NVMe tests trigger it easily I'd rather get it fixed ASAP.
Did this patch get lost? I don't see it upstream or in Jens' tree. FWIW I agree the warning may result in false positive so I'm OK with removing it. So feel free to add:
Reviewed-by Jan Kara <[email protected]>
Yes, it looks like this patch got lost somewhere again.
Jan Kara
reviewerQuoted 5 lines · Christoph Hellwig
Quoted 4 lines · Jan Kara
Quoted 3 lines
I have a vague memory someone else sent this patch alredy, but couldn't find it in my mailing list folder. But given that my current NVMe tests trigger it easily I'd rather get it fixed ASAP.
Quoted 7 lines
Quoted 5 lines
Did this patch get lost? I don't see it upstream or in Jens' tree. FWIW I agree the warning may result in false positive so I'm OK with removing it. So feel free to add:
Reviewed-by Jan Kara <[email protected]>Yes, it looks like this patch got lost somewhere again.
Since Jens didn't reply, I've just picked up the patch to my tree and will push it to Linus tomorrow.
Honza
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
Quoted 10 lines · Jan Kara
Quoted 9 lines · Christoph Hellwig
Quoted 8 lines · Jan Kara
Quoted 3 lines
I have a vague memory someone else sent this patch alredy, but couldn't find it in my mailing list folder. But given that my current NVMe tests trigger it easily I'd rather get it fixed ASAP.
Did this patch get lost? I don't see it upstream or in Jens' tree. FWIW I agree the warning may result in false positive so I'm OK with removing it. So feel free to add:
Quoted 6 lines
Quoted 3 lines
Quoted 1 line
Reviewed-by Jan Kara <[email protected]>Yes, it looks like this patch got lost somewhere again.
Since Jens didn't reply, I've just picked up the patch to my tree and will push it to Linus tomorrow.
Sorry about that... That sounds fine to me, thanks Jan.
Signature · 1 line
Jens Axboe