aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Moffett <ian@osmora.org>2024-03-30 20:11:07 -0400
committerIan Moffett <ian@osmora.org>2024-03-30 20:11:07 -0400
commit02dd6681fa3887f1f33a815d414207d13bbbd23b (patch)
tree98ba7317a7846f24fc3b7d7643cb3a0243459535
parent36da54d8f29ecd6850fafff19cb367f1d7a36cf1 (diff)
kernel: nvme: Return on controller enable failure
Signed-off-by: Ian Moffett <ian@osmora.org>
-rw-r--r--sys/dev/ic/nvme.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/dev/ic/nvme.c b/sys/dev/ic/nvme.c
index 0c3738b..b89545d 100644
--- a/sys/dev/ic/nvme.c
+++ b/sys/dev/ic/nvme.c
@@ -281,6 +281,7 @@ nvme_enable_controller(struct nvme_state *state)
if (nvme_poll_ready(bar, 1) < 0) {
KERR("Failed to enable controller\n");
+ return -1;
}
id = dynalloc_memalign(sizeof(struct nvme_id), 0x1000);