]> git.itanic.dy.fi Git - linux-stable/commit
nvme: ensure subsystem reset is single threaded
authorKeith Busch <kbusch@kernel.org>
Thu, 22 Sep 2022 15:13:47 +0000 (08:13 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 25 Nov 2022 16:45:54 +0000 (17:45 +0100)
commit023435a095d22bcbbaeea7e3a8c534b5c57d0d82
treeea75e714246a1d5762e968f02dbf2681fdb176fd
parentb9a5ecf24180f36bab967b4b1dbb112a0fa37255
nvme: ensure subsystem reset is single threaded

commit 1e866afd4bcdd01a70a5eddb4371158d3035ce03 upstream.

The subsystem reset writes to a register, so we have to ensure the
device state is capable of handling that otherwise the driver may access
unmapped registers. Use the state machine to ensure the subsystem reset
doesn't try to write registers on a device already undergoing this type
of reset.

Link: https://bugzilla.kernel.org/show_bug.cgi?id=214771
Signed-off-by: Keith Busch <kbusch@kernel.org>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/nvme/host/nvme.h