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 0B446C77B75 for ; Tue, 9 May 2023 19:06:36 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 8EF1885F50; Tue, 9 May 2023 21:06:19 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=grimler.se 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; secure) header.d=grimler.se header.i=@grimler.se header.b="RVJ/xOSa"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id C2BDB85F50; Tue, 9 May 2023 21:06:17 +0200 (CEST) Received: from out-33.mta0.migadu.com (out-33.mta0.migadu.com [91.218.175.33]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 9B03480BB0 for ; Tue, 9 May 2023 21:06:15 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=grimler.se Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=henrik@grimler.se X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=grimler.se; s=key1; t=1683659175; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ScyvNYRyo0W1QYXB25BjJY73nSMtDAb2v/ifdKFTxmY=; b=RVJ/xOSaMTnM2OQyyH2vtclABSKPowTTVR/qaz/B6nVDJtnkVCqhX3ep2MEiGjYFGqDTZD MDOH0FHHyO11UEuOIereJwgx1liuBog+Th2KUnQ9MsgU0oTHfJtitRljlmxoB+9yiaiV74 3OwfEkdRuOZvA+T0xPWqow8LIATu5IA= From: Henrik Grimler To: joost@diskos.nl, jh80.chung@gmail.com, peng.fan@nxp.com, mk7.kang@samsung.com, andy.wu@sony.com, sjg@chromium.org, m.szyprowski@samsung.com, u-boot@lists.denx.de, ~postmarketos/upstreaming@lists.sr.ht Cc: Henrik Grimler Subject: [RESEND PATCH v2 2/2] samsung: common: do not reset if cros-ec uclass is missing Date: Tue, 9 May 2023 21:05:47 +0200 Message-Id: <20230509190547.5722-3-henrik@grimler.se> In-Reply-To: <20230509190547.5722-1-henrik@grimler.se> References: <20230509190547.5722-1-henrik@grimler.se> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT 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 Otherwise non-ChromeOS samsung devices, like the odroid boards, are stuck in a bootloop if CONFIG_CROS_EC is not enabled: <...> MMC: SAMSUNG SDHCI: 2, EXYNOS DWMMC: 0 Loading Environment from MMC... *** Warning - bad CRC, using default environment cros-ec communications failure -96 Please reset with Power+Refresh Cannot init cros-ec device resetting ... Issue started after commit e44d7e73fe0d ("dm: core: Switch uclass_*_device_err to use uclass_*_device_check"). Signed-off-by: Henrik Grimler Reviewed-by: Simon Glass Reviewed-by: Minkyu Kang --- board/samsung/common/board.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/board/samsung/common/board.c b/board/samsung/common/board.c index 16ce5cb89253..663d7ca991bc 100644 --- a/board/samsung/common/board.c +++ b/board/samsung/common/board.c @@ -223,7 +223,7 @@ int board_late_init(void) char mmcbootdev_str[16]; ret = uclass_first_device_err(UCLASS_CROS_EC, &dev); - if (ret && ret != -ENODEV) { + if (ret && ret != -ENODEV && ret != -EPFNOSUPPORT) { /* Force console on */ gd->flags &= ~GD_FLG_SILENT; -- 2.30.2