]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
nvme: Update nvme_scan_namespace to keep trying on busy
authorMoritz Fischer <moritzf@google.com>
Wed, 10 Jan 2024 05:04:48 +0000 (05:04 +0000)
committerTom Rini <trini@konsulko.com>
Fri, 19 Jan 2024 01:24:13 +0000 (20:24 -0500)
A busy controller shouldn't be game-over for all controllers,
so keep trying on hitting -EBUSY.

This change brings the actual behavior of the routine in line
with what the descriptions says.

Fixes: 982388eaa991 ("nvme: Add NVM Express driver support")
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Moritz Fischer <moritzf@google.com>
drivers/nvme/nvme.c

index ec45f831a36f840e29be0b8a5fb39ee318fc3b69..59a139baa0ba6c7323b29cc11311000d8fb4a84f 100644 (file)
@@ -695,7 +695,9 @@ int nvme_scan_namespace(void)
                if (ret) {
                        log_err("Failed to probe '%s': err=%dE\n", dev->name,
                                ret);
-                       return ret;
+                       /* Bail if we ran out of memory, else keep trying */
+                       if (ret != -EBUSY)
+                               return ret;
                }
        }