From patchwork Wed Aug 28 12:10:24 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977811 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=QTFz+oj0; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3Ch5Xctz1yfy for ; Wed, 28 Aug 2024 22:10:56 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 31A3488A76; Wed, 28 Aug 2024 14:10:47 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="QTFz+oj0"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id A051388829; Wed, 28 Aug 2024 14:10:44 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wr1-x431.google.com (mail-wr1-x431.google.com [IPv6:2a00:1450:4864:20::431]) (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 BA25588847 for ; Wed, 28 Aug 2024 14:10:42 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wr1-x431.google.com with SMTP id ffacd0b85a97d-371a13c7c80so354622f8f.0 for ; Wed, 28 Aug 2024 05:10:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847042; x=1725451842; darn=lists.denx.de; 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=p6H6IWdSN+rg+rHMHDRzq1nSIiOPpJHDMNLUt1yZPnk=; b=QTFz+oj0uB/nz9NgA3qF5EbQ7RqAaDr1uhJRuzzMhlc2/J+5L/m3i0Z4eFXdgPo089 ssnu+qZgNY05ZPQJrk8J+WyZGy/Bn5R05W7L69guDgjliq9LJf0t4oZP+7FKaC3HUbyq ovdQYWhVJHE43iD5EtVq9eh0HBoCQozwxRq6eXPNM9yXMdXTmo6Katru/v/SFnwL5hbT kJxlhDF7ef5S+SAZd5xxmg6yXjOCYtBurtfKbALroHcFzP4IxjSNlIu39jKFqUh7djLM 9emfsyAOwQ+ZRso4UwbD5HxdWZ3VZR3edGeIQ0hCm1GNnRVbwqVJg5O7TJeMrFD4evEP p4Rg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847042; x=1725451842; 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=p6H6IWdSN+rg+rHMHDRzq1nSIiOPpJHDMNLUt1yZPnk=; b=SeCRC8yfm4ISZi4FdWAtd6ui7rcyGR6V6aOyNMM9STA2fbHqM6e3dhd/b/h17S8ID/ Xb2YCItJF9IE1lATQR4gP4sRRZ0S51uo+zjmcZILidY+X34MI0JbHzmp9TR96J5LxOTb TA6badKRFfVNc3//UVI5CyubX4/ObGJ9kj2B+iLd+Q6vTz/XHnlSCUEWRyVK5HMecwBs u8wbTBo2P3RftjzuXTVEWWxqylWiHGxr2G/QhOWhXkicGrGCPihhq74z1bGiLbpew3PF FqJtvDYyU3HLZKMKquORvvjXY3NSZh1EE1Z7dlhp6QF5oaicOp/ble9QN3dZinSMoxkt nIkA== X-Gm-Message-State: AOJu0YzN5d1XD3QBIgNMy6o4HKooLJhf3Mfc50T1VPUAC4HSaRyVTZtd dvzzTCVzvXulj0pJskxyNBWznGAUO7w3ZP4YhUheAb91FXxdnnAjlOsiw9IL6vLn8FgjNX/offY FSmBTtg== X-Google-Smtp-Source: AGHT+IGY/zKMx/wEBju39EI8qZtWare2EY0qgeIJkmVmBs3pdOSRlLaeDh6EPjp+bmJAomED7vCrXg== X-Received: by 2002:a05:6000:1142:b0:366:dee6:a9ea with SMTP id ffacd0b85a97d-37495f74970mr1115246f8f.26.1724847041858; Wed, 28 Aug 2024 05:10:41 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:41 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Tom Rini , Simon Glass , Heinrich Schuchardt , Rasmus Villemoes , Sumit Garg , Andrew Davis , Bryan Brattlof , Jesse Taube , "Leon M. Busch-George" Subject: [PATCH 01/13] Makefile: detect HOST_ARCH properly when CROSS_COMPILE is multi-word Date: Wed, 28 Aug 2024 14:10:24 +0200 Message-Id: <7de6a75453d11fa56ae81f3ad3d0f16f0d12546e.1724846454.git.jerome.forissier@linaro.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 When CROSS_COMPILE contains multiple words, HOST_ARCH is not properly detected and the sandbox build fail. It typically happens when using ccache. For example: $ make sandbox_defconfig $ make CROSS_COMPILE="ccache x86_64-linux-gnu-" \ CC="ccache x86_64-linux-gnu-gcc" [...] In file included from boot/bootmeth_efi.c:16: include/efi_default_filename.h:33:2: error: #error Unsupported UEFI architecture 33 | #error Unsupported UEFI architecture | ^~~~~ A similar error occurs when the build is done via buildman and ~/.buildman contains: [toolchain-wrapper] wrapper = ccache Fix the issue by considering only the last word in $(CROSS_COMPILE). Signed-off-by: Jerome Forissier Reviewed-by: Ilias Apalodimas --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index f90e48f58a..dc7bdd7942 100644 --- a/Makefile +++ b/Makefile @@ -21,7 +21,7 @@ include include/host_arch.h ifeq ("", "$(CROSS_COMPILE)") MK_ARCH="${shell uname -m}" else - MK_ARCH="${shell echo $(CROSS_COMPILE) | sed -n 's/^[[:space:]]*\([^\/]*\/\)*\([^-]*\)-[^[:space:]]*/\2/p'}" + MK_ARCH="${shell echo ${lastword $(CROSS_COMPILE)} | sed -n 's/^[[:space:]]*\([^\/]*\/\)*\([^-]*\)-[^[:space:]]*/\2/p'}" endif unexport HOST_ARCH ifeq ("x86_64", $(MK_ARCH)) From patchwork Wed Aug 28 12:10:25 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977812 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=U4z4WKDJ; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3Cv0BXYz1yfy for ; Wed, 28 Aug 2024 22:11:07 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 89EE488AAA; Wed, 28 Aug 2024 14:10:47 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="U4z4WKDJ"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 489AB88868; Wed, 28 Aug 2024 14:10:46 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.2 Received: from mail-wr1-x435.google.com (mail-wr1-x435.google.com [IPv6:2a00:1450:4864:20::435]) (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 D0ACF88875 for ; Wed, 28 Aug 2024 14:10:43 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wr1-x435.google.com with SMTP id ffacd0b85a97d-3718706cf8aso3840835f8f.3 for ; Wed, 28 Aug 2024 05:10:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847043; x=1725451843; darn=lists.denx.de; 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=VJKqBRZXsx6/cMes6o8RBGAAWb2rNuGoBSL8WlcYTyc=; b=U4z4WKDJILF60dvdMdHRrxRqgQm7BdEwsqODcW5VB4Xmqg9v8wtyBzUEyt09UYUeHs myBFBclqTsUzU1nQhX99f2OC74q3mxK5e2MU6qNJilyQwrtyr7U8sNXJrw0VysxsKRD7 zcClHNpwJmqG18t45ckOM+OPd0Et+mtygpn+7xideqdJzKMu9K1HOhtT5d57+B802/gT Ujn+HoXt7GiCVJvmwfW9KNQc5GkLJMJHOlp/DA0eWX4UyK6zGxXSHSyLkCF91tJNbMvp FGP50gNsid05frPwO7WXJUErEAIeXsxxqMCef3Dh9auMHL0raMhTkvsxOI6qhRUvbHsM iA3w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847043; x=1725451843; 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=VJKqBRZXsx6/cMes6o8RBGAAWb2rNuGoBSL8WlcYTyc=; b=ZICiny5fvZ0yHVMLh+WEakJtFHEhC9giqgjb9muroB1o9kFXGIDTTDkm9SyqAiF9RW IfaeBr233ATYVDOCdUkiSBzFqv2I8lq3TPj69XWO86hSpWBF7i1CnGowX04PZ9VH/0Cg XPMFHDAL0Zur56VMWkLqDFYpTKFnc35bnPwCMdOmK/t7VHIlHpN6BKJn3YAulLRUCFNi 6mXBtPU+NtMowk/J5LUW9HdX0DGzF+KYVpjXiMj5JKKBrNKI9ORzMB+MmoaNXRi++biU OCpVBPdqLxBvsZB/vNf+QnxUwqJ4CfPJ5PnMq+g7iCvDkDTBGsHmcmAT2/EP/6mCOcVF TEQg== X-Gm-Message-State: AOJu0Yy57eR/qiY8ZUvIt8Oxc5cHoL0OitS0XXGxDYsxAxVCExRA1TKs PMjYdJsRf1YPVCchC/y1SxTWIBO3RyuW1vkbinu0a3tAdT7E+ht+zGhi5IPNU9dvdImOOqVAv2p OqHmpOQ== X-Google-Smtp-Source: AGHT+IE8Qarf46jQYOXTzQbuHwJ3hvwFtp0Br1jU7zUQMSzc2HXviGI0C0Eo1qjNEJbFpugckhw5og== X-Received: by 2002:a05:6000:2c2:b0:36b:357a:bfee with SMTP id ffacd0b85a97d-37311841b2dmr13258946f8f.1.1724847043051; Wed, 28 Aug 2024 05:10:43 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:42 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Tom Rini , Angelo Dureghello , TsiChung Liew , Stefan Roese , Marek Vasut , Jason Liu , Peng Fan , William Zhang Subject: [PATCH 02/13] flash: prefix error codes with FL_ Date: Wed, 28 Aug 2024 14:10:25 +0200 Message-Id: <7251eb28f680327a709aa00f0b3e713f129e827f.1724846454.git.jerome.forissier@linaro.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 Prefix the flash status codes (ERR_*) with FL_ in order to avoid clashes with third-party libraries. Case in point: including the lwIP library header file which defines err_enum_t as an enum with values being ERR_*. Signed-off-by: Jerome Forissier Reviewed-by: Tom Rini Reviewed-by: Ilias Apalodimas --- board/cobra5272/flash.c | 26 +++++++++--------- board/freescale/m5253demo/flash.c | 6 ++--- common/flash.c | 44 +++++++++++++++---------------- drivers/mtd/cfi_flash.c | 36 ++++++++++++------------- include/flash.h | 20 +++++++------- 5 files changed, 66 insertions(+), 66 deletions(-) diff --git a/board/cobra5272/flash.c b/board/cobra5272/flash.c index 616842e62f..d324aa6ac1 100644 --- a/board/cobra5272/flash.c +++ b/board/cobra5272/flash.c @@ -135,22 +135,22 @@ int flash_erase(flash_info_t *info, int s_first, int s_last) { ulong result; int iflag, cflag, prot, sect; - int rc = ERR_OK; + int rc = FL_ERR_OK; int chip1; ulong start; /* first look for protection bits */ if (info->flash_id == FLASH_UNKNOWN) - return ERR_UNKNOWN_FLASH_TYPE; + return FL_ERR_UNKNOWN_FLASH_TYPE; if ((s_first < 0) || (s_first > s_last)) { - return ERR_INVAL; + return FL_ERR_INVAL; } if ((info->flash_id & FLASH_VENDMASK) != (AMD_MANUFACT & FLASH_VENDMASK)) { - return ERR_UNKNOWN_FLASH_VENDOR; + return FL_ERR_UNKNOWN_FLASH_VENDOR; } prot = 0; @@ -160,7 +160,7 @@ int flash_erase(flash_info_t *info, int s_first, int s_last) } } if (prot) - return ERR_PROTECTED; + return FL_ERR_PROTECTED; /* * Disable interrupts which might cause a timeout @@ -217,11 +217,11 @@ int flash_erase(flash_info_t *info, int s_first, int s_last) MEM_FLASH_ADDR1 = CMD_READ_ARRAY; if (chip1 == ERR) { - rc = ERR_PROG_ERROR; + rc = FL_ERR_PROG_ERROR; goto outahere; } if (chip1 == TMO) { - rc = ERR_TIMEOUT; + rc = FL_ERR_TIMEOUT; goto outahere; } @@ -252,7 +252,7 @@ static int write_word(flash_info_t *info, ulong dest, ulong data) { volatile u16 *addr = (volatile u16 *) dest; ulong result; - int rc = ERR_OK; + int rc = FL_ERR_OK; int cflag, iflag; int chip1; ulong start; @@ -262,7 +262,7 @@ static int write_word(flash_info_t *info, ulong dest, ulong data) */ result = *addr; if ((result & data) != data) - return ERR_NOT_ERASED; + return FL_ERR_NOT_ERASED; /* * Disable interrupts which might cause a timeout @@ -302,7 +302,7 @@ static int write_word(flash_info_t *info, ulong dest, ulong data) *addr = CMD_READ_ARRAY; if (chip1 == ERR || *addr != data) - rc = ERR_PROG_ERROR; + rc = FL_ERR_PROG_ERROR; if (iflag) enable_interrupts(); @@ -320,13 +320,13 @@ int write_buff(flash_info_t *info, uchar *src, ulong addr, ulong cnt) if (addr & 1) { printf ("unaligned destination not supported\n"); - return ERR_ALIGN; + return FL_ERR_ALIGN; } #if 0 if (cnt & 1) { printf ("odd transfer sizes not supported\n"); - return ERR_ALIGN; + return FL_ERR_ALIGN; } #endif @@ -364,5 +364,5 @@ int write_buff(flash_info_t *info, uchar *src, ulong addr, ulong cnt) cnt -= 1; } - return ERR_OK; + return FL_ERR_OK; } diff --git a/board/freescale/m5253demo/flash.c b/board/freescale/m5253demo/flash.c index 334518a4bc..ab5d2ebff6 100644 --- a/board/freescale/m5253demo/flash.c +++ b/board/freescale/m5253demo/flash.c @@ -72,7 +72,7 @@ int flash_get_offsets(ulong base, flash_info_t * info) } } - return ERR_OK; + return FL_ERR_OK; } void flash_print_info(flash_info_t * info) @@ -369,9 +369,9 @@ int write_buff(flash_info_t * info, uchar * src, ulong addr, ulong cnt) } if (cnt == 0) - return ERR_OK; + return FL_ERR_OK; - return ERR_OK; + return FL_ERR_OK; } /*----------------------------------------------------------------------- diff --git a/common/flash.c b/common/flash.c index 24ddc8bee7..a64e51a9b5 100644 --- a/common/flash.c +++ b/common/flash.c @@ -110,13 +110,13 @@ addr2info(ulong addr) * Make sure all target addresses are within Flash bounds, * and no protected sectors are hit. * Returns: - * ERR_OK 0 - OK - * ERR_TIMEOUT 1 - write timeout - * ERR_NOT_ERASED 2 - Flash not erased - * ERR_PROTECTED 4 - target range includes protected sectors - * ERR_INVAL 8 - target address not in Flash memory - * ERR_ALIGN 16 - target address not aligned on boundary - * (only some targets require alignment) + * FL_ERR_OK 0 - OK + * FL_ERR_TIMEOUT 1 - write timeout + * FL_ERR_NOT_ERASED 2 - Flash not erased + * FL_ERR_PROTECTED 4 - target range includes protected sectors + * FL_ERR_INVAL 8 - target address not in Flash memory + * FL_ERR_ALIGN 16 - target address not aligned on boundary + * (only some targets require alignment) */ int flash_write(char *src, ulong addr, ulong cnt) @@ -131,11 +131,11 @@ flash_write(char *src, ulong addr, ulong cnt) __maybe_unused ulong cnt_orig = cnt; if (cnt == 0) { - return (ERR_OK); + return (FL_ERR_OK); } if (!info_first || !info_last) { - return (ERR_INVAL); + return (FL_ERR_INVAL); } for (info = info_first; info <= info_last; ++info) { @@ -146,7 +146,7 @@ flash_write(char *src, ulong addr, ulong cnt) if ((end >= info->start[i]) && (addr < e_addr) && (info->protect[i] != 0) ) { - return (ERR_PROTECTED); + return (FL_ERR_PROTECTED); } } } @@ -169,11 +169,11 @@ flash_write(char *src, ulong addr, ulong cnt) #if defined(CONFIG_FLASH_VERIFY) if (memcmp(src_orig, addr_orig, cnt_orig)) { printf("\nVerify failed!\n"); - return ERR_PROG_ERROR; + return FL_ERR_PROG_ERROR; } #endif /* CONFIG_SYS_FLASH_VERIFY_AFTER_WRITE */ - return (ERR_OK); + return (FL_ERR_OK); } /*----------------------------------------------------------------------- @@ -182,33 +182,33 @@ flash_write(char *src, ulong addr, ulong cnt) void flash_perror(int err) { switch (err) { - case ERR_OK: + case FL_ERR_OK: break; - case ERR_TIMEOUT: + case FL_ERR_TIMEOUT: puts ("Timeout writing to Flash\n"); break; - case ERR_NOT_ERASED: + case FL_ERR_NOT_ERASED: puts ("Flash not Erased\n"); break; - case ERR_PROTECTED: + case FL_ERR_PROTECTED: puts ("Can't write to protected Flash sectors\n"); break; - case ERR_INVAL: + case FL_ERR_INVAL: puts ("Outside available Flash\n"); break; - case ERR_ALIGN: + case FL_ERR_ALIGN: puts ("Start and/or end address not on sector boundary\n"); break; - case ERR_UNKNOWN_FLASH_VENDOR: + case FL_ERR_UNKNOWN_FLASH_VENDOR: puts ("Unknown Vendor of Flash\n"); break; - case ERR_UNKNOWN_FLASH_TYPE: + case FL_ERR_UNKNOWN_FLASH_TYPE: puts ("Unknown Type of Flash\n"); break; - case ERR_PROG_ERROR: + case FL_ERR_PROG_ERROR: puts ("General Flash Programming Error\n"); break; - case ERR_ABORTED: + case FL_ERR_ABORTED: puts("Flash Programming Aborted\n"); break; default: diff --git a/drivers/mtd/cfi_flash.c b/drivers/mtd/cfi_flash.c index a7826e81c1..e50502824a 100644 --- a/drivers/mtd/cfi_flash.c +++ b/drivers/mtd/cfi_flash.c @@ -593,11 +593,11 @@ static int flash_status_check(flash_info_t *info, flash_sect_t sector, flash_read_long(info, sector, 0)); flash_write_cmd(info, sector, 0, info->cmd_reset); udelay(1); - return ERR_TIMEOUT; + return FL_ERR_TIMEOUT; } udelay(1); /* also triggers watchdog */ } - return ERR_OK; + return FL_ERR_OK; } /*----------------------------------------------------------------------- @@ -616,9 +616,9 @@ static int flash_full_status_check(flash_info_t *info, flash_sect_t sector, case CFI_CMDSET_INTEL_PROG_REGIONS: case CFI_CMDSET_INTEL_EXTENDED: case CFI_CMDSET_INTEL_STANDARD: - if (retcode == ERR_OK && + if (retcode == FL_ERR_OK && !flash_isset(info, sector, 0, FLASH_STATUS_DONE)) { - retcode = ERR_INVAL; + retcode = FL_ERR_INVAL; printf("Flash %s error at address %lx\n", prompt, info->start[sector]); if (flash_isset(info, sector, 0, FLASH_STATUS_ECLBS | @@ -627,14 +627,14 @@ static int flash_full_status_check(flash_info_t *info, flash_sect_t sector, } else if (flash_isset(info, sector, 0, FLASH_STATUS_ECLBS)) { puts("Block Erase Error.\n"); - retcode = ERR_NOT_ERASED; + retcode = FL_ERR_NOT_ERASED; } else if (flash_isset(info, sector, 0, FLASH_STATUS_PSLBS)) { puts("Locking Error\n"); } if (flash_isset(info, sector, 0, FLASH_STATUS_DPS)) { puts("Block locked.\n"); - retcode = ERR_PROTECTED; + retcode = FL_ERR_PROTECTED; } if (flash_isset(info, sector, 0, FLASH_STATUS_VPENS)) puts("Vpp Low Error.\n"); @@ -702,12 +702,12 @@ static int flash_status_poll(flash_info_t *info, void *src, void *dst, if (get_timer(start) > tout) { printf("Flash %s timeout at address %lx data %lx\n", prompt, (ulong)dst, (ulong)flash_read8(dst)); - return ERR_TIMEOUT; + return FL_ERR_TIMEOUT; } udelay(1); /* also triggers watchdog */ } #endif /* CONFIG_SYS_CFI_FLASH_STATUS_POLL */ - return ERR_OK; + return FL_ERR_OK; } /*----------------------------------------------------------------------- @@ -810,7 +810,7 @@ static int flash_write_cfiword(flash_info_t *info, ulong dest, cfiword_t cword) break; } if (!flag) - return ERR_NOT_ERASED; + return FL_ERR_NOT_ERASED; /* Disable interrupts which might cause a timeout here */ flag = disable_interrupts(); @@ -899,7 +899,7 @@ static int flash_write_cfibuffer(flash_info_t *info, ulong dest, uchar *cp, shift = 3; break; default: - retcode = ERR_INVAL; + retcode = FL_ERR_INVAL; goto out_unmap; } @@ -930,7 +930,7 @@ static int flash_write_cfibuffer(flash_info_t *info, ulong dest, uchar *cp, } } if (!flag) { - retcode = ERR_NOT_ERASED; + retcode = FL_ERR_NOT_ERASED; goto out_unmap; } @@ -950,7 +950,7 @@ static int flash_write_cfibuffer(flash_info_t *info, ulong dest, uchar *cp, retcode = flash_status_check(info, sector, info->buffer_write_tout, "write to buffer"); - if (retcode == ERR_OK) { + if (retcode == FL_ERR_OK) { /* reduce the number of loops by the width of * the port */ @@ -975,7 +975,7 @@ static int flash_write_cfibuffer(flash_info_t *info, ulong dest, uchar *cp, src += 8, dst += 8; break; default: - retcode = ERR_INVAL; + retcode = FL_ERR_INVAL; goto out_unmap; } } @@ -1025,7 +1025,7 @@ static int flash_write_cfibuffer(flash_info_t *info, ulong dest, uchar *cp, } break; default: - retcode = ERR_INVAL; + retcode = FL_ERR_INVAL; goto out_unmap; } @@ -1043,7 +1043,7 @@ static int flash_write_cfibuffer(flash_info_t *info, ulong dest, uchar *cp, default: debug("Unknown Command Set\n"); - retcode = ERR_INVAL; + retcode = FL_ERR_INVAL; break; } @@ -1389,7 +1389,7 @@ int write_buff(flash_info_t *info, uchar *src, ulong addr, ulong cnt) if (i > cnt) i = cnt; rc = flash_write_cfibuffer(info, wp, src, i); - if (rc != ERR_OK) + if (rc != FL_ERR_OK) return rc; i -= i & (info->portwidth - 1); wp += i; @@ -1398,7 +1398,7 @@ int write_buff(flash_info_t *info, uchar *src, ulong addr, ulong cnt) FLASH_SHOW_PROGRESS(scale, dots, digit, i); /* Only check every once in a while */ if ((cnt & 0xFFFF) < buffered_size && ctrlc()) - return ERR_ABORTED; + return FL_ERR_ABORTED; } #else while (cnt >= info->portwidth) { @@ -1413,7 +1413,7 @@ int write_buff(flash_info_t *info, uchar *src, ulong addr, ulong cnt) FLASH_SHOW_PROGRESS(scale, dots, digit, info->portwidth); /* Only check every once in a while */ if ((cnt & 0xFFFF) < info->portwidth && ctrlc()) - return ERR_ABORTED; + return FL_ERR_ABORTED; } #endif /* CONFIG_SYS_FLASH_USE_BUFFER_WRITE */ diff --git a/include/flash.h b/include/flash.h index 60babe8a80..32bc65e7b6 100644 --- a/include/flash.h +++ b/include/flash.h @@ -127,16 +127,16 @@ void flash_perror(int err); /*----------------------------------------------------------------------- * return codes from flash_write(): */ -#define ERR_OK 0 -#define ERR_TIMEOUT 1 -#define ERR_NOT_ERASED 2 -#define ERR_PROTECTED 4 -#define ERR_INVAL 8 -#define ERR_ALIGN 16 -#define ERR_UNKNOWN_FLASH_VENDOR 32 -#define ERR_UNKNOWN_FLASH_TYPE 64 -#define ERR_PROG_ERROR 128 -#define ERR_ABORTED 256 +#define FL_ERR_OK 0 +#define FL_ERR_TIMEOUT 1 +#define FL_ERR_NOT_ERASED 2 +#define FL_ERR_PROTECTED 4 +#define FL_ERR_INVAL 8 +#define FL_ERR_ALIGN 16 +#define FL_ERR_UNKNOWN_FLASH_VENDOR 32 +#define FL_ERR_UNKNOWN_FLASH_TYPE 64 +#define FL_ERR_PROG_ERROR 128 +#define FL_ERR_ABORTED 256 /*----------------------------------------------------------------------- * Protection Flags for flash_protect(): From patchwork Wed Aug 28 12:10:26 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977813 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=smx6SlBJ; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3D50bMBz1yfy for ; Wed, 28 Aug 2024 22:11:17 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id E772588AFB; Wed, 28 Aug 2024 14:10:50 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="smx6SlBJ"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 54349888A3; Wed, 28 Aug 2024 14:10:48 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.2 Received: from mail-wr1-x430.google.com (mail-wr1-x430.google.com [IPv6:2a00:1450:4864:20::430]) (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 2173288A3E for ; Wed, 28 Aug 2024 14:10:46 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wr1-x430.google.com with SMTP id ffacd0b85a97d-37189d8e637so3860185f8f.3 for ; Wed, 28 Aug 2024 05:10:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847045; x=1725451845; darn=lists.denx.de; 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=sDBcEVogIBVBSmglcRAffFeYWv3UMkJZDLIS/N29gaM=; b=smx6SlBJ9B0wvnk7+1xj/ndvBwh2UU7fIqEwpi+6kdkIUjovVwK/mSh3zaOGAzMMa3 0k8lUePbGYI6oA/Hvdesapw1Hoqj2qjnw2nWbFZbYoWN3DqcvxIrM6T+RGIwYhiX263z ayayJ8TQ/PDrVIgZYieTp9UNKDR1p24djkL1rpGRPZ/7npiwQkoX58Z3R3x+waO2cerV iXGIpWWTDUon+zq3pCI85/RzhUiXu14PAXmCfzak4GV4OGrSYKB+uUvXZCry22tfE1Gq Bp9A+xZbJojtbtHtYXZXOVvJZIBuhdr5gUvxSSQMjGPXFbBgtWZKfYropGCx5lTkPZsi bkCw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847045; x=1725451845; 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=sDBcEVogIBVBSmglcRAffFeYWv3UMkJZDLIS/N29gaM=; b=t9xxx0eN84qnWveTxi80uOIF6HraVw+vs70IiCcz90TcFylbSGw2Yix+Zqf9+Phy6C /BtC+Etps0u+s0G03E+QJLugvalJKslZgY9FLhNG4C+m5s925WuXfSA09LgQgSQHSAPY YT7E3fYA11VncRjJGJ9gqdciztFpJd9/0OocWb75rosgDC4j6j+PIl+wgVzmC8+oeI4z 72g//wh067vVSRadAjPLTnM/y6rCoJ2d016XjhX/LVaFzO3VNKpa1GMetciPenJnhLl5 mixvQKnAIJ3w8snv4oRN9d1oBrvqYz5LOAIr6Hbnp/KbjX2khNXGrjEp97n4wOst5CVP yLwA== X-Gm-Message-State: AOJu0Yw9zhhTA1Omf3kCfvRy/zMRq4YX5oy9R2BQTt3GS6l8lLYffoOI 62zbKZ/QpgaSdPCme2NmHVvV2vXI4K3TB5ybomGH0B2pBNiAXVOAz4BvAu5iLhG3n1oA66OPu32 u5B4+gg== X-Google-Smtp-Source: AGHT+IFZUYDsYik9bkzS74f75GQbdlmupznQuRoQtfK+wsxrSzsnlwqIbtMOft0B8zoO7JpSzCeQig== X-Received: by 2002:a05:6000:8b:b0:362:8ec2:53d6 with SMTP id ffacd0b85a97d-373118ef032mr11249606f8f.61.1724847045328; Wed, 28 Aug 2024 05:10:45 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:45 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Eugen Hristev , Tom Rini , Nicolas Ferre , Jakub Klama , Artur Rojek , Stefan Roese , Heiko Schocher , Marcin Jabrzyk Subject: [PATCH 03/13] at91: rename mem_init() to at91_mem_init() Date: Wed, 28 Aug 2024 14:10:26 +0200 Message-Id: <7f010d834c665c15888b7738a0ad16334fa03443.1724846454.git.jerome.forissier@linaro.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 THe AT91-based platforms have a mem_init() function declared in arch/arm/mach-at91/include/mach/at91_common.h and implemented in various places. In preparation of the introduction of the lwIP networking library which also has a global mem_init() function, rename the AT91 one to at91_mem_init(). Signed-off-by: Jerome Forissier Reviewed-by: Ilias Apalodimas Reviewed-by: Heiko Schocher --- arch/arm/mach-at91/include/mach/at91_common.h | 2 +- arch/arm/mach-at91/spl_at91.c | 2 +- arch/arm/mach-at91/spl_atmel.c | 2 +- board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c | 2 +- board/atmel/at91sam9n12ek/at91sam9n12ek.c | 2 +- board/atmel/at91sam9x5ek/at91sam9x5ek.c | 2 +- board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c | 2 +- board/atmel/sama5d27_wlsom1_ek/sama5d27_wlsom1_ek.c | 2 +- board/atmel/sama5d2_icp/sama5d2_icp.c | 2 +- board/atmel/sama5d2_xplained/sama5d2_xplained.c | 2 +- board/atmel/sama5d3_xplained/sama5d3_xplained.c | 2 +- board/atmel/sama5d3xek/sama5d3xek.c | 2 +- board/atmel/sama5d4_xplained/sama5d4_xplained.c | 2 +- board/atmel/sama5d4ek/sama5d4ek.c | 2 +- board/conclusive/kstr-sama5d27/kstr-sama5d27.c | 2 +- board/gardena/smart-gateway-at91sam/spl.c | 2 +- board/siemens/corvus/board.c | 2 +- board/siemens/smartweb/smartweb.c | 2 +- board/siemens/taurus/taurus.c | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/arch/arm/mach-at91/include/mach/at91_common.h b/arch/arm/mach-at91/include/mach/at91_common.h index 683e539b1b..8fec346c1e 100644 --- a/arch/arm/mach-at91/include/mach/at91_common.h +++ b/arch/arm/mach-at91/include/mach/at91_common.h @@ -28,7 +28,7 @@ void at91_pllb_init(u32 pllar); void at91_mck_init(u32 mckr); void at91_mck_init_down(u32 mckr); void at91_pmc_init(void); -void mem_init(void); +void at91_mem_init(void); void at91_phy_reset(void); void at91_sdram_hw_init(void); void at91_mck_init(u32 mckr); diff --git a/arch/arm/mach-at91/spl_at91.c b/arch/arm/mach-at91/spl_at91.c index cde1700a28..0d1233cd10 100644 --- a/arch/arm/mach-at91/spl_at91.c +++ b/arch/arm/mach-at91/spl_at91.c @@ -142,7 +142,7 @@ void board_init_f(ulong dummy) preloader_console_init(); #endif - mem_init(); + at91_mem_init(); at91_spl_board_init(); } diff --git a/arch/arm/mach-at91/spl_atmel.c b/arch/arm/mach-at91/spl_atmel.c index 62a7df8a19..7bfbadf048 100644 --- a/arch/arm/mach-at91/spl_atmel.c +++ b/arch/arm/mach-at91/spl_atmel.c @@ -134,7 +134,7 @@ void board_init_f(ulong dummy) board_early_init_f(); - mem_init(); + at91_mem_init(); ret = spl_init(); if (ret) { diff --git a/board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c b/board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c index 3bd94d0889..af486e977e 100644 --- a/board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c +++ b/board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c @@ -125,7 +125,7 @@ static void ddr2_conf(struct atmel_mpddrc_config *ddr2) 2 << ATMEL_MPDDRC_TPR2_TXARD_OFFSET); } -void mem_init(void) +void at91_mem_init(void) { struct atmel_mpddrc_config ddr2; diff --git a/board/atmel/at91sam9n12ek/at91sam9n12ek.c b/board/atmel/at91sam9n12ek/at91sam9n12ek.c index afc0c0520e..6f9abcbb12 100644 --- a/board/atmel/at91sam9n12ek/at91sam9n12ek.c +++ b/board/atmel/at91sam9n12ek/at91sam9n12ek.c @@ -167,7 +167,7 @@ static void ddr2_conf(struct atmel_mpddrc_config *ddr2) 2 << ATMEL_MPDDRC_TPR2_TXARD_OFFSET); } -void mem_init(void) +void at91_mem_init(void) { struct at91_pmc *pmc = (struct at91_pmc *)ATMEL_BASE_PMC; struct at91_matrix *matrix = (struct at91_matrix *)ATMEL_BASE_MATRIX; diff --git a/board/atmel/at91sam9x5ek/at91sam9x5ek.c b/board/atmel/at91sam9x5ek/at91sam9x5ek.c index e5688c6cf1..f52b9a9773 100644 --- a/board/atmel/at91sam9x5ek/at91sam9x5ek.c +++ b/board/atmel/at91sam9x5ek/at91sam9x5ek.c @@ -181,7 +181,7 @@ static void ddr2_conf(struct atmel_mpddrc_config *ddr2) 2 << ATMEL_MPDDRC_TPR2_TXARD_OFFSET); } -void mem_init(void) +void at91_mem_init(void) { struct at91_pmc *pmc = (struct at91_pmc *)ATMEL_BASE_PMC; struct at91_matrix *matrix = (struct at91_matrix *)ATMEL_BASE_MATRIX; diff --git a/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c b/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c index 36995a927c..cb3cd7ac9a 100644 --- a/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c +++ b/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c @@ -146,7 +146,7 @@ static void ddrc_conf(struct atmel_mpddrc_config *ddrc) (8 << ATMEL_MPDDRC_TPR2_TFAW_OFFSET)); } -void mem_init(void) +void at91_mem_init(void) { struct at91_pmc *pmc = (struct at91_pmc *)ATMEL_BASE_PMC; struct atmel_mpddr *mpddrc = (struct atmel_mpddr *)ATMEL_BASE_MPDDRC; diff --git a/board/atmel/sama5d27_wlsom1_ek/sama5d27_wlsom1_ek.c b/board/atmel/sama5d27_wlsom1_ek/sama5d27_wlsom1_ek.c index c775d593e5..15cbd0daa6 100644 --- a/board/atmel/sama5d27_wlsom1_ek/sama5d27_wlsom1_ek.c +++ b/board/atmel/sama5d27_wlsom1_ek/sama5d27_wlsom1_ek.c @@ -208,7 +208,7 @@ static void ddrc_conf(struct atmel_mpddrc_config *ddrc) ddrc->cal_mr4 |= ATMEL_MPDDRC_CAL_MR4_MR4R(0xFFFE); } -void mem_init(void) +void at91_mem_init(void) { struct at91_pmc *pmc = (struct at91_pmc *)ATMEL_BASE_PMC; struct atmel_mpddr *mpddrc = (struct atmel_mpddr *)ATMEL_BASE_MPDDRC; diff --git a/board/atmel/sama5d2_icp/sama5d2_icp.c b/board/atmel/sama5d2_icp/sama5d2_icp.c index 986da01639..6f0d578abf 100644 --- a/board/atmel/sama5d2_icp/sama5d2_icp.c +++ b/board/atmel/sama5d2_icp/sama5d2_icp.c @@ -180,7 +180,7 @@ static void ddrc_conf(struct atmel_mpddrc_config *ddrc) (7 << ATMEL_MPDDRC_TPR2_TFAW_OFFSET)); } -void mem_init(void) +void at91_mem_init(void) { struct at91_pmc *pmc = (struct at91_pmc *)ATMEL_BASE_PMC; struct atmel_mpddr *mpddrc = (struct atmel_mpddr *)ATMEL_BASE_MPDDRC; diff --git a/board/atmel/sama5d2_xplained/sama5d2_xplained.c b/board/atmel/sama5d2_xplained/sama5d2_xplained.c index c8a8eb4982..d104736fa7 100644 --- a/board/atmel/sama5d2_xplained/sama5d2_xplained.c +++ b/board/atmel/sama5d2_xplained/sama5d2_xplained.c @@ -146,7 +146,7 @@ static void ddrc_conf(struct atmel_mpddrc_config *ddrc) 7 << ATMEL_MPDDRC_TPR2_TFAW_OFFSET); } -void mem_init(void) +void at91_mem_init(void) { struct at91_pmc *pmc = (struct at91_pmc *)ATMEL_BASE_PMC; struct atmel_mpddr *mpddrc = (struct atmel_mpddr *)ATMEL_BASE_MPDDRC; diff --git a/board/atmel/sama5d3_xplained/sama5d3_xplained.c b/board/atmel/sama5d3_xplained/sama5d3_xplained.c index 54cc3c4d90..f98322fb54 100644 --- a/board/atmel/sama5d3_xplained/sama5d3_xplained.c +++ b/board/atmel/sama5d3_xplained/sama5d3_xplained.c @@ -175,7 +175,7 @@ static void ddr2_conf(struct atmel_mpddrc_config *ddr2) 8 << ATMEL_MPDDRC_TPR2_TXARD_OFFSET); } -void mem_init(void) +void at91_mem_init(void) { struct atmel_mpddrc_config ddr2; diff --git a/board/atmel/sama5d3xek/sama5d3xek.c b/board/atmel/sama5d3xek/sama5d3xek.c index f2e1242fcb..28079a8151 100644 --- a/board/atmel/sama5d3xek/sama5d3xek.c +++ b/board/atmel/sama5d3xek/sama5d3xek.c @@ -241,7 +241,7 @@ static void ddr2_conf(struct atmel_mpddrc_config *ddr2) 8 << ATMEL_MPDDRC_TPR2_TXARD_OFFSET); } -void mem_init(void) +void at91_mem_init(void) { struct atmel_mpddrc_config ddr2; diff --git a/board/atmel/sama5d4_xplained/sama5d4_xplained.c b/board/atmel/sama5d4_xplained/sama5d4_xplained.c index 09ca16ca88..f9112fc532 100644 --- a/board/atmel/sama5d4_xplained/sama5d4_xplained.c +++ b/board/atmel/sama5d4_xplained/sama5d4_xplained.c @@ -184,7 +184,7 @@ static void ddr2_conf(struct atmel_mpddrc_config *ddr2) 8 << ATMEL_MPDDRC_TPR2_TXARD_OFFSET); } -void mem_init(void) +void at91_mem_init(void) { struct atmel_mpddrc_config ddr2; diff --git a/board/atmel/sama5d4ek/sama5d4ek.c b/board/atmel/sama5d4ek/sama5d4ek.c index 1f8b85f061..0bdc6adbdc 100644 --- a/board/atmel/sama5d4ek/sama5d4ek.c +++ b/board/atmel/sama5d4ek/sama5d4ek.c @@ -169,7 +169,7 @@ static void ddr2_conf(struct atmel_mpddrc_config *ddr2) 8 << ATMEL_MPDDRC_TPR2_TXARD_OFFSET); } -void mem_init(void) +void at91_mem_init(void) { struct atmel_mpddrc_config ddr2; const struct atmel_mpddr *mpddr = (struct atmel_mpddr *)ATMEL_BASE_MPDDRC; diff --git a/board/conclusive/kstr-sama5d27/kstr-sama5d27.c b/board/conclusive/kstr-sama5d27/kstr-sama5d27.c index 64282ae9dc..37750137ad 100644 --- a/board/conclusive/kstr-sama5d27/kstr-sama5d27.c +++ b/board/conclusive/kstr-sama5d27/kstr-sama5d27.c @@ -182,7 +182,7 @@ static void ddrc_conf(struct atmel_mpddrc_config *ddrc) (8 << ATMEL_MPDDRC_TPR2_TFAW_OFFSET)); } -void mem_init(void) +void at91_mem_init(void) { struct at91_pmc *pmc = (struct at91_pmc *)ATMEL_BASE_PMC; struct atmel_mpddr *mpddrc = (struct atmel_mpddr *)ATMEL_BASE_MPDDRC; diff --git a/board/gardena/smart-gateway-at91sam/spl.c b/board/gardena/smart-gateway-at91sam/spl.c index fb3ec48f9c..db9ba88188 100644 --- a/board/gardena/smart-gateway-at91sam/spl.c +++ b/board/gardena/smart-gateway-at91sam/spl.c @@ -110,7 +110,7 @@ static void ddr2_conf(struct atmel_mpddrc_config *ddr2) 2 << ATMEL_MPDDRC_TPR2_TXARD_OFFSET); } -void mem_init(void) +void at91_mem_init(void) { struct at91_matrix *matrix = (struct at91_matrix *)ATMEL_BASE_MATRIX; struct at91_pmc *pmc = (struct at91_pmc *)ATMEL_BASE_PMC; diff --git a/board/siemens/corvus/board.c b/board/siemens/corvus/board.c index 7d73d1f2b3..cd27fc1cc3 100644 --- a/board/siemens/corvus/board.c +++ b/board/siemens/corvus/board.c @@ -187,7 +187,7 @@ static void ddr2_conf(struct atmel_mpddrc_config *ddr2) 2 << ATMEL_MPDDRC_TPR2_TXARD_OFFSET); } -void mem_init(void) +void at91_mem_init(void) { struct atmel_mpddrc_config ddr2; diff --git a/board/siemens/smartweb/smartweb.c b/board/siemens/smartweb/smartweb.c index 946fbc3f22..e9e4bc348c 100644 --- a/board/siemens/smartweb/smartweb.c +++ b/board/siemens/smartweb/smartweb.c @@ -238,7 +238,7 @@ void at91_spl_board_init(void) | AT91_SDRAMC_TRP_VAL(2) | AT91_SDRAMC_TRCD_VAL(2) \ | AT91_SDRAMC_TRAS_VAL(5) | AT91_SDRAMC_TXSR_VAL(8)) -void mem_init(void) +void at91_mem_init(void) { struct at91_matrix *ma = (struct at91_matrix *)ATMEL_BASE_MATRIX; struct at91_port *port = (struct at91_port *)ATMEL_BASE_PIOC; diff --git a/board/siemens/taurus/taurus.c b/board/siemens/taurus/taurus.c index bda12a9770..3764ab48ab 100644 --- a/board/siemens/taurus/taurus.c +++ b/board/siemens/taurus/taurus.c @@ -177,7 +177,7 @@ void sdramc_configure(unsigned int mask) sdramc_initialize(ATMEL_BASE_CS1, &setting); } -void mem_init(void) +void at91_mem_init(void) { unsigned int ram_size = 0; From patchwork Wed Aug 28 12:10:27 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977814 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=kreFt7yX; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3DH2fTRz1yfy for ; Wed, 28 Aug 2024 22:11:27 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 48B7D88A3E; Wed, 28 Aug 2024 14:10:52 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="kreFt7yX"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id BF37E889B3; Wed, 28 Aug 2024 14:10:48 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wr1-x434.google.com (mail-wr1-x434.google.com [IPv6:2a00:1450:4864:20::434]) (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 E44D888868 for ; Wed, 28 Aug 2024 14:10:46 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wr1-x434.google.com with SMTP id ffacd0b85a97d-371893dd249so3548911f8f.2 for ; Wed, 28 Aug 2024 05:10:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847046; x=1725451846; darn=lists.denx.de; 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=u+YU0Cxzg10TEhNipO2Qc2Z0ZtHICueW3QwSRonIsTk=; b=kreFt7yXqdRCFywa2QJGrk0/3JWIufPdSLWwlxyslE1qb2+SmPkfqm7NyDWGv88XQR jCdmsa+OZjBjNAU6+wQHDIO4cXuYIVReli3V8owcS7dNECtMlM2b0oTHc37/ieWQjOhO j76rP+7dE+bmSwqCYlyzyhNkJDmVPl7hIzHCNEq0S5RZ9k0PPBAATEGT3Ew6iV/IA6Ps ZIxLf5up0qec+E8OurjwH3vUZmNDnYwUy4LipdwOrrkL1snxwVCyVgJ+p0O7k2bHQaNZ frbQiVWiHgc8pFrEDdTxwc8mSg652oONiwyA5hgeIu4c55H8D7w8JRoVduyQQRLgG42R 5dww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847046; x=1725451846; 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=u+YU0Cxzg10TEhNipO2Qc2Z0ZtHICueW3QwSRonIsTk=; b=nhrXM6SVhUncNZGm3dC1AYU5Ta6em//eIHPJIQ8uFQj1EXGzU7BkuWyAserObuHU27 gMfkA2yS7g+wUGeg0Xe/H7msmnrCnfwYROuSCFniNh+ATF/SrHJGpqs5ij+nh+OwyIU9 OvXU2HyoWWlpbNGOf8HDjY2jmrkr26S39nVhtDvnG5/+TS+aBz5k7/tiwX3H3Hm3n8YH uVhDUorPVdIB2iTkaN9XTM7AB7SVbNiBgiPwDFpItnCtUBYvvsjizdl90E8MouxN/rqi aIgcN02Wz4NjaQIlPqi8NWZpOsv5SIlqZSl0haEu3MNe47E5tDI2/rZ0XYIIcQBukFRL 188g== X-Gm-Message-State: AOJu0Yz14zbC1QdDUmHyyqWcTh4dWVPXrWMy0qHm7PKfhSqM7MN4uCoF RctewfPGoNeOewx5M9Oq/O4GNrq5X9Ib0/w6vAbs4MK1ihgKtUHAMckGzsKw0PQ+JAAEcW4zTZP 50wEiuw== X-Google-Smtp-Source: AGHT+IGSIazDHuCdNCDM/DYWVAdujiDyQldwViu+x2XkpmBnciiqQQezZOmDeGoAcrXj11Gd3qQgrg== X-Received: by 2002:a05:6000:104d:b0:371:8763:763c with SMTP id ffacd0b85a97d-373118642e9mr11062564f8f.33.1724847046096; Wed, 28 Aug 2024 05:10:46 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:45 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Tom Rini Subject: [PATCH 04/13] arm: omap2: add missing #include Date: Wed, 28 Aug 2024 14:10:27 +0200 Message-Id: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 emac.c implements cpu_eth_init() so it needs to pull the corresponding header file. Signed-off-by: Jerome Forissier Reviewed-by: Tom Rini Reviewed-by: Ilias Apalodimas --- arch/arm/mach-omap2/omap3/emac.c | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/mach-omap2/omap3/emac.c b/arch/arm/mach-omap2/omap3/emac.c index 7348e92cab..1e30a06361 100644 --- a/arch/arm/mach-omap2/omap3/emac.c +++ b/arch/arm/mach-omap2/omap3/emac.c @@ -9,6 +9,7 @@ #include #include #include +#include /* * Initializes on-chip ethernet controllers. From patchwork Wed Aug 28 12:10:28 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977815 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=VMmwtSNp; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3DS5S50z1yfy for ; Wed, 28 Aug 2024 22:11:36 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id A0C0C88B29; Wed, 28 Aug 2024 14:10:52 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="VMmwtSNp"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id DC6BE88AFB; Wed, 28 Aug 2024 14:10:49 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wm1-x334.google.com (mail-wm1-x334.google.com [IPv6:2a00:1450:4864:20::334]) (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 F3F5B88ABA for ; Wed, 28 Aug 2024 14:10:47 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wm1-x334.google.com with SMTP id 5b1f17b1804b1-429ec9f2155so58292885e9.2 for ; Wed, 28 Aug 2024 05:10:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847047; x=1725451847; darn=lists.denx.de; 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=wvelrrkYuX7sWh+UqcXejJvxNMf6tKNnDRAQQwpPslM=; b=VMmwtSNpbUd2rVZnnK1kHCQQpdQ7FFUSMKmlx8JflGQK4SpK1ZBL1zQHgqSRuOlS53 nHVC36xOWvh7VeErNi5TF14tPx1Q84MYxLDdfyJz+8mh+E/MA2KxP/ltO/AHTOk+iomY gTU0c/nWH60HwXjNiIImXqf5FH0wNsqvPTgsFxAA2p7QZI0RsK08UKHjXENMz+K+V/lT FY3flgZH4YeM82VLscodrWSTZRiEoTLpStUQ3N9wmVTz45sLv7eXXGCQvVRybpBrEbBz Vu8R7MqJ66DmUFr3OqkFcMCbPDaGuVPnjk0iEi/ZnyJsHXX1MKv5Q2edOnDVPMZL2Yye dMJQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847047; x=1725451847; 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=wvelrrkYuX7sWh+UqcXejJvxNMf6tKNnDRAQQwpPslM=; b=gdtpj/Qex1xvVxKKuI2Ul1rVpJtStoXu09n6D2A3XfRJRgYZr2PP4L4SNXKCuAVcyU PaegkTSf2tWQ4fFYsl1f3jEo6q4nCHz3xfxwZbSV80IA+LFP4Q1FRBDK9wzfyldeLY1+ XyGDxveh5c33CcHVwohGVrtBbwmxRiKUg1Yu8EN8vfY/AIA9+BOHWteExvTC7GFi+bTx SoFOCmjcKCU8983g1oht36UZNv6d2YwDXLoV4micreYWz007SWe0m63YyFILE7I0oel7 eQMvHl4d5u7i8fF+1LBTaKkJqYGlXRvYI5dVKFo4ZM7RC34amTmUPHPNBWVxgtD47bIP AN4A== X-Gm-Message-State: AOJu0YzceseNCbAbZkhJJnjJGKgsz9xkjAKtaeRiV7gwml92depQFSE8 jkBcmVz+UhsmsVZspbY7KWHNjqZdIfD7DA+aeFjkgLm/mh5rZ4od30HvKc/Edtqi/zfZNx/t76k b5wsAtA== X-Google-Smtp-Source: AGHT+IFMR6l+TAwuPCTaAnb+pkQbAXi+LdL7HPAKE6H2vI+ynGCHaVB8Yx5lVflYsfE0hT3wZ4Gl3Q== X-Received: by 2002:a05:600c:354b:b0:427:d72a:6c26 with SMTP id 5b1f17b1804b1-42acc8d5290mr110587355e9.6.1724847046971; Wed, 28 Aug 2024 05:10:46 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:46 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Joe Hershberger , Ramon Fried , Tom Rini Subject: [PATCH 05/13] net: fm: call dtsec_init_phy() only when it is defined Date: Wed, 28 Aug 2024 14:10:28 +0200 Message-Id: <679e20bfd9ac3de6560e202f82452563b01fca7a.1724846454.git.jerome.forissier@linaro.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 dtsec_init_phy() is defined only with MII so add the proper conditional in the caller code. Signed-off-by: Jerome Forissier --- drivers/net/fm/eth.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/fm/eth.c b/drivers/net/fm/eth.c index 19f3f0fef0..e4ec769693 100644 --- a/drivers/net/fm/eth.c +++ b/drivers/net/fm/eth.c @@ -701,8 +701,10 @@ static int init_phy(struct fm_eth *fm_eth) supported |= SUPPORTED_2500baseX_Full; #endif +#if defined(CONFIG_MII) || defined(CONFIG_CMD_MII) && !defined(BITBANGMII) if (fm_eth->type == FM_ETH_1G_E) dtsec_init_phy(fm_eth); +#endif #ifdef CONFIG_PHYLIB #ifdef CONFIG_DM_MDIO From patchwork Wed Aug 28 12:10:29 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977816 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=AhS0+4xx; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3Df2wKQz1yfy for ; Wed, 28 Aug 2024 22:11:46 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 08C6988ADB; Wed, 28 Aug 2024 14:10:53 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="AhS0+4xx"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id B19F688AFB; Wed, 28 Aug 2024 14:10:50 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.2 Received: from mail-wr1-x42d.google.com (mail-wr1-x42d.google.com [IPv6:2a00:1450:4864:20::42d]) (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 D5F9488868 for ; Wed, 28 Aug 2024 14:10:48 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wr1-x42d.google.com with SMTP id ffacd0b85a97d-3719753d365so3729798f8f.2 for ; Wed, 28 Aug 2024 05:10:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847048; x=1725451848; darn=lists.denx.de; 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=/GuQLY2YZQmzPr+GaKiym8bRViMHsvubT9envaMps2A=; b=AhS0+4xxSD0FxYCsXmnhhUyg9zWL3M1ViG6/iZgKNcMoZpPxh0m1xNeQsh/izWJteG C9q9ea1eGedyKTyqqDnDemQE2ApNRD632pZ/YtL2rKJSZ4ZrH8vHHWLz0lA8WMmizaTf fHQfvNjbxhjBSkpDu7VS5KvFw2SXxsEogMUh0TYe1BumMKDk0a3ONqALB6/P/ZpBq5ip SzUSW86zinH0JE+ZVUgL1xWKdkYy6hRtKoKGGirN900EtGlOMAYraT8xbSr27W5N7UhJ j3eH4gBB274PcJQzG5BMUtNNoTC2ZfODa9UFB0ZzKOtlX5X9jQpGcWgbwzFsH3fJpuVY SQcQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847048; x=1725451848; 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=/GuQLY2YZQmzPr+GaKiym8bRViMHsvubT9envaMps2A=; b=E3O/4cZmTKIt01Gcp8P6q5+FT1s5UgwEIsRq4tYF2KS4EXAkglbj8oQwaEwScqBmnZ XV8j2ofOBqvmU8w7+Xr0BCKDsH9tLHQ057N03m6SJ63dVMPWxn+1XC99VMosyFhLm0om mVCfrf4/SygnNyNqR1boWaUwBajE33tAFOtXHtVtiBP8WGXDu3z9Ls/b8tsfnCslmWSs OOjhRCbvn+CtAot/772+hK2pgCHfZx4m8ugJJ1FGVUE0sKxCesgr0PJ6UoJIg2WcE00R e5fxHEV4TyP36y3EUbTxMnw+vyWSMlFu4VRLXdmbc7gHnKbwcDxMet6q5AGDMXUO7+05 YK3w== X-Gm-Message-State: AOJu0YwWjIgOVQsDvbjmZ3ZElsspXU31wfA9IzEgjaIRHmyyqsLWyecl IrWPYwH4iZ3gj1CrN47ynGmB/rRkPJ6t8muJvBHhKlBluvbrtlc/EYRQa4GMBSfkY5p5hG1/J9K as2LnwA== X-Google-Smtp-Source: AGHT+IEwrbbX6cUmsSc3AR8G9T3DhYHPZLGr/SSn7/RBnl4g+z5NjQSY37FzXaVBb15hWJXVKMdchg== X-Received: by 2002:adf:f547:0:b0:367:9621:6fa with SMTP id ffacd0b85a97d-373118b9b3amr11180450f8f.37.1724847048037; Wed, 28 Aug 2024 05:10:48 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:47 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Joe Hershberger , Ramon Fried , Tom Rini , Masahisa Kojima , Yasuharu Shibata , Richard Weinberger , Marek Vasut Subject: [PATCH 06/13] net: wget: removed unused function wget_success() Date: Wed, 28 Aug 2024 14:10:29 +0200 Message-Id: <5f77c205f646201b5d68f65eb8872475d18d2836.1724846454.git.jerome.forissier@linaro.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 wget_success() is used nowhere so remove it. Signed-off-by: Jerome Forissier Reviewed-by: Ilias Apalodimas --- net/wget.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/net/wget.c b/net/wget.c index f1dd7abeff..0e4dc5159d 100644 --- a/net/wget.c +++ b/net/wget.c @@ -199,13 +199,6 @@ void wget_fail(char *error_message, unsigned int tcp_seq_num, wget_send(action, tcp_seq_num, tcp_ack_num, 0); } -void wget_success(u8 action, unsigned int tcp_seq_num, - unsigned int tcp_ack_num, int len, int packets) -{ - printf("Packets received %d, Transfer Successful\n", packets); - wget_send(action, tcp_seq_num, tcp_ack_num, len); -} - /* * Interfaces of U-BOOT */ From patchwork Wed Aug 28 12:10:30 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977817 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=xF+ijc7T; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3Dt250Yz1yfy for ; Wed, 28 Aug 2024 22:11:58 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 62C9688874; Wed, 28 Aug 2024 14:10:55 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="xF+ijc7T"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id B614788B1B; Wed, 28 Aug 2024 14:10:51 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wm1-x32e.google.com (mail-wm1-x32e.google.com [IPv6:2a00:1450:4864:20::32e]) (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 956F488AC2 for ; Wed, 28 Aug 2024 14:10:49 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wm1-x32e.google.com with SMTP id 5b1f17b1804b1-42ba9b47f4eso1869925e9.1 for ; Wed, 28 Aug 2024 05:10:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847049; x=1725451849; darn=lists.denx.de; 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=r30FER1u6ArC2MC1YI7nnZsRsMetzEXKpzkVRsNl8s0=; b=xF+ijc7TRfphJOHtxiG5d4Bc5Uwrdc+OoNzd8NQTWYVCvW7nNbMABTDcgcZvuk8Ou4 wMBRUsh6gwKiChg3hyxrrxbx3Ui+XoWJ7zw9wLSpbIye+iN/gKP6lcjn70T5AhKLJ4eQ HIJQxy+BCQyXWfLFTMXzUIrYKzluaijezzb+TD3Sm0Nu0daJYPXqC0zN732GRLi5f76K e/Jh372LlTL1/rmdf8voytLrBOkCvjXQTxFRaU3udfJFU9AL/WsfNIvSPV8MnI+JnX7W Atb97SmtKW56Sj3N9OevRGoSil2Zdnse9n5NSjz8nP1yE6UHroPCA2qHxwSmXIkLre07 9YuQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847049; x=1725451849; 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=r30FER1u6ArC2MC1YI7nnZsRsMetzEXKpzkVRsNl8s0=; b=dPgSGCsq2Np2qFtJciv/9YSMJ0wh7bYwfQ1xs8Luccj2JyQ7nCAbD/zSl6KePAs+7k nlK8NiRN2+KjQLMw2h3eSN+7DtZlOAGWAkF6E35wA1iPgcj85BFLP15tRPry+gxoaWCb HWSwazdUgs9n3it2V1Z8c+O/8/3HBVborMzyoz3idOMbu92ecZcu0tc0yUL3GYfH7wtE DC8OGvB5t5XZ/RV5P8GWNjML1aDSxTRMWjC42ZESTq4P6Rot8FzfuvvqkDv6hS4WtSYh BmIRPPmUNkpkfWUMzMbBwWGCUKvLCZqqJrM+vGK6vOdhWatfVmxI9RBiYvpDl69qO8Tm NBTg== X-Gm-Message-State: AOJu0Yz9M7SDDMi28ur4217M9WSpu0D0oRJ1+4YYcpvZMSEb9Keprpyt 8xRrrX5qKhXEvF3drY36dEbRsvfDfngdSvjxEczldEZPt+7DeVRDWah256G4EMjUgxsbuLoKsxq 42R7UDA== X-Google-Smtp-Source: AGHT+IGgmROtls3CVYxfAnXNYT5kfhzdlNI0D5twiJO1n8M4k2sXPYm3yF0ip5n/so8osi964n3zNg== X-Received: by 2002:a05:600c:35c3:b0:426:5b17:8458 with SMTP id 5b1f17b1804b1-42ba56b9395mr11423195e9.12.1724847048915; Wed, 28 Aug 2024 05:10:48 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:48 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Joe Hershberger , Ramon Fried , Tom Rini , Nicolas Frattaroli , Marek Vasut Subject: [PATCH 07/13] net: phy: ncsi: depend on NET Date: Wed, 28 Aug 2024 14:10:30 +0200 Message-Id: <898bcb397c26f6eb7b0750b91c6c6ad2783d5195.1724846454.git.jerome.forissier@linaro.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 PHY_NCSI enables drivers/net/phy/ncsi.c which calls net_loop() and net_set_timeout_handler(). That's the legacy NET stack (as opposed to NET_LWIP). Therefore add the dependency to Kconfig. Signed-off-by: Jerome Forissier Reviewed-by: Ilias Apalodimas --- drivers/net/phy/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig index 73064b2af6..a9efc50981 100644 --- a/drivers/net/phy/Kconfig +++ b/drivers/net/phy/Kconfig @@ -368,6 +368,7 @@ config PHY_FIXED config PHY_NCSI bool "NC-SI based PHY" + depends on NET endif #PHYLIB From patchwork Wed Aug 28 12:10:31 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977818 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=HzYaQyxw; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3F62qTHz1yfy for ; Wed, 28 Aug 2024 22:12:10 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id BDBBA88AA7; Wed, 28 Aug 2024 14:10:55 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="HzYaQyxw"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 8D5D288B40; Wed, 28 Aug 2024 14:10:53 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wm1-x32b.google.com (mail-wm1-x32b.google.com [IPv6:2a00:1450:4864:20::32b]) (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 91F9988874 for ; Wed, 28 Aug 2024 14:10:50 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wm1-x32b.google.com with SMTP id 5b1f17b1804b1-4281c164408so57192675e9.1 for ; Wed, 28 Aug 2024 05:10:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847050; x=1725451850; darn=lists.denx.de; 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=dT3eVdcZ7+yTL3gKrjedSQI9zhitj9PAgp3LECTzRy0=; b=HzYaQyxwGKjuUxgzIiFzL7bxPMUUDMJ8oIpoQG+FtIAlTXtrwK2YIO5xgjNLgO89+3 SMrRBSXiHJPq/WaE5NAIQo6pX3zQEHz0aKu3LsLsCfnl8UtV1VnRnPuu8CltM1sjz6VG 5k4UzxK8jw1IOq6lomkSHWCEgZDds0zIvdVH1XC+7yCfOuRqkzhStZlWxTf338IXFEbt uJSkGQi2YMLEkxjABTten4HjlSWlaQnkczklou5abSnINWo5TkCZvnL3eL1rJ30fVhcO lwzMIkxb0PnOkXhzhoS05ELFK/4y4Aoa8HwhOlQb7dO53swco23WVHWptsJWknAr1ph8 Ss5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847050; x=1725451850; 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=dT3eVdcZ7+yTL3gKrjedSQI9zhitj9PAgp3LECTzRy0=; b=BzWiPhe5o0mbYmeFIqpOwNivCs7s+Z2sNmDPFMCdlv9Hc6KPpoQN1vG8BXuLNhJrs4 hpW7xw64P0c2sNxF7Yu5rHf/707x0NP0OVGFoOmSauiz3EsA68DVxsrGoxu3WbIV2r7o 1yiUHdxqPdtNQc/4Q9vlPGNuna+vbv1iPXOx6yr8kBpMPFdftHGq9P8eyCnF9Mj/0+9v WyIjUnuTmXcdIfgHkVjcDpdNQiNZlyVD7ryg2JEOjwppVs7qd3QWOgH2SaZkVrCr12I/ rRoCsWd+hX1sgSk85f0XLcH33wyRmXq5620k/LYOQgXpQqtjuyVyvbZdWzDUeferpHa1 4iuQ== X-Gm-Message-State: AOJu0YzeQagJz+SWryeFvFyuj4j+6hnlii86iTmmyEp+FrMccxs6gFlc t/HavepnN5KcqdOMg/Vd6DmmLUjVlJHxuh0kLipV1EfUC1C1CyKxpInIGs7MTKBdxiD9E9BRSdh lBNi3m2i+ X-Google-Smtp-Source: AGHT+IFHwHfXrG1XAYVS6A5DXeJ/GWoET5RnkkZyFw/ScCbbBHXBCr0ANbAle0b6r36ONKIrdFQijg== X-Received: by 2002:a05:600c:19cd:b0:427:ff7a:794 with SMTP id 5b1f17b1804b1-42ba6692269mr12315785e9.4.1724847049817; Wed, 28 Aug 2024 05:10:49 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:49 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Joe Hershberger , Ramon Fried , Tom Rini , Yang Xiwen , Robert Marko , Gabor Juhos , Jonas Karlman , Boon Khai Ng , Neil Armstrong Subject: [PATCH 08/13] net: ftgmac100: depend on NET Date: Wed, 28 Aug 2024 14:10:31 +0200 Message-Id: <3112cb1127580bf714f50a199b4ec9e998322202.1724846454.git.jerome.forissier@linaro.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 FTGMAC100 enables drivers/net/ftgmac100.c which uses PHY_INTERFACE_MODE_NCSI, which is defined only when PHY_NCSI is enabled. Therefore FTGMAC100 depends on PHY_NCSI. However adding such a dependency causes a "recursive dependency detected!" message, so add a dependency on NET instead (PHY_NCSI depends on NET). All in all, either the stack is NET and FTGMAC100 can be enabled, or it is NET_LWIP (or NO_NET) and it cannot. Signed-off-by: Jerome Forissier Reviewed-by: Simon Glass --- drivers/net/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/Kconfig b/drivers/net/Kconfig index 69ae7c0750..3382e533f4 100644 --- a/drivers/net/Kconfig +++ b/drivers/net/Kconfig @@ -461,6 +461,7 @@ config FTMAC100 config FTGMAC100 bool "Ftgmac100 Ethernet Support" select PHYLIB + depends on NET help This driver supports the Faraday's FTGMAC100 Gigabit SoC Ethernet controller that can be found on Aspeed SoCs (which From patchwork Wed Aug 28 12:10:32 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977819 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=iacbgOWh; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3FL0JHMz1yfy for ; Wed, 28 Aug 2024 22:12:22 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 208D988B36; Wed, 28 Aug 2024 14:10:56 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="iacbgOWh"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 03F5C88AD2; Wed, 28 Aug 2024 14:10:54 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.2 Received: from mail-wm1-x329.google.com (mail-wm1-x329.google.com [IPv6:2a00:1450:4864:20::329]) (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 7B0E788B1A for ; Wed, 28 Aug 2024 14:10:51 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wm1-x329.google.com with SMTP id 5b1f17b1804b1-42816ca782dso58310855e9.2 for ; Wed, 28 Aug 2024 05:10:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847051; x=1725451851; darn=lists.denx.de; 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=mJ3uAhukXyjblHix2uS6OBS4D6wbbgyXFHfq96WdFX4=; b=iacbgOWhLhoITLdTb+vroMv4MtaCbI5yWuA5z7gg6bywOZXA6tj5X1q8IBgwITvhDp 7x56bf1mBMASBoDp9xZ72AXIicmyZoZ19+X/VPnj2gXmrYWVD+qto913FitcucH2pPNO kxSCYox3ZWiNNH1RmxoY1ZY1ngGBPY15yMA7AHCIpbs8ASiYKLRLr7emy1C5MpEnthRz 0kCIf9DqT1FtUO+MLrgTJyV0zarqjUvlE4oXgz94hVt3xSG0aJLNNOgFRkCuDhnbROmi +D8i68v31fQXJgGVUPLLRtMurcjp2YlSHu4v2UFvUkQwwa6zRC84RHqYzb3tcHyL/kam 5emQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847051; x=1725451851; 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=mJ3uAhukXyjblHix2uS6OBS4D6wbbgyXFHfq96WdFX4=; b=N+o61Ztn3Bz7iNkuCJDsY5pTvGgjsekkujygSsICmJuJgJMCeyP7T6fgMosSjHv9ec aw88xtTLvRiprLETEE3tVasXC/1qZKsj7F53C6GPHZNHPZ7HAd6Je5VgGQCjj05UcpvS Tg5NRR0edvsRTBhNYQKT+i0wOhLLPATFYdaUgjhfGv9Qjmalsi0vV5HojC5+GJ0wfK6K nO9u7lNwDX6hibQGvoXiijHRPdoBA9uvYgqYASCfSvlUvmhL8tz+EFjOFB0cYU69zVx4 dQKZN5YtpinXJ9uHpQ/LjNFNJ7khwVlhCiC93vlm6Hz33TJynxPZW/ghk3wkHg+bqGon 6UxQ== X-Gm-Message-State: AOJu0YyZjNmwDASKl7fguqQvGm8DbmwsymM0wAP4aVaz3+70MqIQRTCk KHKGoutae9UDHjrRmIhMnagWyHw/cyTa/gp5TYTzVmJQlQpsn6H0F8G3cOOSdJj8Wd+RJ8Yn7ec Btq4IkzvI X-Google-Smtp-Source: AGHT+IEwaT0JLiqueVYy3PUSehjBX0ql7tWSlv0HEGGnIsT28zBASwCk3Ti+OmcMHziX1t9uDJMwrg== X-Received: by 2002:a05:600c:3d07:b0:42a:b62c:8c86 with SMTP id 5b1f17b1804b1-42acc9fe221mr121836105e9.32.1724847050711; Wed, 28 Aug 2024 05:10:50 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:50 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Joe Hershberger , Ramon Fried , Tom Rini , Masahisa Kojima , Simon Glass , Yasuharu Shibata , Marek Vasut Subject: [PATCH 09/13] net: wget: allow EFI boot Date: Wed, 28 Aug 2024 14:10:32 +0200 Message-Id: <1a6084e845a0612546a1e86d142208af945c8f77.1724846454.git.jerome.forissier@linaro.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 wget followed by bootefi currently fails as follows: U-Boot> wget 200000 192.168.0.30:helloworld.efi Waiting for Ethernet connection... done. HTTP/1.0 200 OK Packets received 13, Transfer Successful Bytes transferred = 12720 (31b0 hex) U-Boot> bootefi 200000 No UEFI binary known at 200000 U-Boot> Fix the problem by adding the missing efi_set_bootdev() call. Signed-off-by: Jerome Forissier Reviewed-by: Ilias Apalodimas Reviewed-by: Simon Glass --- net/wget.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/net/wget.c b/net/wget.c index 0e4dc5159d..cf7681a4e7 100644 --- a/net/wget.c +++ b/net/wget.c @@ -8,6 +8,7 @@ #include #include #include +#include #include #include #include @@ -429,6 +430,9 @@ static void wget_handler(uchar *pkt, u16 dport, case WGET_TRANSFERRED: printf("Packets received %d, Transfer Successful\n", packets); net_set_state(wget_loop_state); + efi_set_bootdev("Net", "", image_url, + map_sysmem(image_load_addr, 0), + net_boot_file_size); break; } } From patchwork Wed Aug 28 12:10:33 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977820 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=VWodHQFv; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3FY4gKJz1yfy for ; Wed, 28 Aug 2024 22:12:33 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 76CD388A2E; Wed, 28 Aug 2024 14:10:59 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="VWodHQFv"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id B6CB688A2E; Wed, 28 Aug 2024 14:10:54 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wm1-x32b.google.com (mail-wm1-x32b.google.com [IPv6:2a00:1450:4864:20::32b]) (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 4F19088AA7 for ; Wed, 28 Aug 2024 14:10:52 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wm1-x32b.google.com with SMTP id 5b1f17b1804b1-42ab880b73eso59982785e9.0 for ; Wed, 28 Aug 2024 05:10:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847051; x=1725451851; darn=lists.denx.de; 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=pSCk/K3y0znMBwS36qz04ulKJ9c8kUuxfDOEXC+T2eY=; b=VWodHQFvhvknrees0AVzYVR7rHKsD8oQHl7LeGQ9W2vtr02mH0NtINHnX1fA8+GER3 E4Gh1QRFh+nPZ3wvWGlk4y9hCEU0L2cupWY5hez+fG+Bl7/fmR5JzVkKbByKVadf/Iwe /l95UThNbGeKFc1FY7w8GOmQzzRvj/P69j7UpJl5fsYderY6TsKPp8/kXpQuF1ycKGeI TE2peKG8loQHxQP8Iz+K9aty3ny+z/XlGiRQuiMsKX5IxFgrxODR2G6SkgBcX751DTvn Q93hyhIJycTPEPm3q2mPji9nRwKJYp2z2xlNI41PZ+GhzkwO7srEyvl1fnWaFiCSU4dy f6HQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847051; x=1725451851; 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=pSCk/K3y0znMBwS36qz04ulKJ9c8kUuxfDOEXC+T2eY=; b=YfHpqvb43UrQLHDnnnys728qrYkQYBWpmxwp7QQbi29ZGSqIUIrPIIf3lbnp8uxBHI +jlzeDD4Yt/LBO1/uDKIdzLEzhNeUGKyCz0zYyUbxHdbDZuI4kbJGY3KTyN7aZ9/yeXK c/QOA3SYewQYVIE1uTmVwMemhk5N3P0eBaT4XV6oio8I6SLg5+qXrqaZgXZLZCjQhyuf sGUmoLIoUp/cU1Bs0yMRQ/ZgY2JkgCnns6eXm6uJlY8L6/ZP8DXZBsfFPA16A3B5n5Q/ D90BYVdVuLWNrZAE+lfuAwDTQDqkvfnQmrD1DyALRDGHYIDaz2qgywxyCkdZTAS7Nik4 XNOw== X-Gm-Message-State: AOJu0YwGZib6j4GXLO6GsoPZRZ8z9rpsdo/pm6UrMfz/OHM8Qq0M0AlB Spq2Fv6Lw507YBZBvPRlswBzHxYo54sMZMkyWnBfTvNNXa0cnPOvO0tMM2Vps3SyaaJ1YH6+98v AP1I/lnHg X-Google-Smtp-Source: AGHT+IFKE6vEyo6n8qObhIyPYf9gI37xSGt99ARlKlY8CyQ9mWMeThTH6iwkh9/EwurB5kVKxA5Ptw== X-Received: by 2002:a05:600c:4f83:b0:426:6320:7ddf with SMTP id 5b1f17b1804b1-42ba66c1a10mr10959975e9.35.1724847051555; Wed, 28 Aug 2024 05:10:51 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:51 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Fabio Estevam , Joe Hershberger , Ramon Fried , Tom Rini , Ye Li Subject: [PATCH 10/13] net: fec_mxc_init(): do not ignore return status of fec_open() Date: Wed, 28 Aug 2024 14:10:33 +0200 Message-Id: <4d8009789411a42fb860fcd00343c73d8fbe628c.1724846454.git.jerome.forissier@linaro.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 The fec_mxc_init() function currently always returns 0. This does not allow the callers to detect when for instance the PHY initialization failed due to the port being unconnected. Fix that by returning the status of fec_open(). Signed-off-by: Jerome Forissier Reviewed-by: Fabio Estevam Reviewed-by: Ilias Apalodimas --- drivers/net/fec_mxc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/fec_mxc.c b/drivers/net/fec_mxc.c index 0a0d92bc2c..2dc1364bee 100644 --- a/drivers/net/fec_mxc.c +++ b/drivers/net/fec_mxc.c @@ -615,8 +615,7 @@ static int fecmxc_init(struct udevice *dev) if (fec->xcv_type != SEVENWIRE) miiphy_restart_aneg(dev); #endif - fec_open(dev); - return 0; + return fec_open(dev); } /** From patchwork Wed Aug 28 12:10:34 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977821 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=Gutv4wh6; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3Fl6Yrqz1yfy for ; Wed, 28 Aug 2024 22:12:43 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id D8B4388B5A; Wed, 28 Aug 2024 14:11:04 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="Gutv4wh6"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 5FA0488AA7; Wed, 28 Aug 2024 14:10:55 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wr1-x434.google.com (mail-wr1-x434.google.com [IPv6:2a00:1450:4864:20::434]) (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 80E8788AF8 for ; Wed, 28 Aug 2024 14:10:53 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wr1-x434.google.com with SMTP id ffacd0b85a97d-3730749ee7aso3899209f8f.2 for ; Wed, 28 Aug 2024 05:10:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847053; x=1725451853; darn=lists.denx.de; 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=Tt2vjY7MaKscycbDjgQS+EhvZk4u1eI0iM4tc60Fq+8=; b=Gutv4wh6LfIhPaHvquQIMpPqBr0MfavTkWTC4OT+maF58Vd1NsGJr0HKLnUjtJoYzj Se1pS6qCfkLMfGnGZeSCeomwzEWauo4+Cq08E1TjMQuHN8A5vuqdyL0HcWantXw3dx6g xtwhPBaorsyHCZ55Wlo7yBxZt3qn3EFoqUeLo+w3CyfUaeR3x0dNUvLCSV/lp8aL5r7C 6KT76RfyvUe00T9uGZYBjMKSWobOwN2g0R9ji8cf2qBJJzDgYpFccKHjiouJW/WV3EGh nxMFGByMLiTXQHPgnuEslkeSKNNshlUBVhWwCyMOywV1nRXbac9eTZRcIIcrunQ3rU1Q z+XA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847053; x=1725451853; 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=Tt2vjY7MaKscycbDjgQS+EhvZk4u1eI0iM4tc60Fq+8=; b=TO0RszQvHe2Zct27RgxdfWG0+q4FVvpza2Y+fAMluEdYHqR5sC1juVnoyZZ40MaWEK 2kovgTgAgrFjIOi4LP7pTRayaD4oaYrTYIzjyllKyjJMBI5IUn8vW5XEM4LjemBlgQ+7 /rU3VyBI3+kvcgmRHXGlpn9lv6NOzfCqZ8yLbzPI4QGd1yjDYlWBT/m3rmzLuk3nzvQP etlk3pWTqP12K4ASo7pIsb3y9hH8JSjHvz3LzVev4tDdGZDTpFbPJaoN4G9RonHCOSKy t9lQ2yVIFuaiBERGEf/J3dwhTMgqrnEW1YIS0FNzYETIpnIPpIuxWfWj1wHAQhRI4xlG 0N4Q== X-Gm-Message-State: AOJu0YwCR6zNQAX9PH5zAGOS1fhjV5MErIwxlG06V5PMgpVJ2CAcDB2S Szq099AyxSGLRaVIiBPF/lsE9Oc5djLy+MAj5q9CD7AQgb2Ztkj/ZESI5w7JbO9Yt/DntF7yEdo Ys83Cl4F3 X-Google-Smtp-Source: AGHT+IHKMLDry5yqq8F6hoaqPodWpQbGAvy9nlH0WDpSPKCTKCfoTd0G8U4tfMSXgylcOc7jrJQ86Q== X-Received: by 2002:a5d:5911:0:b0:371:728e:d000 with SMTP id ffacd0b85a97d-3749680af92mr1212900f8f.1.1724847052741; Wed, 28 Aug 2024 05:10:52 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:52 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Tom Rini , Love Kumar Subject: [PATCH 11/13] test/py: net_boot: fix comment Date: Wed, 28 Aug 2024 14:10:34 +0200 Message-Id: <418bd1a5d16cf1e0061fd499ac82bef5bae82f68.1724846454.git.jerome.forissier@linaro.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 If env__pxe_boot_test_skip is not present, it defaults to True not False. Therefore fix the comment. Signed-off-by: Jerome Forissier Reviewed-by: Ilias Apalodimas --- test/py/tests/test_net_boot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/py/tests/test_net_boot.py b/test/py/tests/test_net_boot.py index 63309fe82e..d7d7435692 100644 --- a/test/py/tests/test_net_boot.py +++ b/test/py/tests/test_net_boot.py @@ -75,7 +75,7 @@ env__net_pxe_bootable_file = { 'check_pattern': 'ERROR', } -# False or omitted if a PXE boot test should be tested. +# False if a PXE boot test should be tested. # If PXE boot testing is not possible or desired, set this variable to True. # For example: If pxe configuration file is not proper to boot env__pxe_boot_test_skip = False From patchwork Wed Aug 28 12:10:35 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977823 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=trmFF7eK; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3Fy4Lbtz1yfy for ; Wed, 28 Aug 2024 22:12:54 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 35B9288B6A; Wed, 28 Aug 2024 14:11:05 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="trmFF7eK"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 446FA88B55; Wed, 28 Aug 2024 14:10:56 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wm1-x32f.google.com (mail-wm1-x32f.google.com [IPv6:2a00:1450:4864:20::32f]) (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 6216888AD2 for ; Wed, 28 Aug 2024 14:10:54 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wm1-x32f.google.com with SMTP id 5b1f17b1804b1-4281c164408so57193285e9.1 for ; Wed, 28 Aug 2024 05:10:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847053; x=1725451853; darn=lists.denx.de; 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=uOvm+usFf/OfMNJfit/RQ0Rx+oQkfNfrdGJgctlqbYk=; b=trmFF7eK+waUtCqcODGbwbdMJdreP1EdnPPCoiqs4RnJR9V8xEcTNG6wQumkEhMdEP HTad4+QMstczZRxVPPwwudBauXej2lJ+RB3fJe5esdPfdYqCfW0D3lZYnSYW6ScTUG5+ +2D/ab7+2j3Id6YobycPsQ6Uwhx0jWnhZQ2/wvcG6HfX+myAtx4tYh3RwE7rJHKbxYtN 9ApNokRzuvIqShWna0krxViOMxFpyFxZYS6kteLPM3T21O3sOzjM3bptEKDCYMoZqpEJ yQKOwVtJKvsj4pQIJpYU4GUq6Nm0k6sO4vShGYi2xqx50fPZ25OuQmxaTDEp3TrV9ByN RPtQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847053; x=1725451853; 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=uOvm+usFf/OfMNJfit/RQ0Rx+oQkfNfrdGJgctlqbYk=; b=O73JAceRhaafxH70j7RAkTnDSrmwRu6f1662fa+zCRrAoLpd8RomMylh/1KI70swJL KfGU/cNM9dKsDhJMkZAF4I0NHg0JUuMuYktMEmccQ+9eLoh6rjtKC/9A53ZEh6K0Z/e7 BQXDJauaH2aF8rdz5gTInlXmcYGR/tUkkecKlh9yZKnlojlL8O12HWvkbHHQVQCrCsNm TN3sz6VnxthTaDQeh2V2ZzHrVi87Ese1YEW2sYaoFUqX1J6pxtOhWVfS+/cmYaTvHyKl OlE88QzqyyTgM12tfkbDvPmggdR5Cgeg7jjK6Hp7p+HB7gOifK2qm2+nMQgp0cckoVde 6brA== X-Gm-Message-State: AOJu0Yz2h4wSKzZ1DXLe3NDAiRL9yTRTGV6r+db7wUZeI7+ndZHSRHuG HuLgHvnqRl662/AsPjyAf7aOEog6YKo0hS10Q7RplUwg8uMCUBV90YGrxGXm8mTzesvCfKCJ7Yr SavccgAMA X-Google-Smtp-Source: AGHT+IF+RKZw+841g6OckxKyD4tBNYujn2qHWMN69RcLQW6JZt2WXxbN1UO63rz8nb3Lpubib7ajJQ== X-Received: by 2002:a05:600c:a0b:b0:42b:8a35:1acf with SMTP id 5b1f17b1804b1-42ba66a8dd7mr12594775e9.25.1724847053536; Wed, 28 Aug 2024 05:10:53 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:53 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Tom Rini , Heinrich Schuchardt Subject: [PATCH 12/13] test/py: test_efi_loader: add missing dependency on cmd_tftpboot Date: Wed, 28 Aug 2024 14:10:35 +0200 Message-Id: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 test_efi_helloworld_net() and test_efi_grub_net() depend on cmd_tftpboot so add the missing annotations. Reported-by: Tom Rini Signed-off-by: Jerome Forissier Reviewed-by: Ilias Apalodimas --- test/py/tests/test_efi_loader.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test/py/tests/test_efi_loader.py b/test/py/tests/test_efi_loader.py index 85473a9049..7c1e0ffa59 100644 --- a/test/py/tests/test_efi_loader.py +++ b/test/py/tests/test_efi_loader.py @@ -149,6 +149,7 @@ def fetch_tftp_file(u_boot_console, env_conf): @pytest.mark.buildconfigspec('of_control') @pytest.mark.buildconfigspec('cmd_bootefi_hello_compile') +@pytest.mark.buildconfigspec('cmd_tftpboot') def test_efi_helloworld_net(u_boot_console): """Run the helloworld.efi binary via TFTP. @@ -178,6 +179,7 @@ def test_efi_helloworld_builtin(u_boot_console): @pytest.mark.buildconfigspec('of_control') @pytest.mark.buildconfigspec('cmd_bootefi') +@pytest.mark.buildconfigspec('cmd_tftpboot') def test_efi_grub_net(u_boot_console): """Run the grub.efi binary via TFTP. From patchwork Wed Aug 28 12:10:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Forissier X-Patchwork-Id: 1977824 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256 header.s=google header.b=K8UkZGDW; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wv3G91LjWz1yfy for ; Wed, 28 Aug 2024 22:13:05 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 87E0288B7F; Wed, 28 Aug 2024 14:11:05 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="K8UkZGDW"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 4F6BA88868; Wed, 28 Aug 2024 14:10:57 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wm1-x331.google.com (mail-wm1-x331.google.com [IPv6:2a00:1450:4864:20::331]) (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 542F288868 for ; Wed, 28 Aug 2024 14:10:55 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jerome.forissier@linaro.org Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-42819654737so56724935e9.1 for ; Wed, 28 Aug 2024 05:10:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724847054; x=1725451854; darn=lists.denx.de; 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=05192NsFH2MG3emPZoYYF3sUntFvJjHm1ytV4NXnLXs=; b=K8UkZGDWNzg6XgZ4Way8DRFVUPL8r1tvVO0vrRiOEnSoWflL4+ruXqrTA7EIT3M/yS sjdA5aS70AW8WrBD79b9ZjuczDoeTyCvM3r/3qEG0xdkSTd/R9uvt8eSuv/Yyzgdqy9R vSFsIrxXjcVWqAkVcWAmrgmmqx+VWHAvIU3PqISSfKEbUP1AE5/tcfzDUYewi7fu5Vcm mQJH5xAcQcwr3MUN+vJy5IvYvDxpPmotMt0MjfWDZ0uHhIf243wjtdk2MZYRQyFbeGWo objwvzBv6JeBht00MbV/2+/xaDV0zD3nR3oI1iJnJxtCr8ViP778+xWHaVCnk6Y117ui 8Peg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724847054; x=1725451854; 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=05192NsFH2MG3emPZoYYF3sUntFvJjHm1ytV4NXnLXs=; b=pLidBMP6O9bWXDCGlJauHM0ZHo1UH4Z3/7K/gO1ciPSYbm8n3XwczuShGXzLF38deL zCQHAnQ5DcfI6r2pAfXUD1fs3hfpHBZY7U3eOxWAVFT0hAixduKm1a8FSWjOKkkCtMhQ pAOGLwAwF4Csn/Jjgta/XyNLhw6WHr1063qcPJVZOssPNSZVh4QaTRlpBVZLVs0V0y+y c80zMZOPUYrjL/9FeA/0LtVLk7QI0ncdwdLVXBsg2Tn1/vDEFDXWZmydIW/T8MlQ8BG5 Q5G3lcudT31bbpn8jXXlYuqaLzauOGIGFnpPDcmecqPbkMtVOIvcSzsP1l5Afzkfzhuc NvRg== X-Gm-Message-State: AOJu0YyvOG4prcOmPBHEM7ecrIFSGfvmY4fb6Ijufd0DwaTtQFJN+460 QIu8A43j92a/IZdePciExj1KwkdGbvLs8B9l+xPNo9F5rjqQyYVgjYqno8NDZ6oyVMJLu4zOBnQ Py2E6vH0O X-Google-Smtp-Source: AGHT+IHYqpM184lV3c6oeXgVoxlrciBfTPJGmZGK5JTKXm8farvw9mT5PwWb7eeiqD6sQiTU6urGvw== X-Received: by 2002:a05:600c:a08:b0:426:6e95:78d6 with SMTP id 5b1f17b1804b1-42acd534890mr114138235e9.4.1724847054467; Wed, 28 Aug 2024 05:10:54 -0700 (PDT) Received: from builder.. ([2a01:e0a:3cb:7bb0:8ac3:aada:f033:985a]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ba639687csm19470365e9.8.2024.08.28.05.10.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Aug 2024 05:10:54 -0700 (PDT) From: Jerome Forissier To: u-boot@lists.denx.de Cc: Ilias Apalodimas , Peter Robinson , Jerome Forissier , Tom Rini , Heinrich Schuchardt Subject: [PATCH 13/13] test/py: test_efi_loader: add HTTP (wget) test for the EFI loader Date: Wed, 28 Aug 2024 14:10:36 +0200 Message-Id: <719ff6dc8f79e0ccb6160bbbbc834b30ac70ca78.1724846454.git.jerome.forissier@linaro.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: References: MIME-Version: 1.0 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 a test to test_efi_loader.py similar to the TFTP test but for HTTP with the wget command. Suggested-by: Tom Rini Signed-off-by: Jerome Forissier Tested-by: Tom Rini --- test/py/tests/test_efi_loader.py | 62 +++++++++++++++++++++++--------- 1 file changed, 46 insertions(+), 16 deletions(-) diff --git a/test/py/tests/test_efi_loader.py b/test/py/tests/test_efi_loader.py index 7c1e0ffa59..5f3b448a06 100644 --- a/test/py/tests/test_efi_loader.py +++ b/test/py/tests/test_efi_loader.py @@ -45,11 +45,18 @@ env__efi_loader_helloworld_file = { 'crc32': 'c2244b26', # CRC32 check sum 'addr': 0x40400000, # load address } + +# False if the helloworld EFI over HTTP boot test should be performed. +# If HTTP boot testing is not possible or desired, set this variable to True or +# ommit it. +env__efi_helloworld_net_http_test_skip = True """ import pytest import u_boot_utils +PROTO_TFTP, PROTO_HTTP = range(0, 2) + net_set_up = False def test_efi_pre_commands(u_boot_console): @@ -110,10 +117,10 @@ def test_efi_setup_static(u_boot_console): global net_set_up net_set_up = True -def fetch_tftp_file(u_boot_console, env_conf): - """Grab an env described file via TFTP and return its address +def fetch_file(u_boot_console, env_conf, proto): + """Grab an env described file via TFTP or HTTP and return its address - A file as described by an env config is downloaded from the TFTP + A file as described by an env config is downloaded from the server. The address to that file is returned. """ if not net_set_up: @@ -128,7 +135,13 @@ def fetch_tftp_file(u_boot_console, env_conf): addr = u_boot_utils.find_ram_base(u_boot_console) fn = f['fn'] - output = u_boot_console.run_command('tftpboot %x %s' % (addr, fn)) + if proto == PROTO_TFTP: + cmd = 'tftpboot' + elif proto == PROTO_HTTP: + cmd = 'wget' + else: + assert False + output = u_boot_console.run_command('%s %x %s' % (cmd, addr, fn)) expected_text = 'Bytes transferred = ' sz = f.get('size', None) if sz: @@ -147,17 +160,8 @@ def fetch_tftp_file(u_boot_console, env_conf): return addr -@pytest.mark.buildconfigspec('of_control') -@pytest.mark.buildconfigspec('cmd_bootefi_hello_compile') -@pytest.mark.buildconfigspec('cmd_tftpboot') -def test_efi_helloworld_net(u_boot_console): - """Run the helloworld.efi binary via TFTP. - - The helloworld.efi file is downloaded from the TFTP server and is executed - using the fallback device tree at $fdtcontroladdr. - """ - - addr = fetch_tftp_file(u_boot_console, 'env__efi_loader_helloworld_file') +def do_test_efi_helloworld_net(u_boot_console, proto): + addr = fetch_file(u_boot_console, 'env__efi_loader_helloworld_file', proto) output = u_boot_console.run_command('bootefi %x' % addr) expected_text = 'Hello, world' @@ -165,6 +169,32 @@ def test_efi_helloworld_net(u_boot_console): expected_text = '## Application failed' assert expected_text not in output +@pytest.mark.buildconfigspec('of_control') +@pytest.mark.buildconfigspec('cmd_bootefi_hello_compile') +@pytest.mark.buildconfigspec('cmd_tftpboot') +def test_efi_helloworld_net_tftp(u_boot_console): + """Run the helloworld.efi binary via TFTP. + + The helloworld.efi file is downloaded from the TFTP server and is executed + using the fallback device tree at $fdtcontroladdr. + """ + + do_test_efi_helloworld_net(u_boot_console, PROTO_TFTP); + +@pytest.mark.buildconfigspec('of_control') +@pytest.mark.buildconfigspec('cmd_bootefi_hello_compile') +@pytest.mark.buildconfigspec('cmd_wget') +def test_efi_helloworld_net_http(u_boot_console): + """Run the helloworld.efi binary via HTTP. + + The helloworld.efi file is downloaded from the HTTP server and is executed + using the fallback device tree at $fdtcontroladdr. + """ + if u_boot_console.config.env.get('env__efi_helloworld_net_http_test_skip', True): + pytest.skip('helloworld.efi HTTP test is not enabled!') + + do_test_efi_helloworld_net(u_boot_console, PROTO_HTTP); + @pytest.mark.buildconfigspec('cmd_bootefi_hello') def test_efi_helloworld_builtin(u_boot_console): """Run the builtin helloworld.efi binary. @@ -187,7 +217,7 @@ def test_efi_grub_net(u_boot_console): executed. """ - addr = fetch_tftp_file(u_boot_console, 'env__efi_loader_grub_file') + addr = fetch_file(u_boot_console, 'env__efi_loader_grub_file', PROTO_TFTP) u_boot_console.run_command('bootefi %x' % addr, wait_for_prompt=False)