Commit ec249557 authored by Keith Busch's avatar Keith Busch Committed by Yong Hu
Browse files

nvme-pci: fix timeout request state check

stable inclusion
from stable-v5.10.166
commit 5f10f7efe0fc97c0ee2112a1032914f6fb2f940c
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I7R4BC
CVE: NA

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=5f10f7efe0fc97c0ee2112a1032914f6fb2f940c



--------------------------------

[ Upstream commit 1c584208 ]

Polling the completion can progress the request state to IDLE, either
inline with the completion, or through softirq. Either way, the state
may not be COMPLETED, so don't check for that. We only care if the state
isn't IN_FLIGHT.

This is fixing an issue where the driver aborts an IO that we just
completed. Seeing the "aborting" message instead of "polled" is very
misleading as to where the timeout problem resides.

Fixes: bf392a5d ("nvme-pci: Remove tag from process cq")
Signed-off-by: default avatarKeith Busch <kbusch@kernel.org>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarYong Hu <yong.hu@windriver.com>
parent bda9956a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment