Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 3116EC41513 for ; Fri, 28 Jul 2023 02:40:27 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 17E80868B0; Fri, 28 Jul 2023 04:39:56 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="R6clcRaT"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 5318386899; Fri, 28 Jul 2023 04:39:21 +0200 (CEST) Received: from mail-io1-xd34.google.com (mail-io1-xd34.google.com [IPv6:2607:f8b0:4864:20::d34]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id ABADC86884 for ; Fri, 28 Jul 2023 04:38:59 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-io1-xd34.google.com with SMTP id ca18e2360f4ac-78625caa702so63832439f.1 for ; Thu, 27 Jul 2023 19:38:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1690511937; x=1691116737; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=MFGfJmL2CxPv80ArHg8vqXSBr3wsVrDfY32qnpexQbg=; b=R6clcRaTlPx3rkphQr9n6i5oNBkP6Qot1ERdo94AEW5sOb6M9q6RlJLGUM3SL/52B4 VY3KONP6jYwzo4jzxnXPYUNMczKoi8GwObI3LA3kXFXX2z/y54D96fSRBuKc0x2dlVDe JMMlc2fJxJeI4vToOglwmT7jZivAu98ygDTZ0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690511937; x=1691116737; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=MFGfJmL2CxPv80ArHg8vqXSBr3wsVrDfY32qnpexQbg=; b=dVUeuUYk/qnQnCk47M0jbpJgqDm+RMq9xT/umdITOHWT2riB7iP+eYEEpMdhWPu57n qvhJKJ1/JmeeZZma9TPf6cTZiSY/Sq4tFbIEBK7rRQ+eP9X05lvm65nAolJezCn+9QdT uH9IEE6vW+BlPuu7Ihkwibtr8rfrgel8vll9WFL0JFuA1dO1AFP9SssCcCCuhMcOznyG 6S0IA84OUurj+s70QQNUvrTtVAnPrSMsDg4X0sIFH9baihyw6dKtDlbVP8u/UiUOcbNO 9LrEAOzZcNU8ECkY8Gt9aK7FpZviTCeL5bbP0iwE3a5ZRpTbg2msK2OAUlQzu9MWBshV 166Q== X-Gm-Message-State: ABy/qLa/5jrj9La2uhfjTA0SCUvX/ns9EFq0AqqvEoElS04KIsSWDvij ajGNaoer9J+5ILqC08uZnmVnqldF5kcg3Z4vVYw= X-Google-Smtp-Source: APBJJlFuGRhSa6pvmhlNjfl1nOaeRqmEqKkeqp6FfMjXHvji7vjQLtoXI4i5xpdfBmT4aBjmwbkdRQ== X-Received: by 2002:a5e:8c08:0:b0:780:bfc8:ad10 with SMTP id n8-20020a5e8c08000000b00780bfc8ad10mr1466268ioj.1.1690511937538; Thu, 27 Jul 2023 19:38:57 -0700 (PDT) Received: from sjg1.roam.corp.google.com (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id g18-20020a0566380c5200b0042acf389acesm799266jal.71.2023.07.27.19.38.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 27 Jul 2023 19:38:57 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , Simon Glass Subject: [PATCH 5/8] bootstd: Add some more debugging in the bootdev uclass Date: Thu, 27 Jul 2023 20:37:48 -0600 Message-ID: <20230728023755.680278-6-sjg@chromium.org> X-Mailer: git-send-email 2.41.0.487.g6d72f3e995-goog In-Reply-To: <20230728023755.680278-1-sjg@chromium.org> References: <20230728023755.680278-1-sjg@chromium.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean Add some more output to make it easier to see what is going wrong when a bootdev hunter fails. Signed-off-by: Simon Glass --- boot/bootdev-uclass.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/boot/bootdev-uclass.c b/boot/bootdev-uclass.c index 114853ffb72a..a3661b18e28d 100644 --- a/boot/bootdev-uclass.c +++ b/boot/bootdev-uclass.c @@ -537,6 +537,8 @@ static int default_get_bootflow(struct udevice *dev, struct bootflow_iter *iter, int ret; ret = bootdev_get_sibling_blk(dev, &blk); + log_debug("sibling_blk ret=%d, blk=%s\n", ret, + ret ? "(none)" : blk->name); /* * If there is no media, indicate that no more partitions should be * checked @@ -662,7 +664,8 @@ int bootdev_next_prio(struct bootflow_iter *iter, struct udevice **devp) ret = bootdev_hunt_prio(iter->cur_prio, iter->flags & BOOTFLOWIF_SHOW); - log_debug("- hunt ret %d\n", ret); + log_debug("- bootdev_hunt_prio() ret %d\n", + ret); if (ret) return log_msg_ret("hun", ret); } @@ -698,6 +701,7 @@ int bootdev_setup_iter(struct bootflow_iter *iter, const char *label, /* hunt for any pre-scan devices */ if (iter->flags & BOOTFLOWIF_HUNT) { ret = bootdev_hunt_prio(BOOTDEVP_1_PRE_SCAN, show); + log_debug("- bootdev_hunt_prio() ret %d\n", ret); if (ret) return log_msg_ret("pre", ret); } @@ -768,6 +772,7 @@ static int bootdev_hunt_drv(struct bootdev_hunter *info, uint seq, bool show) log_debug("Hunting with: %s\n", name); if (info->hunt) { ret = info->hunt(info, show); + log_debug(" - hunt result %d\n", ret); if (ret) return ret; } @@ -833,9 +838,11 @@ int bootdev_hunt_prio(enum bootdev_prio_t prio, bool show) if (prio != info->prio) continue; ret = bootdev_hunt_drv(info, i, show); + log_debug("bootdev_hunt_drv() return %d\n", ret); if (ret && ret != -ENOENT) result = ret; } + log_debug("exit %d\n", result); return result; } -- 2.41.0.487.g6d72f3e995-goog