[QUESTION] kernel can be silence when io hang
From: Yu Kuai
Date: Tue Oct 18 2022 - 23:07:28 EST
Hi, block experts!
In order to prevent false positive hung task warnings for slow io,
following commits forbit hung task checking for io:
1)
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=4b1977698ceb
2)
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=de6a78b601c5
3)
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=e6249cdd46e4
However, if io really hangs, they also forbit the hung task warnings
that will be helpful.
I'm thinking about when hang task should be detected:
1) If io is still in block layer,there are many places that io can be
stalled: blk throttle, get tag, rq_qos_throttle, plug, elevator, hctx. I
think hang task should be detected at least for the case that there is
no io in driver.
2) If io is issued to driver
a. For the driver that timeout handling is implemented, there is no
need to detect hung task.
b. For the driver that timeout handling is not implemented
(virtio,virtio_scsi),there is a real timeout handling in physical
device. So hung task should be detected before the io is issued to lower
device.
Does anyone thinks these thoughts meaningful? Comments and suggestions
are welcomed.
Thanks,
Kuai