]> git.baikalelectronics.ru Git - uboot.git/commit
ide: Simplify success condition
authorSimon Glass <sjg@chromium.org>
Tue, 25 Apr 2023 16:54:39 +0000 (10:54 -0600)
committerTom Rini <trini@konsulko.com>
Thu, 27 Apr 2023 17:51:06 +0000 (13:51 -0400)
commitc90aaf1b0397d6b1e526e9f57bf61340c0947b9f
treea87330b224c8242e70d5ebf6a1112bc00ffaaaed
parentb1d5ff63bd30c3e2084331279c81ab54977db45f
ide: Simplify success condition

Change the if() to remove extra brackets and check for the positive case
first, i.e. when a device is found. Exit the loop in that case, with the
retry logic in the 'else' part.

Signed-off-by: Simon Glass <sjg@chromium.org>
drivers/block/ide.c