aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Hellwig <[email protected]>2022-11-08 11:14:09 +0100
committerChristoph Hellwig <[email protected]>2022-12-06 14:36:51 +0100
commitc76b8308e4c9148e44e0c7e086ab6d8b4bb10162 (patch)
tree5b23dcf214bb90baa720f990c64b141ac1da7f5e
parentb2969585572e5ddaa239d53ee68e2824df7a7736 (diff)
nvme-apple: fix controller shutdown in apple_nvme_disable
nvme_shutdown_ctrl already shuts the controller down, there is no need to also call nvme_disable_ctrl for the shutdown case. Signed-off-by: Christoph Hellwig <[email protected]> Reviewed-by: Keith Busch <[email protected]> Reviewed-by: Eric Curtin <[email protected]> Reviewed-by: Sagi Grimberg <[email protected]> Reviewed-by: Hector Martin <[email protected]>
-rw-r--r--drivers/nvme/host/apple.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/nvme/host/apple.c b/drivers/nvme/host/apple.c
index 94ef797e8b4a..56d9e9be945b 100644
--- a/drivers/nvme/host/apple.c
+++ b/drivers/nvme/host/apple.c
@@ -831,7 +831,8 @@ static void apple_nvme_disable(struct apple_nvme *anv, bool shutdown)
if (shutdown)
nvme_shutdown_ctrl(&anv->ctrl);
- nvme_disable_ctrl(&anv->ctrl);
+ else
+ nvme_disable_ctrl(&anv->ctrl);
}
WRITE_ONCE(anv->ioq.enabled, false);