diff options
| author | Yu Kuai <[email protected]> | 2025-07-15 01:28:12 +0000 |
|---|---|---|
| committer | Christoph Hellwig <[email protected]> | 2025-07-15 07:49:13 +0000 |
| commit | 71257925e83eae1cb6913d65ca71927d2220e6d1 (patch) | |
| tree | 463074f3e031183162c4c36f67483fabdee51be9 /drivers/fpga/of-fpga-region.c | |
| parent | nvme: revert the cross-controller atomic write size validation (diff) | |
| download | kernel-71257925e83eae1cb6913d65ca71927d2220e6d1.tar.gz kernel-71257925e83eae1cb6913d65ca71927d2220e6d1.zip | |
nvme: fix misaccounting of nvme-mpath inflight I/O
Procedures for nvme-mpath IO accounting:
1) initialize nvme_request and clear flags;
2) set NVME_MPATH_IO_STATS and increase inflight counter when IO
started;
3) check NVME_MPATH_IO_STATS and decrease inflight counter when IO is
done;
However, for the case nvme_fail_nonready_command(), both step 1) and 2)
are skipped, and if old nvme_request set NVME_MPATH_IO_STATS and then
request is reused, step 3) will still be executed, causing inflight I/O
counter to be negative.
Fix the problem by clearing nvme_request in nvme_fail_nonready_command().
Fixes: ea5e5f42cd2c ("nvme-fabrics: avoid double completions in nvmf_fail_nonready_command")
Reported-by: Yi Zhang <[email protected]>
Closes: https://lore.kernel.org/all/CAHj4cs_+dauobyYyP805t33WMJVzOWj=7+51p4_j9rA63D9sog@mail.gmail.com/
Signed-off-by: Yu Kuai <[email protected]>
Signed-off-by: Christoph Hellwig <[email protected]>
Diffstat (limited to 'drivers/fpga/of-fpga-region.c')
0 files changed, 0 insertions, 0 deletions
