From patchwork Mon Jan 23 22:07:21 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 1730725 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; 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=) 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=svLsSlB3; dkim-atps=neutral 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 (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4P14Gs5Wm2z23gY for ; Tue, 24 Jan 2023 09:17:41 +1100 (AEDT) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 9AF0F857F1; Mon, 23 Jan 2023 23:10:18 +0100 (CET) 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="svLsSlB3"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 9D3B285479; Mon, 23 Jan 2023 23:07:43 +0100 (CET) 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 autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-ej1-x634.google.com (mail-ej1-x634.google.com [IPv6:2a00:1450:4864:20::634]) (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 BB99385569 for ; Mon, 23 Jan 2023 23:07:38 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=linus.walleij@linaro.org Received: by mail-ej1-x634.google.com with SMTP id hw16so34234650ejc.10 for ; Mon, 23 Jan 2023 14:07:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=VoWauswNOpfd++EQlV1QkEKyr/zKwSOOFToxz2shWBk=; b=svLsSlB3vOOCyYA8zJQ1qGDP6GsibXKM+C2v7+uRIIbeuyrDubPsQ0G7VIEsQ5GVoW f1OSwOyOGURNFERaS02eGrzB/FsJ3/JXStg/42pfyegDgd3A6PiktXY1o2IIf3hfPCyS 7zqI7M8Vl93B3jAnO0DeY+IX0t+q0euDyWTfsnh1gWVMoD0FlGDh6ZJGapq3HDrMb3kd DmK5nXoN/gWsp2vvu0pOTuv+3GwuhbER0enrmIXu5bnV7R2K0PmUlsoKWBz9r6mxwFGW DzFUobhOdIwMXt0wIJGLiqyXn8Ps/BRQxnHQmx3qnhzjXTBAgMVHXh79rpusvCnm/BPu VO3g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=VoWauswNOpfd++EQlV1QkEKyr/zKwSOOFToxz2shWBk=; b=mCLkwcNnZyYvd/UNCDAHTTsaRPi0tSp3P4CEwuHvQ1ObAi684ldbgcK5Xyd0RZgt/R YzeWlYu0PjUqoHVvWwOtvrSIY9JN4ZOvyJ+CpDlQLoj+UoinqVNHsWCP5KKAVpro+7jp JVPXimrZg2KTsklxc/6zWDhEjucIUt3gEc5Y28Mv7VDwbVITmP3tUcBgQeQsZio/eJIv +vwFvx/GXHPToGsG10WCFaSrAiNRLfnJ3iqYnrobd6x/syhrYn6aSgk6pyajCiHLkkWC zTpLC2P3s0n4icv8rwo7A+perFGpkjL/wI+lOGSKb5hPn9smuYPZE88qKhbe6AsIMsKy BJdQ== X-Gm-Message-State: AFqh2ko+v2wGgPwXNtpHuHjYFco27RLFlBWhjMBdT+vuq+2nWoRTbFhH Jlnv/D+Je3LcKqGVsI6TS+Jb4FbkNEmQFiX2 X-Google-Smtp-Source: AMrXdXuZgRVq1ynavI8mPxB7jqIZlIhIq1TupGZAkqq2U1VLpYI1WQ4KlOyNdxH5loxg4mc6hYdJig== X-Received: by 2002:a17:906:d20f:b0:84d:4d6c:a462 with SMTP id w15-20020a170906d20f00b0084d4d6ca462mr24416286ejz.25.1674511657069; Mon, 23 Jan 2023 14:07:37 -0800 (PST) Received: from localhost.localdomain (c-05d8225c.014-348-6c756e10.bbcust.telenor.se. [92.34.216.5]) by smtp.gmail.com with ESMTPSA id hs8-20020a1709073e8800b008727576e4ecsm8787ejc.117.2023.01.23.14.07.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 23 Jan 2023 14:07:35 -0800 (PST) From: Linus Walleij To: u-boot@lists.denx.de, Tom Rini Cc: Linus Walleij , Simon Glass Subject: [PATCH] test: bootdev: Do not require USB to compile test Date: Mon, 23 Jan 2023 23:07:21 +0100 Message-Id: <20230123220721.2463058-1-linus.walleij@linaro.org> X-Mailer: git-send-email 2.39.0 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.6 at phobos.denx.de X-Virus-Status: Clean This test will block compilation of the entire test suite on platforms without USB support. Make the extern "usb_started" conditional on USB host or gadget and define a dummy flag if neither is enabled. Cc: Simon Glass Signed-off-by: Linus Walleij Reviewed-by: Simon Glass --- test/boot/bootdev.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/boot/bootdev.c b/test/boot/bootdev.c index 1c2a79fb1084..fa466b708184 100644 --- a/test/boot/bootdev.c +++ b/test/boot/bootdev.c @@ -18,7 +18,11 @@ #include "bootstd_common.h" /* Allow reseting the USB-started flag */ +#if defined(CONFIG_USB_HOST) || defined(CONFIG_USB_GADGET) extern char usb_started; +#else +char usb_started; +#endif /* Check 'bootdev list' command */ static int bootdev_test_cmd_list(struct unit_test_state *uts)