]> www.infradead.org Git - nvme.git/commit
pds_core: Prevent health thread from running during reset/remove
authorBrett Creeley <brett.creeley@amd.com>
Mon, 29 Jan 2024 23:40:30 +0000 (15:40 -0800)
committerJakub Kicinski <kuba@kernel.org>
Thu, 1 Feb 2024 02:26:58 +0000 (18:26 -0800)
commitd9407ff11809c6812bb84fe7be9c1367d758e5c8
treeb9937696e57a13ef7d2352dc2ef649e261af6bb6
parent4d322dce82a1d44f8c83f0f54f95dd1b8dcf46c9
pds_core: Prevent health thread from running during reset/remove

The PCIe reset handlers can run at the same time as the
health thread. This can cause the health thread to
stomp on the PCIe reset. Fix this by preventing the
health thread from running while a PCIe reset is happening.

As part of this use timer_shutdown_sync() during reset and
remove to make sure the timer doesn't ever get rearmed.

Fixes: ffa55858330f ("pds_core: implement pci reset handlers")
Signed-off-by: Brett Creeley <brett.creeley@amd.com>
Reviewed-by: Shannon Nelson <shannon.nelson@amd.com>
Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
Link: https://lore.kernel.org/r/20240129234035.69802-2-brett.creeley@amd.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/amd/pds_core/main.c