From patchwork Sun Apr 30 01:29:34 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775300 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=G3csvyms; 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 4Q881k1C6tz1ydX for ; Sun, 30 Apr 2023 11:31:06 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 985A386181; Sun, 30 Apr 2023 03:30:32 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="G3csvyms"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 1470585C9B; Sun, 30 Apr 2023 03:30:18 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x12a.google.com (mail-il1-x12a.google.com [IPv6:2607:f8b0:4864:20::12a]) (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 D461D86103 for ; Sun, 30 Apr 2023 03:30:12 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x12a.google.com with SMTP id e9e14a558f8ab-32f397b44dcso30559305ab.1 for ; Sat, 29 Apr 2023 18:30:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818211; x=1685410211; 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=vIR3kubaLVp6VMdHQBTKmgIJNbOcG6BdslD/6QyCMxw=; b=G3csvymsq2mZCdubizzwJv4iCzQ+d/blbc3QkMHhLEEhmh5wBq4ZCxk44iMUvIyNmL ULUuNidUxKrd6sp7tgHB4Y0Wh3+4hi9EBm9J/TQAGeDk/bNfhfz3GqQP+wsMVPyRRlpZ 1WDwhU91Y6DPsdNwrBtBhxe4UEASbLu3Hd3+o= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818211; x=1685410211; 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=vIR3kubaLVp6VMdHQBTKmgIJNbOcG6BdslD/6QyCMxw=; b=SizBVlzXLFfphQllw0kdiuecuxIuwezsGcrf9pGsYpeBCm67UZGYGolOZ4l2AUa+ET do7PV/FYRCCT1+pcgKGJaC7RIBvVLYah7IGHUfpitwH6xI7uOsaXufd7BH8tWHDYFrL6 kxV5xn1yKhgxjwc7xg5d48oHijORoj1K94m2AJgyW2MnXpCdLqbbjNqMW+BUuVDx4fZ0 GPy6eXssnl2JBczIZTdgkdlZdR5e7fnoi5on6tPpraeg6twx1K9dZn6DWdC/odPk5tsT 6fj6Bbm0Cctz0rfv72zfqBQViVRVenXaMMuZtij+MjzN9w1hG29op/rbNKy2ayuNw6Gr dxiA== X-Gm-Message-State: AC+VfDxPmb6oQ04O02fpMirTNyzrVCsuvi1HU5pLu+uKTAV8IxC47Whg AZxGvLD8VAtUJHCMEN4YLIx1ieMKQiQiAUQCj9U= X-Google-Smtp-Source: ACHHUZ6MB+N0BMDbvBdlPuLGltKLD4yIi45RRhr+p5strDYtPP+XG7fvjtY1Q3hOUW1hQGzxsrDNVA== X-Received: by 2002:a05:6e02:ec8:b0:32b:3555:f690 with SMTP id i8-20020a056e020ec800b0032b3555f690mr7892895ilk.2.1682818211382; Sat, 29 Apr 2023 18:30:11 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:11 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 01/30] u_boot_pylib: Correct name of readme Date: Sat, 29 Apr 2023 19:29:34 -0600 Message-ID: <20230430013003.1047454-2-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 This has an rst prefix rather than md. Fix it. Signed-off-by: Simon Glass --- (no changes since v1) tools/u_boot_pylib/README.rst | 2 +- tools/u_boot_pylib/pyproject.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/u_boot_pylib/README.rst b/tools/u_boot_pylib/README.rst index 93858f5571da..b1bab4364896 100644 --- a/tools/u_boot_pylib/README.rst +++ b/tools/u_boot_pylib/README.rst @@ -1,6 +1,6 @@ .. SPDX-License-Identifier: GPL-2.0+ -# U-Boot Python Library +U-Boot Python Library ===================== This is a Python library used by various U-Boot tools, including patman, diff --git a/tools/u_boot_pylib/pyproject.toml b/tools/u_boot_pylib/pyproject.toml index 3f33caf6f8d2..31a4c0adae87 100644 --- a/tools/u_boot_pylib/pyproject.toml +++ b/tools/u_boot_pylib/pyproject.toml @@ -9,7 +9,7 @@ authors = [ { name="Simon Glass", email="sjg@chromium.org" }, ] description = "U-Boot python library" -readme = "README.md" +readme = "README.rst" requires-python = ">=3.7" classifiers = [ "Programming Language :: Python :: 3", From patchwork Sun Apr 30 01:29:35 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775297 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=DpGNUAEQ; 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) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Q88126Fzvz1ydX for ; Sun, 30 Apr 2023 11:30:29 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 9648C860C7; Sun, 30 Apr 2023 03:30:17 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="DpGNUAEQ"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 83C3C8617B; Sun, 30 Apr 2023 03:30:16 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-io1-xd33.google.com (mail-io1-xd33.google.com [IPv6:2607:f8b0:4864:20::d33]) (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 D455A85BFB for ; Sun, 30 Apr 2023 03:30:13 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-io1-xd33.google.com with SMTP id ca18e2360f4ac-7696975338aso8688039f.1 for ; Sat, 29 Apr 2023 18:30:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818212; x=1685410212; 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=AynfM4ja5aj2kI+L47HoSgCFUnSUH6HEdSUoDBTBCkY=; b=DpGNUAEQ/oJSJQeNNZn48sOUyU1g/Dg31dJ03xZZeIm44IFoYehtreaxRuAHG6AxWO WLGf2BfSzhfnrCvIZ0xsD1AxDdG+6sVYqH1dcOv/FwwSuSkl9nwo1Jbka3Poe4y5VeJ3 v3QH+hgvQpBaRCERJeb+cbTUcxFCUI51uA8Ic= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818212; x=1685410212; 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=AynfM4ja5aj2kI+L47HoSgCFUnSUH6HEdSUoDBTBCkY=; b=Q8+fZYqc5l/q3H78noMzDqKIEFh9NGc1bhL/dbV6hqL//Qiig2G/QpbWVbbHmU8FZF JDH9IGBkSURQ751BEHv3QpgpXUrKxXwCcBrGgQ1YueVXgFNmli7Wq42DwpS/x99DWmJo gS0tdPntEvOSimROTCVe1SlPtdFUbEtsavjbEfkVs3b7rvPAIejQ/bGGTKLKslz04qgj 0dmEPkIo/omIPCD9wlouTRK7fiZulRQcx5rgs8ilfjL+diK/5W7aav4nDEZOl53LXQFm y/0gl1Y9Q+taX5avl2tPfpLkbmLGkJjPER1zc5K+wufSIlIHfSfGSwX9cyLAxx+NznXS VJeg== X-Gm-Message-State: AC+VfDyjS0jHPpOc3BSxTstkHuBbuba7YRTWYUkIR5PDTP8kCCVVdNFW QXECP+JDTkLPwfQRc3KQgMgg9vggoP9l7WJtMME= X-Google-Smtp-Source: ACHHUZ5Z5bqmPnaJbqi1d2amfyCnUbmHAKusNj+uc3R7ywIZmLSwC42KQ5465fsYMYsJGFNNmzv0cw== X-Received: by 2002:a5e:9707:0:b0:761:b329:535f with SMTP id w7-20020a5e9707000000b00761b329535fmr6347676ioj.4.1682818212388; Sat, 29 Apr 2023 18:30:12 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:12 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 02/30] u_boot_pylib: Avoid deleting the test_util.py file Date: Sat, 29 Apr 2023 19:29:35 -0600 Message-ID: <20230430013003.1047454-3-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 This is needed, so update the removal code to keep it. Signed-off-by: Simon Glass --- Changes in v2: - Split out u_boot_pylib from the subprocess patch scripts/make_pip.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/make_pip.sh b/scripts/make_pip.sh index 4602dcf61c88..ef43e028e385 100755 --- a/scripts/make_pip.sh +++ b/scripts/make_pip.sh @@ -91,7 +91,12 @@ find ${dest} -name __pycache__ -type f -exec rm {} \; find ${dest} -depth -name __pycache__ -exec rmdir 112 \; # Remove test files -rm -rf ${dest}/*test* +for path in ${dest}/*test*; do + echo ${path} + if ! [[ "${path}" =~ .*test_util.* ]]; then + rm -rf ${path} + fi +done mkdir ${dir}/tests cd ${dir} From patchwork Sun Apr 30 01:29:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775299 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=kGDCr1zY; 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 4Q881R2LbMz1ydX for ; Sun, 30 Apr 2023 11:30:51 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 3173386189; Sun, 30 Apr 2023 03:30:25 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="kGDCr1zY"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 823EF85C9B; Sun, 30 Apr 2023 03:30:17 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-io1-xd2f.google.com (mail-io1-xd2f.google.com [IPv6:2607:f8b0:4864:20::d2f]) (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 BBABD85D10 for ; Sun, 30 Apr 2023 03:30:14 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-io1-xd2f.google.com with SMTP id ca18e2360f4ac-7606d44604aso115379139f.1 for ; Sat, 29 Apr 2023 18:30:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818213; x=1685410213; 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=YcR38uDohRhiiB06Pe3T5YBGan8eApjAgplaD4R5FCs=; b=kGDCr1zYjPtkAMnKtERHJ2eKv+ahygxxe7WjH7qPjmFYCoOB+O/V1DFRmGhsT6Nh6D fU0Wd5p7VlrZ/3ttkriu1iyCQ0ximbYcR13vsOfPrpjVjbHipk5cf5PL6Bet05727+rg LCQicJ4zHAje/o5vDP+qbPHeiJeDcL8T0Ujmc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818213; x=1685410213; 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=YcR38uDohRhiiB06Pe3T5YBGan8eApjAgplaD4R5FCs=; b=VJQhUs5VyPnq+jsiYWhXSIoUzycQKKi4wNIYWlBep4y/k+453sG7dnpm5ONhtkYM/k RhPL7QX07uSvVwLCrDtlCsDpvQdhrCAShMirHm0Zqj6IrE/gGDPLg6oxSv4rEE2++S/v KODidCRTW7HhiKy5/OkiW54PzHDZ24j+Uh2/9rSLy33cyNQy96DuOZ/7PzNqjCnVzSkO s55ddxAY0l+zt0Ld2G5EA0no4iHdTanztaaxYxIf3SM7OsCzCEoYA/SXNLli38rGQ5aW iZvnG08Ne2FThgoIK1QkLNYwcVMJ1hJfxj5QW+DjSF1psYCha0TFPvZwlgFCEldK+0OW ueCw== X-Gm-Message-State: AC+VfDzdxU27xZDFV1LohMFqh1kD6se1tyhoiIR5pbKAMkZkAWpcrPIA QJdf18Ga5gJVxJN1dVe8kDfXIa9wrkKtfFfRK8A= X-Google-Smtp-Source: ACHHUZ73suTfSNGyDaLRHZUH0IhkS79YRh2Nr2TpE3RPDgC/heomsOf7K3SpVt1JY1Gy6+fk236X7Q== X-Received: by 2002:a5d:8e0e:0:b0:760:e373:f833 with SMTP id e14-20020a5d8e0e000000b00760e373f833mr5775570iod.8.1682818213287; Sat, 29 Apr 2023 18:30:13 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:13 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 03/30] u_boot_pylib: Make pty optional Date: Sat, 29 Apr 2023 19:29:36 -0600 Message-ID: <20230430013003.1047454-4-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 This library is not available on Windows. Detect this and work around it by using a normal pipe. Signed-off-by: Simon Glass --- Changes in v2: - move u_boot_pylib changes to a separate patch tools/u_boot_pylib/cros_subprocess.py | 28 ++++++++++++++++++++++----- 1 file changed, 23 insertions(+), 5 deletions(-) diff --git a/tools/u_boot_pylib/cros_subprocess.py b/tools/u_boot_pylib/cros_subprocess.py index cd614f38a648..35cef7333f3a 100644 --- a/tools/u_boot_pylib/cros_subprocess.py +++ b/tools/u_boot_pylib/cros_subprocess.py @@ -16,12 +16,18 @@ progress information and filter output in real time. import errno import os -import pty import select import subprocess import sys import unittest +try: + import pty + HAVE_PTY = True +except: + # For Windows + HAVE_PTY = False + # Import these here so the caller does not need to import subprocess also. PIPE = subprocess.PIPE @@ -74,11 +80,17 @@ class Popen(subprocess.Popen): stderr_pty = None if stdout == PIPE_PTY: - stdout_pty = pty.openpty() - stdout = os.fdopen(stdout_pty[1]) + if HAVE_PTY: + stdout_pty = pty.openpty() + stdout = os.fdopen(stdout_pty[1]) + else: + stdout = PIPE if stderr == PIPE_PTY: - stderr_pty = pty.openpty() - stderr = os.fdopen(stderr_pty[1]) + if HAVE_PTY: + stderr_pty = pty.openpty() + stderr = os.fdopen(stderr_pty[1]) + else: + stderr = PIPE super(Popen, self).__init__(args, stdin=stdin, stdout=stdout, stderr=stderr, shell=shell, cwd=cwd, env=env, @@ -156,6 +168,12 @@ class Popen(subprocess.Popen): Note also that if you set stderr to STDOUT, then stderr will be empty and the combined output will just be the same as stdout. """ + if not HAVE_PTY: + stdout, stderr = self.communicate(input_buf) + stdout = self.convert_data(stdout) + stderr = self.convert_data(stderr) + combined = self.convert_data(stdout + stderr) + return (stdout, stderr, combined) read_set = [] write_set = [] From patchwork Sun Apr 30 01:29:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775301 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=HIaAGAJO; 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 4Q88206gqVz1ydX for ; Sun, 30 Apr 2023 11:31:20 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 4237985D10; Sun, 30 Apr 2023 03:30:34 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="HIaAGAJO"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id AB47785C9B; Sun, 30 Apr 2023 03:30:18 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x12b.google.com (mail-il1-x12b.google.com [IPv6:2607:f8b0:4864:20::12b]) (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 967BF8615D for ; Sun, 30 Apr 2023 03:30:15 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x12b.google.com with SMTP id e9e14a558f8ab-32adf94ac1bso3258565ab.0 for ; Sat, 29 Apr 2023 18:30:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818214; x=1685410214; 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=YzunrxanIxFqqWiUj26s/N6/VXCpB2MqSIC0o+heDpU=; b=HIaAGAJOGTzTC5TmYLtV3yqaW7llvBckR2e/eMZcS4Z0S+xcjwsN2TRsMF2OS0RICQ RTyEtLzGl6ltWJ9qL5Y6WxQMyfqkdocynSmXHGU2L66m9IfmrMimDviKuxwDUA/As/cm gv7g6nJiBPvnrVPWuERAFwbDxe4Z7uFdEhLO0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818214; x=1685410214; 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=YzunrxanIxFqqWiUj26s/N6/VXCpB2MqSIC0o+heDpU=; b=Xe8kgrMeZSFGyZwef0hT22LySckWTY3TA9YboBzZHt7WzC3amitO+KUEAu++ZnufKp yxkUz1fZ6pPGqTJvb1iUcZQW0uJ/FsdMTb//pf/VxZg9qlHbARa9s8E8DpoOSboaraMw T7JtkeaeNkddeQ4PNVtExTU2fc1IzZAYDyU3jcpWYFHHWE9ynBZIQorJ7ty3n/4wWbwp Jx2HZXIhzBxiYdoldZyctqE5z4KtWetHeyhb+MLU0E+8JjRg3wpdnwqr6Fbk3aQukmeY Rwf8nP6pQf/rqOxfitKedJCVgL/8/ogvOyyfBWWjwVIKAjzp75Sar6yqikcyylQUiw+Z aa3A== X-Gm-Message-State: AC+VfDx8tzXJ0uJT//r+RgCsfIXx/zSojN0gd1Pc8+S5oFfb+B2IGofx o5t7PyoAxf6gIEeC7HEFm7v3d8DFuZGiS4zSnds= X-Google-Smtp-Source: ACHHUZ6ALLid8WKaFpV8OxysWq7kq5Kwrp6T8ab6OX0+Uj+ztHK4rSdzC9OEUxSGHC4qOO7Ztkq8yw== X-Received: by 2002:a92:b0f:0:b0:32a:ea4e:97d1 with SMTP id b15-20020a920b0f000000b0032aea4e97d1mr6449602ilf.10.1682818214231; Sat, 29 Apr 2023 18:30:14 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:13 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass , Alper Nebi Yasak , Neha Malcom Francis , Peng Fan , Philippe Reynes , Stefan Herbrechtsmeier Subject: [PATCH v2 04/30] binman: Avoid using a symlink Date: Sat, 29 Apr 2023 19:29:37 -0600 Message-ID: <20230430013003.1047454-5-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 Use a small Python script instead of a symlink to avoid problems with Windows. Signed-off-by: Simon Glass --- (no changes since v1) tools/binman/binman | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) mode change 120000 => 100755 tools/binman/binman diff --git a/tools/binman/binman b/tools/binman/binman deleted file mode 120000 index 11a5d8e18ab7..000000000000 --- a/tools/binman/binman +++ /dev/null @@ -1 +0,0 @@ -main.py \ No newline at end of file diff --git a/tools/binman/binman b/tools/binman/binman new file mode 100755 index 000000000000..2b0633073abc --- /dev/null +++ b/tools/binman/binman @@ -0,0 +1,10 @@ +#!/usr/bin/env python3 +# SPDX-License-Identifier: GPL-2.0+ + +import os + +our_path = os.path.dirname(os.path.realpath(__file__)) + +import main + +main.start_binman() From patchwork Sun Apr 30 01:29:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775302 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=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=fYmifs6b; dkim-atps=neutral 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 (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Q882J2gsdz1ydX for ; Sun, 30 Apr 2023 11:31:36 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 57795861C0; Sun, 30 Apr 2023 03:30:36 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="fYmifs6b"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id A78FA86188; Sun, 30 Apr 2023 03:30:19 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x135.google.com (mail-il1-x135.google.com [IPv6:2607:f8b0:4864:20::135]) (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 AF5C085BFB for ; Sun, 30 Apr 2023 03:30:16 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x135.google.com with SMTP id e9e14a558f8ab-3294fd17f1cso2827665ab.1 for ; Sat, 29 Apr 2023 18:30:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818215; x=1685410215; 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=4uiK5msbRrlWwRiWAXdE8iakYbFUfhgaMS5OeVW1+x0=; b=fYmifs6bPszTiRLqL5u51qQfEVXiJV85ts+tis2PR+Vl5Yfa5Qw5QB+YcdMq7BWjfX InJOsST2Trb85sjdQgL1j0LVI8D/pw4btCOBEt3bfc7dbqA4rOqMqDbI7yXtDOXB0wvc 8hRv34+QbhKs3+Zy/NML88piQTjVOKZgi/UxY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818215; x=1685410215; 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=4uiK5msbRrlWwRiWAXdE8iakYbFUfhgaMS5OeVW1+x0=; b=KRW8NDONQ/dyVxhi19Gjc4p5naNHfCnrEVh4q0MK/IAOLKmWFx9+9lL3cA8eFwnkD/ 8eUqwW3+Q0fxEhdeJH9itGaX11rwDnZXtvHpAfccfC5kj0AwH65NOJRtr9DH4vcLS9Pi BFH91mZ3r8YJGkbNynZ3xiWY9NsbTjsbFn6V6NczFMtODVmy5Kui9fIhC3clw0Mhl11d jJYge2fxkTShsL0WOHzbZm5JPO7B8NrlFcXqeiDZeBnSkq1fS5pqVjhHJ1YRFcaw8CIc eJYYTlfdEDcr8NctBno1HLn53ri5+XMtYD/7jRCGHTy9/NWnO+briJ1otOpu6H+Au5Mf XMLA== X-Gm-Message-State: AC+VfDxFDnZhHGQ8SYaHyHI40YgOTs/Q8ITQ5q+4E7lF+/s4lPJr40Iq 56un1YAYMytwVqipcwtdIbBbnDAcQKLe/FPgC2s= X-Google-Smtp-Source: ACHHUZ5su2fq5QX/bu7FsguyIruS5gB+K483kto7nAjNmfPXosdJ2kgL7HgUEybfKhSYCgCag8k06Q== X-Received: by 2002:a05:6e02:805:b0:323:bce:f23f with SMTP id u5-20020a056e02080500b003230bcef23fmr6002133ilm.3.1682818215281; Sat, 29 Apr 2023 18:30:15 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:15 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 05/30] pylibfdt: Allow building on Windows Date: Sat, 29 Apr 2023 19:29:38 -0600 Message-ID: <20230430013003.1047454-6-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 Handle the different shared-object extension with MSYS2 by creating a new SOEXT variable. Signed-off-by: Simon Glass --- Changes in v2: - Use LIBEXT instead of SOEXT Makefile | 11 +++++++++++ scripts/dtc/pylibfdt/Makefile | 16 +++++++++------- 2 files changed, 20 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index 166acba27032..2453a80eca62 100644 --- a/Makefile +++ b/Makefile @@ -39,6 +39,17 @@ else ifeq ("riscv64", $(MK_ARCH)) endif undefine MK_ARCH +# Building on Windows with MSYS2 +export MSYS_VERSION = $(if $(findstring Msys, $(shell uname -o)),$(word 1, $(subst ., ,$(shell uname -r))),0) +# $(info The version of MSYS you are running is $(MSYS_VERSION) (0 meaning not MSYS at all)) + +# Sets the extension to use for shared-object files +ifeq ($(MSYS_VERSION),0) +export LIBEXT := so +else +export LIBEXT := dll +endif + # Avoid funny character set dependencies unexport LC_ALL LC_COLLATE=C diff --git a/scripts/dtc/pylibfdt/Makefile b/scripts/dtc/pylibfdt/Makefile index e442d5c24201..314ef91e527b 100644 --- a/scripts/dtc/pylibfdt/Makefile +++ b/scripts/dtc/pylibfdt/Makefile @@ -7,6 +7,8 @@ LIBFDT_srcdir = $(abspath $(srctree)/$(src)/../libfdt) include $(LIBFDT_srcdir)/Makefile.libfdt +LIBFILE := _libfdt.$(LIBEXT) + # Unfortunately setup.py (or actually the Python distutil implementation) puts # files into the same directory as the .i file. We cannot touch the source # directory, so we "ship" .i file into the objtree. @@ -29,16 +31,16 @@ quiet_cmd_pymod = PYMOD $@ rebuild: $(src)/setup.py $(PYLIBFDT_srcs) @# Remove the library since otherwise Python doesn't seem to regenerate @# the libfdt.py file if it is missing. - @rm -f $(obj)/_libfdt*.so + @rm -f $(obj)/_libfdt*.$(LIBEXT) $(call if_changed,pymod) - @# Rename the file to _libfdt.so so this Makefile doesn't run every time - @if [ ! -e $(obj)/_libfdt.so ]; then \ - mv $(obj)/_libfdt*.so $(obj)/_libfdt.so; \ + @# Rename the file to $(LIBFILE) so this Makefile doesn't run every time + @if [ ! -e $(obj)/$(LIBFILE) ]; then \ + mv $(obj)/_libfdt*.$(LIBEXT) $(obj)/$(LIBFILE); \ fi -$(obj)/_libfdt.so $(obj)/libfdt.py &: rebuild +$(obj)/$(LIBFILE) $(obj)/libfdt.py &: rebuild @: -always += _libfdt.so libfdt.py +always += $(LIBFILE) libfdt.py -clean-files += libfdt.i _libfdt.so libfdt.py libfdt_wrap.c +clean-files += libfdt.i $(LIBFILE) libfdt.py libfdt_wrap.c From patchwork Sun Apr 30 01:29:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775303 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=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=krPv+gqa; dkim-atps=neutral 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 (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Q882d07msz1ydX for ; Sun, 30 Apr 2023 11:31:53 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 9A50C861CC; Sun, 30 Apr 2023 03:30:37 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="krPv+gqa"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 00CB585BFB; Sun, 30 Apr 2023 03:30:20 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x12a.google.com (mail-il1-x12a.google.com [IPv6:2607:f8b0:4864:20::12a]) (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 70BE58605F for ; Sun, 30 Apr 2023 03:30:17 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x12a.google.com with SMTP id e9e14a558f8ab-329326b4f10so2644545ab.2 for ; Sat, 29 Apr 2023 18:30:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818216; x=1685410216; 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=6ArM4BYGeSGVxqcCwONLXocnodZPEl/Q40QIOu/z57s=; b=krPv+gqa/3Bnsi1LrNNvl47889J18M67VxFf5w6pNXRZPVCcB+pgIgnrCYvRttUIch bfcsPnaCFM7tJYGLCdVOFwFhFk2q3/JQiEmahnY4qQfzQUtfiWLASKajwYtORlhWkqJv 7fkaI4HXfCVZFktLPAifCbVQrWh0po+GpjwWk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818216; x=1685410216; 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=6ArM4BYGeSGVxqcCwONLXocnodZPEl/Q40QIOu/z57s=; b=A4g8ALVQ12TNU8u97aw+oRkEbe0hMwcBpiLJRfU86HCzj1m8jcCSDWKuwxawIwRbqi a+51QSR3AmNSZ8zCfSfhoa7XuNP19FiaxQUFVtHlACN4Vxtf+z7ugRiyUCO05h/GrGht FleNIDhf/UHTyJy5vDACZaHtYEygv1JA7AM+Zd0KkZg9wKYhGpkPDsfRfQ1/TiPl8g7h eqtEa8V593u81humsf+yA5mZTtaJAtX2iTH1ESIrq9R+23kbRIxUJThChWK/Q1mGVBgZ UEuStaBmZENG0hfZ8YQkuvbFRPJKi08UovsdZ0jpLDS7d6lFA6fdtxZ/NCb+wTtEIrlt j3Sg== X-Gm-Message-State: AC+VfDyfneX92Ok26x30SpcR7XaK+W1SRJkZ/Qdh031FekzVHfXdJHhv ZEoVRi8ljR6WiRTFTnRzknrjv2PjT5jvCFcF22g= X-Google-Smtp-Source: ACHHUZ4o19KisdSyAoiptH2GnDI14eaGCbFxpWbDXfWVDOWSb2UYQaCe5/sLmB+EO/q6BMk5cRg5Rw== X-Received: by 2002:a5e:dd03:0:b0:760:a363:4e51 with SMTP id t3-20020a5edd03000000b00760a3634e51mr6316512iop.18.1682818216078; Sat, 29 Apr 2023 18:30:16 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:15 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 06/30] Fix Makefile warning about parallel targets Date: Sat, 29 Apr 2023 19:29:39 -0600 Message-ID: <20230430013003.1047454-7-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 These targets are not really parallel; they are handled one at a time when invoked by other rules. Some recent versions of make (e.g. on MSYS2) give a warning about this. Split out the rules to avoid the warning. Signed-off-by: Simon Glass --- (no changes since v1) tools/Makefile | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/tools/Makefile b/tools/Makefile index 38699b069d63..22ae5c30351f 100644 --- a/tools/Makefile +++ b/tools/Makefile @@ -263,7 +263,16 @@ HOSTCFLAGS_sha512.o := -pedantic -DCONFIG_SHA512 -DCONFIG_SHA384 quiet_cmd_wrap = WRAP $@ cmd_wrap = echo "\#include <../$(patsubst $(obj)/%,%,$@)>" >$@ -$(obj)/boot/%.c $(obj)/common/%.c $(obj)/env/%.c $(obj)/lib/%.c: +$(obj)/boot/%.c: + $(call cmd,wrap) + +$(obj)/common/%.c: + $(call cmd,wrap) + +$(obj)/env/%.c: + $(call cmd,wrap) + +$(obj)/lib/%.c: $(call cmd,wrap) clean-dirs := lib common From patchwork Sun Apr 30 01:29:40 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775304 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=jd/lNKKu; 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 4Q882v3sr7z1ydX for ; Sun, 30 Apr 2023 11:32:07 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id F36DB861C9; Sun, 30 Apr 2023 03:30:38 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="jd/lNKKu"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 5FA4186103; Sun, 30 Apr 2023 03:30:21 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x132.google.com (mail-il1-x132.google.com [IPv6:2607:f8b0:4864:20::132]) (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 70BE38617D for ; Sun, 30 Apr 2023 03:30:18 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x132.google.com with SMTP id e9e14a558f8ab-32b102ca487so10481445ab.2 for ; Sat, 29 Apr 2023 18:30:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818217; x=1685410217; 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=Zh6uDDXW3jZC5kSHT31DBIBFO/SDIPuOm5liTD/wgH8=; b=jd/lNKKut1phTuiOm2GN1h8TiS5id4s+fqp2E6YMaN7ai50k7dQlXTesDHXVM9KIQ9 oYwR3P63Ap1RgnaZy2ugdp/L03nR4IE4rx4kgbgZ+eldZB2F7CHWQ/+rztCOGNxE9Wg1 aNEVzkPf78o2LcJZ+0KzZg5C7RpEG3DF1VSak= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818217; x=1685410217; 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=Zh6uDDXW3jZC5kSHT31DBIBFO/SDIPuOm5liTD/wgH8=; b=DNDybnBEc9xU4OziePsesEBy+rHo8xlJ1szWrCDa5TsDs8yLvShUPkHsyQcW2YVGwz NvxgVdL2x/HyFFSwuJYBRReBcqGW3fWo+Ho4kTy62cTOjIWxlOr/QqpvlZk1BfBIJNBL bmdKoGWzSGL9pn72nUiIXLe4jy5+dYFKsbSx8Xi6Is6f8x/S46QmOqnBxT3Q3ZKMbY6E 3zcrntjZ7/WJQr/u7e1JjIbdu0KrhYnRC3LEfVW+M3XjyvZg9GcBpUBH6v4TemzKJZR+ HHubI/q6LZEsa7zZIdSyygq9CmN72c2BuLmwfPWkOZtgS/mgJpU0g6vII0l9SvBOpSmf bSGw== X-Gm-Message-State: AC+VfDxXp43b5RsAhWh5EcB/vS/L7vexzGwR5JAf8AcMINRy03c7e8af rTL885uxItfM43+ojEM9fZx35n2p2VB2FOcz3hE= X-Google-Smtp-Source: ACHHUZ6/grEEzwdkVC2WB/qi6TjRa4JmQ85stKYc52QZJOyDgsGhSTExj+kDQomhopVeLTAcIXKz1g== X-Received: by 2002:a92:d14c:0:b0:329:577a:3d13 with SMTP id t12-20020a92d14c000000b00329577a3d13mr7004938ilg.1.1682818216971; Sat, 29 Apr 2023 18:30:16 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:16 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass , Joe Hershberger , Marek Vasut , Stefano Babic Subject: [PATCH v2 07/30] mkimage: Correct checking of configuration node Date: Sat, 29 Apr 2023 19:29:40 -0600 Message-ID: <20230430013003.1047454-8-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 This returns a negative value on error. Update the logic to detect this and avoid a segfault when the node is not found. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) tools/image-host.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/image-host.c b/tools/image-host.c index 4a24dee8153c..e4e44e33badd 100644 --- a/tools/image-host.c +++ b/tools/image-host.c @@ -1336,8 +1336,10 @@ int fit_check_sign(const void *fit, const void *key, int ret; cfg_noffset = fit_conf_get_node(fit, fit_uname_config); - if (!cfg_noffset) + if (cfg_noffset < 0) { + fprintf(stderr, "Configuration node not found\n"); return -1; + } printf("Verifying Hash Integrity for node '%s'... ", fdt_get_name(fit, cfg_noffset, NULL)); From patchwork Sun Apr 30 01:29:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775305 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=DGxrDvFz; 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 4Q88390HX2z1ydX for ; Sun, 30 Apr 2023 11:32:21 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 6480C861EF; Sun, 30 Apr 2023 03:30:44 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="DGxrDvFz"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id D1CAB86161; Sun, 30 Apr 2023 03:30:21 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x133.google.com (mail-il1-x133.google.com [IPv6:2607:f8b0:4864:20::133]) (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 47E4385C9B for ; Sun, 30 Apr 2023 03:30:19 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x133.google.com with SMTP id e9e14a558f8ab-32a62613a69so2781425ab.2 for ; Sat, 29 Apr 2023 18:30:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818218; x=1685410218; 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=mpIGYsg8sWpAsQXE/AFXjatRO/HnqEZ3bh48FMNBtGM=; b=DGxrDvFz9nyHfg6wvifXIMKkay7W+O0HxDwGyM3mFAauopc2ndnILHRfE2mGPHXuKg L0H021chQfuEOV54/xXyoxDk/1rF2pwUsQKSO7IhhzsQF9Nx1iUPBqFJTTuCeBgMw5Yh m0GAeccIQRY5XYhMRtSrk4OggxA3NoDYKNnaE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818218; x=1685410218; 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=mpIGYsg8sWpAsQXE/AFXjatRO/HnqEZ3bh48FMNBtGM=; b=OSOB1CQ8pHUt7anll/oRP9M/PC1sr2fEKUAZ2a18OVmYfAJ3niBMrAKWTh2AXrFh0t y7gLhHNoehyDEyXgxN1kQSU5bjbXDKX+poM0TQ0FQHNKNEVqw8Dr71BsoBrqBIaHDE2i sBydObNXhFb5WmKEws1+5jYEfitdXlepa4Cef56evsUtiU2DdKY1l9XEGwVOTlA3221G WE74nyAy8j3vc5hr5UhmbUJ52ohOFcY5MOqsMCZ0M21mqwGu8mAyc9Bv1XVGy1qIueUL gKPxof0zdj75nBvtG3knjFK6SelEWmUJhknuNouL0vSfiaCGsBgbI+0Nt+xhN48Ei8kG orCg== X-Gm-Message-State: AC+VfDwzijabgk68Ags1xqj4js+A6UDOGsdfurbItcr860I4GrlDlkA7 3cy4sEr68r74x0u5H/TqLaQzwtq5uD7bxant3XY= X-Google-Smtp-Source: ACHHUZ7UMy7oXTs6HSMg4Fy49rWpVI6RL2LImL/uv2ClpyYreftB3A3BawAl+7XibBGQxjvwS1qzlg== X-Received: by 2002:a6b:ce09:0:b0:760:ee9e:c78d with SMTP id p9-20020a6bce09000000b00760ee9ec78dmr6331829iob.21.1682818217812; Sat, 29 Apr 2023 18:30:17 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:17 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 08/30] sandbox: Drop dead code from Makefile Date: Sat, 29 Apr 2023 19:29:41 -0600 Message-ID: <20230430013003.1047454-9-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 This is not used, since the same code appears in cpu/Makefile Drop it. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) arch/sandbox/Makefile | 7 ------- 1 file changed, 7 deletions(-) diff --git a/arch/sandbox/Makefile b/arch/sandbox/Makefile index a335f8acfde6..f6cf859f249c 100644 --- a/arch/sandbox/Makefile +++ b/arch/sandbox/Makefile @@ -4,10 +4,3 @@ head-y := arch/sandbox/cpu/start.o arch/sandbox/cpu/os.o head-$(CONFIG_SANDBOX_SDL) += arch/sandbox/cpu/sdl.o libs-y += arch/sandbox/cpu/ libs-y += arch/sandbox/lib/ - -# sdl.c fails to compile with -fshort-wchar using musl. -cmd_cc_sdl.o = $(CC) $(filter-out -nostdinc -fshort-wchar, \ - $(patsubst -I%,-idirafter%,$(c_flags))) -fno-lto -c -o $@ $< - -$(obj)/sdl.o: $(src)/sdl.c FORCE - $(call if_changed_dep,cc_sdl.o) From patchwork Sun Apr 30 01:29:42 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775306 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=PLVuiU9M; 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 4Q883Q66lJz1ydX for ; Sun, 30 Apr 2023 11:32:34 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 5A09E861FF; Sun, 30 Apr 2023 03:30:46 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="PLVuiU9M"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id AF4A385D10; Sun, 30 Apr 2023 03:30:22 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x12a.google.com (mail-il1-x12a.google.com [IPv6:2607:f8b0:4864:20::12a]) (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 29C6285CD8 for ; Sun, 30 Apr 2023 03:30:20 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x12a.google.com with SMTP id e9e14a558f8ab-329560b1994so2773305ab.3 for ; Sat, 29 Apr 2023 18:30:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818218; x=1685410218; 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=Tlfk21//umObS/yeXZEH0S636U/FEI6PihU89ZoN2l4=; b=PLVuiU9MFm9p5jCjBEFGsxKt0E5j7KCciGqf+OUQblXmXcqYehw9+0ej3Kme6V8/Gz qpDF+Ry7nVDz986CvE+HEVuGkVy/B1eb75IwooCikcymom+xKpcGJc8X0yEau2Njyf/8 eX6DEsIJCz0yfzuaRjpFt2wSh9LPi6mMnJtUU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818218; x=1685410218; 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=Tlfk21//umObS/yeXZEH0S636U/FEI6PihU89ZoN2l4=; b=h5XybwIsbpMv9kdNv934JPKNpBSc7V9KTFLHW3bdc51TX+HPKyMYxVQOp5/HN8/IkX T/+BPQNq1fiB7jikjbs3hvjmZ+NyH1mxaqqOS1P6gWMm1TuuR5Mpg2MYGCbBQnrPpd9U JXdgyEYTuqOMd6OoUFwBF8o+i2oD/owj4WvgNXff8MPrCqXZZGSn7lA3VWDu2LO3yt10 kFl4fwAVMqpCj2qRFIdrqGjNLimXCGHiZuT1z/XK2gIjNQX0VkSmKEovHqetbSSoNXHd REZ2CljhEBRHxd1xD9u0uk8LuDebrCcs5P41rmTzX0FZcT4abDofxw/SbxoOUZkhp7S+ 2J9g== X-Gm-Message-State: AC+VfDwnb7daNw5/d4ckwdD/xjqIKJEf6T66oxbyS3moWDkCMGcaZmdC JpejveOQfVn7lNMM0CHmMrMuMmxiKkxqbOkmvdw= X-Google-Smtp-Source: ACHHUZ5bnABBDWMkdc+rPBkn8jb6Q214m4BwDjgOWEGAm8POZSxRqb6He88u7KpvBIV1ECrzO+wMSg== X-Received: by 2002:a5d:9286:0:b0:766:41fa:e26f with SMTP id s6-20020a5d9286000000b0076641fae26fmr6408647iom.10.1682818218676; Sat, 29 Apr 2023 18:30:18 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:18 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 09/30] sandbox: Correct SDL.h header inclusion Date: Sat, 29 Apr 2023 19:29:42 -0600 Message-ID: <20230430013003.1047454-10-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 We rely on sdl-config to provide the include directory for this header file, so should not add the include directory in the C file. Drop it so that this works as expected on Windows. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) arch/sandbox/cpu/sdl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/sandbox/cpu/sdl.c b/arch/sandbox/cpu/sdl.c index 2c570ed8d164..31d3e9c32dec 100644 --- a/arch/sandbox/cpu/sdl.c +++ b/arch/sandbox/cpu/sdl.c @@ -7,7 +7,7 @@ #include #include #include -#include +#include #include /** From patchwork Sun Apr 30 01:29:43 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775307 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=Nx9zUzZr; 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 4Q883h6pTMz1ydX for ; Sun, 30 Apr 2023 11:32:48 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 42704861E7; Sun, 30 Apr 2023 03:30:48 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="Nx9zUzZr"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 85BAF86161; Sun, 30 Apr 2023 03:30:23 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-io1-xd31.google.com (mail-io1-xd31.google.com [IPv6:2607:f8b0:4864:20::d31]) (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 F1AFF8605F for ; Sun, 30 Apr 2023 03:30:20 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-io1-xd31.google.com with SMTP id ca18e2360f4ac-76089de42e6so108553639f.0 for ; Sat, 29 Apr 2023 18:30:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818219; x=1685410219; 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=Fn3FYG6TO74PsNtPaxvbvVATn+m3osfrQQciZBiW5Sw=; b=Nx9zUzZrjkBGWeepBYF1UVUh5OSkpwDQzdPkJXkMRo1qZCRTzrQ1b3XlwpwF3MmV0i LI/WHZ6UPNOWovUuApCYXsLulYv2P/OmPUJoIyl5chjiRVkSu1BiiqAAGP4T4yAF5zpQ lDwpd50W/YFFXMakp9ra4Yh+/DhWZpzK1aj5o= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818219; x=1685410219; 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=Fn3FYG6TO74PsNtPaxvbvVATn+m3osfrQQciZBiW5Sw=; b=UPvse7IHL6hFQTVyghsnPlYJ6+8EQUtNyHEDcRu86ZjgcUMGjv2WUxHLgkv46aOw/A 9FEgz0T4F/6+//n46EJYk5yYVO9F0/lcXGkwRIQ7rWnnucPv7GNstMHD5K2skMLpdnEI /TDhm36++m0irFTTReXkKDwEX+k5xXE+py6AV4P44Lj9tJa1kFTTt6O8nqnGDtn+zpRq /0c09OZx87V7GyJl/uYv+ZTk8avUB4xz6CSWUVzu2q8arZ1SEkRhbyYoBHeT1efG7bRC D9VQCBNBH+ZBMQk0u3XXlJNOrv38BtM7UqrXv2Q+rFGuBXfeSI+t2repYPp6XegsMdPl GEkw== X-Gm-Message-State: AC+VfDzAB3sbR1kOAolTNCy2glGmK1AOk+WTzU/LQTE3ScHZFh40URrR JwTPnHzaOrS3fE4Ns4hyUDKjiry96JvUzOQ5LT8= X-Google-Smtp-Source: ACHHUZ5YPy+Jd6B1KyosX2ee3MwmII6xrWJ8w78N0DhgppPXCSEU97XZ9iogUGDRpinQ80FPVNo6mg== X-Received: by 2002:a5d:9955:0:b0:750:c68e:f028 with SMTP id v21-20020a5d9955000000b00750c68ef028mr7275542ios.9.1682818219476; Sat, 29 Apr 2023 18:30:19 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:19 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 10/30] sandbox: Include errno.h in the test header Date: Sat, 29 Apr 2023 19:29:43 -0600 Message-ID: <20230430013003.1047454-11-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 this so that the header file can used without first including the errno.h header. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) arch/sandbox/include/asm/test.h | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/sandbox/include/asm/test.h b/arch/sandbox/include/asm/test.h index e482271fe975..86968ea6d345 100644 --- a/arch/sandbox/include/asm/test.h +++ b/arch/sandbox/include/asm/test.h @@ -8,6 +8,7 @@ #ifndef __ASM_TEST_H #define __ASM_TEST_H +#include #include #include From patchwork Sun Apr 30 01:29:44 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775308 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=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=oVAAmxel; dkim-atps=neutral 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 (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Q883z6w4Dz1ydX for ; Sun, 30 Apr 2023 11:33:03 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id BC0AD861F4; Sun, 30 Apr 2023 03:30:49 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="oVAAmxel"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 5C87A85C9B; Sun, 30 Apr 2023 03:30:24 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-io1-xd31.google.com (mail-io1-xd31.google.com [IPv6:2607:f8b0:4864:20::d31]) (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 BB53486103 for ; Sun, 30 Apr 2023 03:30:21 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-io1-xd31.google.com with SMTP id ca18e2360f4ac-76655852953so26880439f.0 for ; Sat, 29 Apr 2023 18:30:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818220; x=1685410220; 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=KG86faSXhjpyPSfJPQq2aW9UjuNDh9uCWbhY9qzejWw=; b=oVAAmxelSoxqmgySyD0/gcw/kwtyFeQCTM8Pv+190nM66RdKhE+WVWihoQ/DZrDwGU W5mfTc26NEaFRn0elISJb0pDofRK/qMukLahccKNW0EJN6heSgG9C6BEbEDheTq/3uhI pcWkzMJGG2kHFkPBx7C4EFdKDZGjGWmtMF+cY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818220; x=1685410220; 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=KG86faSXhjpyPSfJPQq2aW9UjuNDh9uCWbhY9qzejWw=; b=XnGqaMD/gNtj+fAIc2YyxDF1GDu3uUZh+1PEHq1eTPJJ7lFyLAeWJIch9pMdNS/uOz 6FJo2bOxsLLvKuRGPB037BZAPNCWL8CQHi2W0ePLGL1jUdQLy1xGeujT/OiIo2gDGbsK KuubfRprpSEGChFiWaefmP1yPMNSNvZfPftMhWJnqnEv/B5836nI+B2T/VP7oClufTts bB28vkO521elej5F2oIh1UMZVduDTvqZjWvERFvMs/mADoJT4uJbNyV1cBRB73OTJE39 +B3bMCs+7we3D86Dbevi1XnC7bx4FfV5zTEASFcwKrVTF3Ck9Ub6xRdzLB39U6k9ZjtP h7nQ== X-Gm-Message-State: AC+VfDxrWu8FlWIgXczvDYGMjUxFqZ2ZWtuGUX6yW+q/iDy38sFYhzT1 BaIH6OOfcrS1K56zLxfigw16TQiCas677ltvk8g= X-Google-Smtp-Source: ACHHUZ5Nx+iG26cusiSuZoe/zDN532GW8cIvOxviGWhKwzGoYeDVhi8vftWRIFdF2//eAKRpbUuJQQ== X-Received: by 2002:a05:6e02:104:b0:32a:82e9:23c1 with SMTP id t4-20020a056e02010400b0032a82e923c1mr7142901ilm.21.1682818220310; Sat, 29 Apr 2023 18:30:20 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:20 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 11/30] sections: Drop use of linux/types.h Date: Sat, 29 Apr 2023 19:29:44 -0600 Message-ID: <20230430013003.1047454-12-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 Use 'unsigned long' instead of 'ulong' so this file does not need to include the linux/types.h header file. This allows it to be built with MSYS2. Signed-off-by: Simon Glass Reviewed-by: Tom Rini Reviewed-by: Bin Meng --- (no changes since v1) include/asm-generic/sections.h | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/include/asm-generic/sections.h b/include/asm-generic/sections.h index 267f1db73f23..4ed9a8478cc5 100644 --- a/include/asm-generic/sections.h +++ b/include/asm-generic/sections.h @@ -8,8 +8,6 @@ #ifndef _ASM_GENERIC_SECTIONS_H_ #define _ASM_GENERIC_SECTIONS_H_ -#include - /* References to section boundaries */ extern char _text[], _stext[], _etext[]; @@ -71,7 +69,7 @@ extern char __image_copy_end[]; extern void _start(void); /* - * ARM defines its symbols as char[]. Other arches define them as ulongs. + * ARM defines its symbols as char[]. Other archs define them as unsigned long */ #ifdef CONFIG_ARM @@ -86,13 +84,13 @@ extern char __rel_dyn_end[]; #else /* don't use offsets: */ /* Exports from the Linker Script */ -extern ulong __data_end; -extern ulong __rel_dyn_start; -extern ulong __rel_dyn_end; -extern ulong __bss_end; -extern ulong _image_binary_end; +extern unsigned long __data_end; +extern unsigned long __rel_dyn_start; +extern unsigned long __rel_dyn_end; +extern unsigned long __bss_end; +extern unsigned long _image_binary_end; -extern ulong _TEXT_BASE; /* code start */ +extern unsigned long _TEXT_BASE; /* code start */ #endif From patchwork Sun Apr 30 01:29:45 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775309 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=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=ZoqfFuiS; dkim-atps=neutral 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 (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Q884G40LXz1ydX for ; Sun, 30 Apr 2023 11:33:18 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 36D9286214; Sun, 30 Apr 2023 03:30:51 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="ZoqfFuiS"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 291F886181; Sun, 30 Apr 2023 03:30:24 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x12a.google.com (mail-il1-x12a.google.com [IPv6:2607:f8b0:4864:20::12a]) (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 A1F958615D for ; Sun, 30 Apr 2023 03:30:21 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x12a.google.com with SMTP id e9e14a558f8ab-32f397b44dcso30560235ab.1 for ; Sat, 29 Apr 2023 18:30:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818221; x=1685410221; 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=wOVADWW5W88Dp4u3eE52x2+T7TBzAo2v91lX4t3M07g=; b=ZoqfFuiSxmAd74IyEtHuIAMJ4+VXTaVxVw37jKCL36Yf+I6fQh1jn7mqR8tU4cn1X0 qJmwXJEGju7dPfGGepr8Ez6QvTmsfPlyI2gxpRXy5+xSXn10LKtdaPOBJwrQPUfkNuzw SfAKe76fuNrZIOnzzotbSUOlqH0Y4kmrt1sqY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818221; x=1685410221; 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=wOVADWW5W88Dp4u3eE52x2+T7TBzAo2v91lX4t3M07g=; b=TY7WPMX+oXCepMYfdLjfanayYC8A72pX3LWIRrbBuTgE6+IDcnbWdyqHErvn4cb0KU kQysnV2BIUPqUtdHdd8OiFUehNy1ZHpznk6dITAUw7JKWiQcd6E7RiYzV4tA6dJjDQ+6 Rf/7pMye6uvxDIulhNg2sphVjbAda437EseVKCWbWz6is/SNmHLxPnqXNyIJZp059/8H TiowjttHGMI7cit86TFcAZnw9hIyAFMIt7mJyHNH4pnJ89DTYK9YD6WoP5FAwV7yyek7 uL+ilWjjKid640FI+duSObCYfkPJM+fK6872ROvnDlg+xh+Af0zZVDwdHFJlaTLRdvO0 /Kkg== X-Gm-Message-State: AC+VfDxlKMSvtXHfo+bVzmGseQKSNpoK6SK6TNTD2l3Aye1JwBPiKo+R m1NhjxRFKafECTa7PU1ghJYp4H2HiOP9DGgTcmA= X-Google-Smtp-Source: ACHHUZ4rLOc5sj7PhkuRWOlUuAP+USb6r3qeGF7XXXXFav0w0GFWB2AnQKIKOn3MWeLgVjLt6UEvxg== X-Received: by 2002:a05:6e02:1ca4:b0:32a:f44e:b869 with SMTP id x4-20020a056e021ca400b0032af44eb869mr9884705ill.5.1682818221131; Sat, 29 Apr 2023 18:30:21 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:20 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 12/30] sandbox: Drop incorrect inclusion of linux/types.h Date: Sat, 29 Apr 2023 19:29:45 -0600 Message-ID: <20230430013003.1047454-13-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 This header file should only be included in U-Boot standalone files, not those built in the Linux environment. When not building for Linux, the header file does not exist, except in the U-Boot tree. In any case, it should not be used. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) arch/sandbox/cpu/os.c | 1 - include/os.h | 2 -- 2 files changed, 3 deletions(-) diff --git a/arch/sandbox/cpu/os.c b/arch/sandbox/cpu/os.c index 9e93a0fa571f..e76568ebdd32 100644 --- a/arch/sandbox/cpu/os.c +++ b/arch/sandbox/cpu/os.c @@ -26,7 +26,6 @@ #include #include #include -#include #include #include diff --git a/include/os.h b/include/os.h index 968412b0a822..561ef1264b13 100644 --- a/include/os.h +++ b/include/os.h @@ -11,8 +11,6 @@ #ifndef __OS_H__ #define __OS_H__ -#include - struct rtc_time; struct sandbox_state; From patchwork Sun Apr 30 01:29:46 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775310 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=JtYMu8j0; 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 4Q884Y4MY9z1ydX for ; Sun, 30 Apr 2023 11:33:33 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 7A1F586225; Sun, 30 Apr 2023 03:30:52 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="JtYMu8j0"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 22EBC861A3; Sun, 30 Apr 2023 03:30:26 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x136.google.com (mail-il1-x136.google.com [IPv6:2607:f8b0:4864:20::136]) (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 66D0485CD8 for ; Sun, 30 Apr 2023 03:30:23 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x136.google.com with SMTP id e9e14a558f8ab-3294eacb2f6so2629575ab.3 for ; Sat, 29 Apr 2023 18:30:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818222; x=1685410222; 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=ckFO3iObtE8Jdz5T6dY0eJoT1TR1bq9buQjRyoLgc9Y=; b=JtYMu8j00/VqbykaiWby+ZlKaJdhW6XzQknAmy2b8vTrR7WqQpgDOy4AHyparhBShg 5EQgANKU80Q638qKZiRSoOUttXkuTOGHZLtroWx7U7UTQugWhbiVhaUnAlnFl7mVuhbq PKvg7O0S/OOUWejwhG6tJq22inTZxZz5hO5To= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818222; x=1685410222; 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=ckFO3iObtE8Jdz5T6dY0eJoT1TR1bq9buQjRyoLgc9Y=; b=IbsDLVPgOPvshZ0nHluuNmbSHIcAl9Ox/tz4tn/+7NUl2fqK5u4K+M9+cl9GnIyR9j ebrekyBddt7NIR20w0tUPOtg9P6CnbUoIsMFPm8Z1JUzh6UzNPn+f3ZNRDcAJcY+7XNU MnfYzX2omAZcFNR1FLa7tGNdqkc5QEqmWiPFcX9BU2OAew4qCjwxSjD38DMJlgC3EFBo JhDnse+7itl6keh14iNgZFzlTUvayaoBd0aD9bAaPQM+neHnlNgEEH6Q4PF0WqKaidh3 hyN8QPQBZ6phyWDv5X416QEo02ntdHa1iNDApagw4fIuCQ9oZc9JSq3P2fh5uy429wIi yssw== X-Gm-Message-State: AC+VfDxYLZD2zADSTPBs/sK12iaXwbep+TGi60itDynmeR1rw/R9EOPQ 6OlZGJ3d8fumuAg7SAiAFrPo+w2nzYUN5ILcKbI= X-Google-Smtp-Source: ACHHUZ5vZjHhWKUACY2uZW3yolrgMGNRuTzjtNKuxkgJ84QH0rPXXtyP0z4Yp94TuzVlPmP96cWbOg== X-Received: by 2002:a92:6e02:0:b0:32c:9c5e:900c with SMTP id j2-20020a926e02000000b0032c9c5e900cmr6403404ilc.8.1682818222007; Sat, 29 Apr 2023 18:30:22 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:21 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 13/30] sandbox: Drop inclusion of os.h in sscanf.c Date: Sat, 29 Apr 2023 19:29:46 -0600 Message-ID: <20230430013003.1047454-14-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 There is no need for this file and it should not be included unless sandbox is being used. Drop it. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- (no changes since v1) lib/sscanf.c | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/sscanf.c b/lib/sscanf.c index 4c35c035fe10..b79f6d79255c 100644 --- a/lib/sscanf.c +++ b/lib/sscanf.c @@ -17,7 +17,6 @@ #if !defined HAVE_LIBC -#include #include #include #include From patchwork Sun Apr 30 01:29:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775311 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=dYStmWbU; 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 4Q884s3MDfz1ydX for ; Sun, 30 Apr 2023 11:33:49 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 3ABAC861F1; Sun, 30 Apr 2023 03:30:54 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="dYStmWbU"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id BF18686154; Sun, 30 Apr 2023 03:30:26 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-io1-xd32.google.com (mail-io1-xd32.google.com [IPv6:2607:f8b0:4864:20::d32]) (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 529758615D for ; Sun, 30 Apr 2023 03:30:24 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-io1-xd32.google.com with SMTP id ca18e2360f4ac-763c3429abaso108100839f.1 for ; Sat, 29 Apr 2023 18:30:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818223; x=1685410223; 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=QOULTIVJOgIQL2/Yje7NDEMDU+i93+d3Ft+CWzE2yvs=; b=dYStmWbUGZ82TSvQ5EHQAaDWq8UhNt+/pqovCxwfophN/PeyIMJgXEzwsfnggiKhgq 06FsaCKbrhHqumrA2wEO1dEv0ReljgSvpYjmaUYK1mDVnl5WFwQ+YWlKJAR9R4PqcZEP u/2B8kMye+AYhTDIST4R1VW19F86AnFrr4GQI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818223; x=1685410223; 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=QOULTIVJOgIQL2/Yje7NDEMDU+i93+d3Ft+CWzE2yvs=; b=Fer/W/1zFYvjfS/o9QjuwpCIVj8px1g9WUoW6JQTvqXbJpPkXljlyHKg5rfYdS8AIL uI6LtH9zw+hDwTudOeXLMFNp3ptLWC7wHIWMQlbipUOQBmnjrp9if73HAm3oLigfy558 h3ZwdJSkj9V37r0qRVGW3Pp4Kp9hqcwzPH95zxMxg1NesxrO/KoHvWcscPLmdmOtXxvT WgKCJrfU2a9qQKVDalrZSc1OKr7a48kwdswtcbFwVyBJ+XrU6xlRjUdfLomnGanfBQOy acUunrqa0jSjJPjKsDG044jENzWIWXr0vI6j2TPnbZKtyxnB3w59dpVb2KzGNBO6UYsP dIMg== X-Gm-Message-State: AC+VfDzk8jrTuyiHT+iEZAngo5YG9q/Mbh+cY8JS4VhvzMUqQ7WzoQR2 NEbV+OpsZv5eaX06EaEeckfhBFvQk8IiT1axJFg= X-Google-Smtp-Source: ACHHUZ5j3lrwni31YL4AnTIhVhyA1q0b24CV/UW8tnp3fxOYkstejkNxAevDnNfQjvyFi9NC7Y5A5w== X-Received: by 2002:a6b:5c0a:0:b0:760:ec21:a8af with SMTP id z10-20020a6b5c0a000000b00760ec21a8afmr8741927ioh.0.1682818222853; Sat, 29 Apr 2023 18:30:22 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:22 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 14/30] test: Avoid strange symbols in the assembler file Date: Sat, 29 Apr 2023 19:29:47 -0600 Message-ID: <20230430013003.1047454-15-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 This works correctly on Linux with ELF but not on Windows with PE, since it creates assembly symbols with invalid names. Use the lowest/highest valid characters instead. This should still work correctly, since we have no tests starting with $ and none starting with 'zz' at present. Signed-off-by: Simon Glass Reviewed-by: Bin Meng Tested-by: Bin Meng --- Changes in v2: - Update comment and use zz to make it less likely we have a problem include/test/test.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/test/test.h b/include/test/test.h index 838e3ce8a8f3..fd07238a7b0b 100644 --- a/include/test/test.h +++ b/include/test/test.h @@ -126,9 +126,9 @@ struct unit_test { #define UNIT_TEST_SUITE_COUNT(_suite) \ ll_entry_count(struct unit_test, ut_ ## _suite) -/* Use ! and ~ so that all tests will be sorted between these two values */ -#define UNIT_TEST_ALL_START() ll_entry_start(struct unit_test, ut_!) -#define UNIT_TEST_ALL_END() ll_entry_start(struct unit_test, ut_~) +/* Use $ and zz so that all tests will be sorted between these two values */ +#define UNIT_TEST_ALL_START() ll_entry_start(struct unit_test, ut_$) +#define UNIT_TEST_ALL_END() ll_entry_start(struct unit_test, ut_zz) #define UNIT_TEST_ALL_COUNT() (UNIT_TEST_ALL_END() - UNIT_TEST_ALL_START()) /* Sizes for devres tests */ From patchwork Sun Apr 30 01:29:48 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775312 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=hdhmaGAP; 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 4Q88581PSdz1ydX for ; Sun, 30 Apr 2023 11:34:04 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id AA2E88623A; Sun, 30 Apr 2023 03:30:55 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="hdhmaGAP"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id E12CA861A3; Sun, 30 Apr 2023 03:30:27 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x129.google.com (mail-il1-x129.google.com [IPv6:2607:f8b0:4864:20::129]) (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 5E7B386192 for ; Sun, 30 Apr 2023 03:30:25 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x129.google.com with SMTP id e9e14a558f8ab-32943f2063cso2852715ab.0 for ; Sat, 29 Apr 2023 18:30:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818224; x=1685410224; 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=m2chrqlXkYPorRdnIHzFAuuLwSBABPy3GX0B6oh1fTE=; b=hdhmaGAPhhOnb7FjbddSQ40uiU4upMJYCG4p7EUw87IbEkNx60LKPyW0A27HKp4c0B mDNtCG3YanaqSprXwIcgskGLAbGdkpWWEBtMOUJtH1yiy8LfsqrI+OI9RqAa6EbrtFXs qgXxgj1atsrUbLNdy47gYmnv+renttnTpRbek= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818224; x=1685410224; 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=m2chrqlXkYPorRdnIHzFAuuLwSBABPy3GX0B6oh1fTE=; b=JLsV88z0KsMX0soKP1pcht034KWUQPPe3Fc/ThMMkeSqRuRDLX1CukvZOd7zBad42y WWjgcDJkkCH48N2KdT2osGhkiahq3/Qt8GUG7Y1ntAcJGLvHHd0bYA0rmu8a40EDPMxU /ou9jNJFmfmtSQ7mhrje1WEmoj2oke0ZGoJOb8BHG1GnFaPBJBTPkbcmgd26pfpiPjpy tQdxAhG9MGuNqtOV0tEmybnWzE9pTF/CfciA3HQguFg3k3mk2cxUnumbZYbCF9kPNnjH vMvABwBMa9tS5E9V7qJJJpaqlsakavD594TU9/HQmA0S+O1ZDDrcIcnhr1NC6vXNqnsD wIsA== X-Gm-Message-State: AC+VfDw5rWcqmd+LTcC+vjaCtONtPgt+7lKzWasnB8BKL28vAB9+cG0N QJVL7nDZO2jzQSuYbTPeCqEJpOWjppTAfIwOJHI= X-Google-Smtp-Source: ACHHUZ4v4GNb5PyAShkpBkQ7QXG8YaDvU8+uktssEXSs9+XG97N8cq+gQL6p7Ya7UaTjYBgqfE/8yQ== X-Received: by 2002:a92:d445:0:b0:32f:776d:711 with SMTP id r5-20020a92d445000000b0032f776d0711mr3117367ilm.30.1682818223869; Sat, 29 Apr 2023 18:30:23 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:23 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 15/30] ctype: Avoid using a symlink Date: Sat, 29 Apr 2023 19:29:48 -0600 Message-ID: <20230430013003.1047454-16-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 Windows doesn't really support symlinks so fails to build this file. Use a single-line #include instead. Signed-off-by: Simon Glass --- (no changes since v1) include/ctype.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) mode change 120000 => 100644 include/ctype.h diff --git a/include/ctype.h b/include/ctype.h deleted file mode 120000 index 9e43f9c6c6c4..000000000000 --- a/include/ctype.h +++ /dev/null @@ -1 +0,0 @@ -linux/ctype.h \ No newline at end of file diff --git a/include/ctype.h b/include/ctype.h new file mode 100644 index 000000000000..155e3c63e59d --- /dev/null +++ b/include/ctype.h @@ -0,0 +1,6 @@ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* + * Copyright 2023 Google LLC + */ + +#include From patchwork Sun Apr 30 01:29:49 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775313 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=O2jkiKZ6; 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 4Q885R5Dzgz1ydX for ; Sun, 30 Apr 2023 11:34:19 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 2D0058625C; Sun, 30 Apr 2023 03:30:57 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="O2jkiKZ6"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 4EB3085C9B; Sun, 30 Apr 2023 03:30:29 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x12b.google.com (mail-il1-x12b.google.com [IPv6:2607:f8b0:4864:20::12b]) (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 5735985C9B for ; Sun, 30 Apr 2023 03:30:25 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x12b.google.com with SMTP id e9e14a558f8ab-32b1ee270ebso2981415ab.0 for ; Sat, 29 Apr 2023 18:30:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818224; x=1685410224; 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=iwTECLntZ3+n9LnzBIrHR9aNx8Wqgx7oEVwJULnFWrE=; b=O2jkiKZ6RaBxGxUFfuPW+xh4quWElC8/8LKJVWgrpNZ7Gzc0isvW9JDQHSHos2F4R3 a3bGpUJqtRuWkzfp97jb6b3KGh+5VydcsJbiWt7H31e3NRymyso6irjpW2jWTfJf35vD JBVGLCgbEWC/mSEV/tsTxz8aS1Zny3Y1hDlEc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818224; x=1685410224; 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=iwTECLntZ3+n9LnzBIrHR9aNx8Wqgx7oEVwJULnFWrE=; b=R2z/OOcFtA5KkoN9CNdeWvS6l8vX3TLa4KLuYzcR/XwIQ7pRzgm+3mLZn2gWncFre6 F9ev8CTNH5cS2lOoE9WMLj7iuPScQK2G7xzeWBraYOgLCQp1LO1fnA0Eb8THawWngKP9 la9Jh4q/wwKbXhxGsv3DFYt6uPFF+RFD5c8WbABQZdKJeGsENtInpQSZ6+LNCYWQX1QJ r3V459PWgsws6Gro3uHlIZ6BRN6Y0nmmcH6xWWOvk6qUK/N8rHcfZHadLMc3S0Vfxm3g /SruYsqVuWzic7s7ur3QTSwn3TCQCjICTOjhNBn9nW/W+FQ9XqOzsSpU44/tBoG0sZr2 I+JQ== X-Gm-Message-State: AC+VfDwRYCKgmMR+sRqFqBkRYpkk+Lz5Ahka7lWhvTWOaHktpfs2s4iL /Bkz80KZVM8EFXjLLxHNqCpg4iV+xgt3UXf5PuU= X-Google-Smtp-Source: ACHHUZ4dKhCh9+riywivyuCexB31CWym1IgfZMcMPhe0akpp18gbhbzu8AGFZiuLpCVUJwukgh1Ing== X-Received: by 2002:a92:d48a:0:b0:32d:e1ee:bddd with SMTP id p10-20020a92d48a000000b0032de1eebdddmr5558618ilg.1.1682818224744; Sat, 29 Apr 2023 18:30:24 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:24 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass , Masahiro Yamada Subject: [PATCH v2 16/30] Makefile: Disable LTO when not building with gcc Date: Sat, 29 Apr 2023 19:29:49 -0600 Message-ID: <20230430013003.1047454-17-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 For MSYS2 this creates a lot of errors of the form: `__stack_chk_fail' referenced in section `.text' of ...ltrans.o: defined in discarded section `.text' of common/stackprot.o (symbol from plugin) For clang it doesn't work, except with sandbox. Update the dependency to (hopefully) deal with all of that. Signed-off-by: Simon Glass Reviewed-by: Tom Rini --- Changes in v2: - Make LTO depend on !MSYS2 rather than adding another check - Also disable LTO for clang, except with sandbox Kconfig | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Kconfig b/Kconfig index 888b9984ac3b..9ac816abef1c 100644 --- a/Kconfig +++ b/Kconfig @@ -72,6 +72,9 @@ config CLANG_VERSION int default $(shell,$(srctree)/scripts/clang-version.sh $(CC)) +config CC_IS_MSYS + def_bool $(success,uname -o | grep -q Msys) + choice prompt "Optimization level" default CC_OPTIMIZE_FOR_SIZE @@ -121,6 +124,8 @@ config ARCH_SUPPORTS_LTO config LTO bool "Enable Link Time Optimizations" depends on ARCH_SUPPORTS_LTO + depends on CC_IS_GCC || (CC_IS_CLANG && SANDBOX) + depends on !CC_IS_MSYS help This option enables Link Time Optimization (LTO), a mechanism which allows the compiler to optimize between different compilation units. From patchwork Sun Apr 30 01:29:50 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775314 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=Arx0RFq0; 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 4Q885l217Rz1ydX for ; Sun, 30 Apr 2023 11:34:35 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id AD8508628F; Sun, 30 Apr 2023 03:30:58 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="Arx0RFq0"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 2037C8615D; Sun, 30 Apr 2023 03:30:30 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-io1-xd33.google.com (mail-io1-xd33.google.com [IPv6:2607:f8b0:4864:20::d33]) (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 193CF861A5 for ; Sun, 30 Apr 2023 03:30:26 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-io1-xd33.google.com with SMTP id ca18e2360f4ac-7696975338aso8693339f.1 for ; Sat, 29 Apr 2023 18:30:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818225; x=1685410225; 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=yiz6AGFjc/vawfZCscWjXfmsbteRD7pMr+kPgwsRft0=; b=Arx0RFq0CGqTC09XNQmp31QvKSbMWABMnExStkIqhq/g/AELfD4vvU/kVQKHG2K9Xa lL0eJnNdZ6n/83gtIJyFULuEcmiKmjO9BpJmVg6t8Q+gevmxE/MQMlzKk5bLsVgeNC5N 508J2x9D3kltbF/Sm/jOLuC7tS+jN+JTHKmm8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818225; x=1685410225; 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=yiz6AGFjc/vawfZCscWjXfmsbteRD7pMr+kPgwsRft0=; b=aC7CdGQ7LBmeWdooHFmTNVTaNR41gf3kXn9h1r9mmUeVE9tTFpD5A4h44DVUvdJFSu GzFdN2MLUyaPtXY6JcPKczHJZutuLeOeYEIH0FInqJlKvbBcTHMYvM0ZXTX1ZsWyBE1X Fxjnpr+cYrCROvHHfdq/b/AyrKxJw/f+ALsDS+1/TtagEmISwwkBCfKl4kztc4jMD/Fk PQTatipGzBD930ZEWk/TVOtbK1yTB99voJlNtANG4VX9NZeV2AUEr8xIMPK2RYOQgafv 2f086dDVCXsHpkCoLz2uNX5KClOaVMC5HTX/moMJvQFIaOMSjEtYl9Xr1CIxli5x4NUI KlZg== X-Gm-Message-State: AC+VfDx7WGwRuOq3HgssLc4SK3pkK0rAWdICqH2KVHajW8ejx4oRbGF7 l9wESY4mVciFRprx4ig96N3nFWMp9ZI5rOUkAmc= X-Google-Smtp-Source: ACHHUZ4G1bqcr8H+doNfsyqWrDfILtaGjuawhR4ojQWxUhBAAhLIjtbZ+pxD0XUABhs55NVwnIOg7w== X-Received: by 2002:a92:d6c9:0:b0:328:18af:df0 with SMTP id z9-20020a92d6c9000000b0032818af0df0mr6616883ilp.23.1682818225602; Sat, 29 Apr 2023 18:30:25 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:25 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 17/30] Kbuild: Detect including an MSYS2 path Date: Sat, 29 Apr 2023 19:29:50 -0600 Message-ID: <20230430013003.1047454-18-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 source-tree directory is prepended to relative include paths, but this does not work on Windows, where a path may have a drive letter like C: at the start of it. This breaks SDL which includes an absolute path to the header directory to the C flags, e.g. -IC:/msys64/mingw64/include/SDL2 Add this as a special case to leave these absolute paths alone on Windows. Signed-off-by: Simon Glass --- (no changes since v1) scripts/Kbuild.include | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/Kbuild.include b/scripts/Kbuild.include index 62e0207f91b4..411a768a7767 100644 --- a/scripts/Kbuild.include +++ b/scripts/Kbuild.include @@ -205,9 +205,10 @@ clean := -f $(srctree)/scripts/Makefile.clean obj hdr-inst := -f $(srctree)/scripts/Makefile.headersinst obj # Prefix -I with $(srctree) if it is not an absolute path. +# Detect C: (C drive) with MSYS2 # skip if -I has no parameter addtree = $(if $(patsubst -I%,%,$(1)), \ -$(if $(filter-out -I/% -I./% -I../%,$(1)),$(patsubst -I%,-I$(srctree)/%,$(1)),$(1)),$(1)) +$(if $(filter-out -I/% -I./% -I../% -IC:%,$(1)),$(patsubst -I%,-I$(srctree)/%,$(1)),$(1)),$(1)) # Find all -I options and call addtree flags = $(foreach o,$($(1)),$(if $(filter -I%,$(o)),$(call addtree,$(o)),$(o))) From patchwork Sun Apr 30 01:29:51 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775315 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=NVTcYSNS; 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 4Q88622tdTz1ydX for ; Sun, 30 Apr 2023 11:34:50 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id E66DC86378; Sun, 30 Apr 2023 03:30:59 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="NVTcYSNS"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id A5802861BF; Sun, 30 Apr 2023 03:30:30 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x129.google.com (mail-il1-x129.google.com [IPv6:2607:f8b0:4864:20::129]) (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 BF52E86154 for ; Sun, 30 Apr 2023 03:30:27 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x129.google.com with SMTP id e9e14a558f8ab-32b47d6792dso11586465ab.1 for ; Sat, 29 Apr 2023 18:30:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818226; x=1685410226; 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=6LwN0YmJRhVprD1er60Det2vtDp+H4cfSK6RPaOU6BE=; b=NVTcYSNSdNj8JfknDm93AqcNf55y/DZFc1+5YKsbj1lsPbZNp19wBJHe/IZc2b7xke o3QIcSswL5vPjLuouN8c2ynA9a5voVqhwZf0tCJZ/rgAJsRL4D4BJuVIJRWoGuAU7Vmj icO/VZMLfd7iDhh79Zhp+uHdxkBPyrfVLG+Ws= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818226; x=1685410226; 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=6LwN0YmJRhVprD1er60Det2vtDp+H4cfSK6RPaOU6BE=; b=F6zZ6xqBfzZqxDxkfhG2G/Q5vVe769eKeDr+YDVqnmCNua4g4Td1QnWt0nWnRV+ioh mWrNL6H1eRihEgkfe/HKmiqSz2ggHACnN2oStSkN+pO3TsKASeXPBm/QUe4B2htr4jnR gi7v7F0NI/8ZxvBlg5RyhLpyCPwTod0im6CIYOD+TWmMOpuNdnhGGo0ZEHualSp7D1YS ofQTncidFcRXgz6wcwfomMST/Ss8Co/ds+wCGkrqY0znuTExtELPmFCx2gBIsxXZl91C 2wqjl8ZcOrlDyznDnMbGK/zUSdokYxYL3Jzzk8C1SzBNDW+xBNucFCMb0dKecGYce9TP djIA== X-Gm-Message-State: AC+VfDyXAi4PMDHQm8Cfux//qZ3wnubNQvuhyu2MawmiSMugebS9T687 BaIqbpmA44qOYP69CEINKJldUy0oMN+tPC15o7M= X-Google-Smtp-Source: ACHHUZ7smaAyhvI27h6h/sGqtgVGdqmMtKkLQg2iaX37jH9hWrx15SxMNzZFiGFMSKdKCwLDj5fS9g== X-Received: by 2002:a05:6e02:549:b0:328:6412:df0e with SMTP id i9-20020a056e02054900b003286412df0emr6737785ils.29.1682818226410; Sat, 29 Apr 2023 18:30:26 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:26 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 18/30] sandbox: Disable raw Ethernet on MSYS2 Date: Sat, 29 Apr 2023 19:29:51 -0600 Message-ID: <20230430013003.1047454-19-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 This relies on Linux features so cannot be built for Windows. Drop it. Signed-off-by: Simon Glass --- (no changes since v1) arch/sandbox/cpu/Makefile | 2 ++ drivers/net/Makefile | 2 ++ 2 files changed, 4 insertions(+) diff --git a/arch/sandbox/cpu/Makefile b/arch/sandbox/cpu/Makefile index 7c5c52652f5c..be6b57692dd5 100644 --- a/arch/sandbox/cpu/Makefile +++ b/arch/sandbox/cpu/Makefile @@ -9,7 +9,9 @@ obj-y := cache.o cpu.o state.o extra-y := start.o os.o extra-$(CONFIG_SANDBOX_SDL) += sdl.o obj-$(CONFIG_SPL_BUILD) += spl.o +ifeq ($(MSYS_VERSION),0) obj-$(CONFIG_ETH_SANDBOX_RAW) += eth-raw-os.o +endif # os.c is build in the system environment, so needs standard includes # CFLAGS_REMOVE_os.o cannot be used to drop header include path diff --git a/drivers/net/Makefile b/drivers/net/Makefile index 46a40e2ed9f8..6580f8d85510 100644 --- a/drivers/net/Makefile +++ b/drivers/net/Makefile @@ -30,8 +30,10 @@ obj-$(CONFIG_ETH_DESIGNWARE_MESON8B) += dwmac_meson8b.o obj-$(CONFIG_ETH_DESIGNWARE_S700) += dwmac_s700.o obj-$(CONFIG_ETH_DESIGNWARE_SOCFPGA) += dwmac_socfpga.o obj-$(CONFIG_ETH_SANDBOX) += sandbox.o +ifeq ($(MSYS_VERSION),0) obj-$(CONFIG_ETH_SANDBOX_RAW) += sandbox-raw-bus.o obj-$(CONFIG_ETH_SANDBOX_RAW) += sandbox-raw.o +endif obj-$(CONFIG_FEC_MXC) += fec_mxc.o obj-$(CONFIG_FMAN_ENET) += fm/ obj-$(CONFIG_FMAN_ENET) += fsl_mdio.o From patchwork Sun Apr 30 01:29:52 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775316 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=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=EIHdg2JM; dkim-atps=neutral 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 (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Q886K3BSHz1ydV for ; Sun, 30 Apr 2023 11:35:05 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 946D186318; Sun, 30 Apr 2023 03:31:01 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="EIHdg2JM"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 1FE0085C9B; Sun, 30 Apr 2023 03:30:32 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x129.google.com (mail-il1-x129.google.com [IPv6:2607:f8b0:4864:20::129]) (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 0AE22861A3 for ; Sun, 30 Apr 2023 03:30:29 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x129.google.com with SMTP id e9e14a558f8ab-32b4e379000so3185555ab.2 for ; Sat, 29 Apr 2023 18:30:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818227; x=1685410227; 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=ehJ7znfICGzF8ht0FkrQn+pJY46iPhXztZRfHENKMcA=; b=EIHdg2JMOhopeF40Q2K+35/tSZTFHEAOOcKNgc15Yi3gFAkcnaXBKDNMVKMWRVz/IS UMpFZWB0hltqh71BS8Xz0zEsUbOKgtsJXK8EoUKzpeOo/wmkSjtIFnwAMJOvwh0zBQnY ruPs4pktuUEx9/8WMZI77BH+NdtmlTe7v1TEA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818227; x=1685410227; 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=ehJ7znfICGzF8ht0FkrQn+pJY46iPhXztZRfHENKMcA=; b=MWMEczUHrDOIU2ok7WoSHAEd0RI8W6yOGuN39WSKLV1VHq4H01K5rZpckg/EqCScev Sh3cKX77GU5v/yWnqmqZfZJ6RHyA2TxPAhAkueDG1ZkV8SOqjt/gqhRuA21tKo1cOSP9 YjLHKTrf+q/RK9RtUGguU8BMzm1ahtrD0yKFTsVtMKfhxFZM2U4yXRZDTLC30NlqdaqB KNHjkOJwjd+G9UQ5qAtDVXOENYxexjTQFdWXMfHoNpEvYu2ZUAVFQqBY0GRO6pczW5xN vx+87QdbRagBuPfKBSFxhC6Hl0pt76h7A27ZapF3OTHNXWxutW1pangwDs3bVl4jQg1L BQSQ== X-Gm-Message-State: AC+VfDzc5+Qs1ONieSX6DmFYSlc2yqD/xQdhnWa4uxNB3+Ga8PH3UTkU ipUtnScRNiyMChuvSZqS+3gEFkYdVQHWW6t7ons= X-Google-Smtp-Source: ACHHUZ5zuryMk0soQYMkaf9FKQl32Z9i/Ma8i+1BpOu0USHB3xDM5BLzFj1fl46JQLHgFU4AAu8rTg== X-Received: by 2002:a92:d44b:0:b0:32a:8da8:8820 with SMTP id r11-20020a92d44b000000b0032a8da88820mr6442161ilm.17.1682818227270; Sat, 29 Apr 2023 18:30:27 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:27 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 19/30] sandbox: Drop signal handling for MSYS2 Date: Sat, 29 Apr 2023 19:29:52 -0600 Message-ID: <20230430013003.1047454-20-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 Linux register format used on Linux (and perhaps other OSes) is not used on Windows, so disable this feature. Signed-off-by: Simon Glass --- Changes in v2: - Update commit message to mention other OSes - Check for __MSYS__ instead of __linux arch/sandbox/cpu/os.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/sandbox/cpu/os.c b/arch/sandbox/cpu/os.c index e76568ebdd32..522fe8a6f2b1 100644 --- a/arch/sandbox/cpu/os.c +++ b/arch/sandbox/cpu/os.c @@ -288,7 +288,7 @@ static void os_signal_handler(int sig, siginfo_t *info, void *con) ucontext_t __maybe_unused *context = con; unsigned long pc; -#if defined(__x86_64__) +#if defined(__x86_64__) && !defined(__MSYS__) pc = context->uc_mcontext.gregs[REG_RIP]; #elif defined(__aarch64__) pc = context->uc_mcontext.pc; From patchwork Sun Apr 30 01:29:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775317 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=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=g441qrPZ; dkim-atps=neutral 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 (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Q886c4Fxvz1ydW for ; Sun, 30 Apr 2023 11:35:20 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 4A46686281; Sun, 30 Apr 2023 03:31:05 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="g441qrPZ"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id EC04F861AA; Sun, 30 Apr 2023 03:30:32 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x134.google.com (mail-il1-x134.google.com [IPv6:2607:f8b0:4864:20::134]) (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 86BC9861B4 for ; Sun, 30 Apr 2023 03:30:29 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x134.google.com with SMTP id e9e14a558f8ab-32a249b416fso10956115ab.1 for ; Sat, 29 Apr 2023 18:30:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818228; x=1685410228; 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=FTysxEeM5mu7Bg1VX4jS7rAGTFfIeb7MyknGhKRgf8A=; b=g441qrPZQVZ0d/H9toorecncr1Z7V+UceNO5U6C89n95HBLbEKbZiW9uNGwbDJ3sqh nATkq8AJQlkaXAHntQVYo+L3bsZc4pr3Zj8CkQ5AJ7dNIJiG3idnW1LY9OWM+0Wdx1dk fdCRcnTMpNwAPXlzcOvqKK+zMvWnSXAZxgUh4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818228; x=1685410228; 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=FTysxEeM5mu7Bg1VX4jS7rAGTFfIeb7MyknGhKRgf8A=; b=M7kFCu90iBT9fHdCWQPyYjJKUCLk6LJeuVJIZ4PjKp9UlZMq4e85/l0rCYkPJT0BHi scffWMR0jGuuseOByTryUtzF5o/VdUVCEt2Sx6AtwG7EwSZPzVkqN2om/usnKN4IRE08 pG82KKIWx++mrJriJDW70AoMz2daYwtMw45ZHPnQF9RZPCG2nAUdNyd42Z3fYgweP91u up+D3VUhluYLdcDbUT/CmrjjJRCw0iYnBgMakp45hSiaIROMUEroVkI4r3Tz4y0IpDRS JQbwNKAA6Lzm3im9BZzXBdFDGqQgPYNH2dTT5lZL67DNrCQVNigk5k3uBTrjn8T3+cxV nLFg== X-Gm-Message-State: AC+VfDx+4sha9ZZfLo7FFHCb1K9t2BDfW/ac2gecZspBeob9pZ4kXUVZ UquPHWdKSmyjPpcuxXUxWGqgguDBtU9+jVSfSoY= X-Google-Smtp-Source: ACHHUZ7xs7xASojNanwgk2L0FyFW2IEfB/uzp0XGyIVDUvZ8OIz65wkJ88Rfcyx5P4s8I3RiDAsn+A== X-Received: by 2002:a92:ce89:0:b0:329:3c3b:93f4 with SMTP id r9-20020a92ce89000000b003293c3b93f4mr6647583ilo.19.1682818228128; Sat, 29 Apr 2023 18:30:28 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:27 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 20/30] sandbox: Fix up setting of monitor_len on MSYS2 Date: Sat, 29 Apr 2023 19:29:53 -0600 Message-ID: <20230430013003.1047454-21-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 required linker symbols are not present. For now just return 0 in this case. Signed-off-by: Simon Glass --- (no changes since v1) common/board_f.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/board_f.c b/common/board_f.c index 1688e27071fc..4f380d7c82c8 100644 --- a/common/board_f.c +++ b/common/board_f.c @@ -290,7 +290,7 @@ static int setup_mon_len(void) { #if defined(__ARM__) || defined(__MICROBLAZE__) gd->mon_len = (ulong)&__bss_end - (ulong)_start; -#elif defined(CONFIG_SANDBOX) && !defined(__riscv) +#elif defined(CONFIG_SANDBOX) && !defined(__riscv) && !defined(__MSYS__) gd->mon_len = (ulong)&_end - (ulong)_init; #elif defined(CONFIG_SANDBOX) /* gcc does not provide _init in crti.o on RISC-V */ From patchwork Sun Apr 30 01:29:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775318 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=dZCE30vL; 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 4Q886w4gv6z1ydW for ; Sun, 30 Apr 2023 11:35:36 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id C6BC786348; Sun, 30 Apr 2023 03:31:06 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="dZCE30vL"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 31854861B4; Sun, 30 Apr 2023 03:30:34 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x132.google.com (mail-il1-x132.google.com [IPv6:2607:f8b0:4864:20::132]) (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 DFEE085D10 for ; Sun, 30 Apr 2023 03:30:30 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x132.google.com with SMTP id e9e14a558f8ab-32f23e2249bso35216695ab.0 for ; Sat, 29 Apr 2023 18:30:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818229; x=1685410229; 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=NHDZJneIdJE0XsYiYos4w1oIKg52Po0eDffGc3s5e9o=; b=dZCE30vLcSgMPME1yBIARSfjyUgF5ULb+DxyiZ+UJigaOKqTpLkNryH4PZBIuu+zvk V/BX8v7c0/y8LQmiGqSkYauWf8AD3HmHbEOb0Ey3ZxDlLqGvCx9czqYNEgepxYU06WPM ZNUttExLVOeBoza+Q+jfro1Zmw3gjUCfibD6g= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818229; x=1685410229; 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=NHDZJneIdJE0XsYiYos4w1oIKg52Po0eDffGc3s5e9o=; b=Pe/GurxqLJY+kkW7KjWCygU+6n4fMCnZgS3lcyUX2NntReysG5K9HiZgO7oZOgNrnX 1YgioAz/V2x1ZU2NICEzKS6GjSYpFGwkG43j9W74Ud2NiGhTGCXvbtk/aW01ERf+OZRn tIWl/ovpAhZDFfqvaJqERKyyycohpYZCFZnmTVhlP0hhbxvZB/db93gazMrYgeFWGxVi dxHH5G+2xHJnylPvFRC/JsMTf6YxpbpRdHElggt9BCnJIrT5rEPAtAFH3smurko0xPTK yD9Ivv3vozLLdCktsKaIqyNe21LbZAonN+j2fnw8EdqgcxtQgpiltZXcJ1hYnX5GuiMU l2QQ== X-Gm-Message-State: AC+VfDzB9Xsdl+Wc3lAMfgh8aFFuDhcuR8Ifc4md1syro8VvrdiNLsRG C2Qxg1Z8Cwu4pPUsY4v+KOu6Jmm0/QhvM5ohGvg= X-Google-Smtp-Source: ACHHUZ7GRvVFR2i9JDYIsAs1989Q4twaJ6RahIfwAiUFZEJkaHqLphPtvZi1i3AS8wAUCQqlYft2AQ== X-Received: by 2002:a05:6602:8ce:b0:760:ece4:98dc with SMTP id h14-20020a05660208ce00b00760ece498dcmr6215838ioz.10.1682818229166; Sat, 29 Apr 2023 18:30:29 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:28 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass , Masahiro Yamada Subject: [PATCH v2 21/30] Makefile: Disable unsupported compiler options with PE Date: Sat, 29 Apr 2023 19:29:54 -0600 Message-ID: <20230430013003.1047454-22-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 MSYS2 compiler does not support some of these options. Drop them to avoid build errors. Signed-off-by: Simon Glass Reviewed-by: Tom Rini Reviewed-by: Bin Meng --- Changes in v2: - Use cc-option and ld-option instead Makefile | 2 +- scripts/Makefile.lib | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 2453a80eca62..240562dff00b 100644 --- a/Makefile +++ b/Makefile @@ -819,7 +819,7 @@ KBUILD_CPPFLAGS += $(KCPPFLAGS) KBUILD_AFLAGS += $(KAFLAGS) KBUILD_CFLAGS += $(KCFLAGS) -KBUILD_LDFLAGS += -z noexecstack +KBUILD_LDFLAGS += $(call ld-option,-znoexecstack) KBUILD_LDFLAGS += $(call ld-option,--no-warn-rwx-segments) KBUILD_HOSTCFLAGS += $(if $(CONFIG_TOOLS_DEBUG),-g) diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib index 7b27224b5d44..aaae37d50a43 100644 --- a/scripts/Makefile.lib +++ b/scripts/Makefile.lib @@ -425,7 +425,10 @@ cmd_efi_objcopy = $(OBJCOPY) -j .header -j .text -j .sdata -j .data -j \ $(obj)/%.efi: $(obj)/%_efi.so $(call cmd,efi_objcopy) -KBUILD_EFILDFLAGS = -nostdlib -zexecstack -znocombreloc -znorelro +KBUILD_EFILDFLAGS := -nostdlib +KBUILD_EFILDFLAGS += $(call ld-option,-zexecstack) +KBUILD_EFILDFLAGS += $(call ld-option,-znocombreloc) +KBUILD_EFILDFLAGS += $(call ld-option,-znorelro) KBUILD_EFILDFLAGS += $(call ld-option,--no-warn-rwx-segments) quiet_cmd_efi_ld = LD $@ cmd_efi_ld = $(LD) $(KBUILD_EFILDFLAGS) -T $(EFI_LDS_PATH) \ From patchwork Sun Apr 30 01:29:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775319 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=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=IvfMz3q4; dkim-atps=neutral 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 (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Q887C3SgMz1ydW for ; Sun, 30 Apr 2023 11:35:51 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id E7BE186396; Sun, 30 Apr 2023 03:31:07 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="IvfMz3q4"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id CABCB861C0; Sun, 30 Apr 2023 03:30:34 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x12a.google.com (mail-il1-x12a.google.com [IPv6:2607:f8b0:4864:20::12a]) (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 6BCD48615D for ; Sun, 30 Apr 2023 03:30:31 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x12a.google.com with SMTP id e9e14a558f8ab-32a89b6f185so11528945ab.2 for ; Sat, 29 Apr 2023 18:30:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818230; x=1685410230; 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=j1v3xA/zfqLNzNAoaqJsJfIEYm18to5tH0r1cvaFvSo=; b=IvfMz3q4hmpSpYDsC/ReiIkMaukmD9L9cUGf/GDb/WglFxZasW7rZpSsnDjBPrkyKA cy2mr6PO+LM/L6thc3B4ZP5Abm0OlwlvIacSvnBD5I6Vy3W83Jz6HPon8zG0Avj9NxBJ kQ7rbvS2duXchLyIvzGpLlUK/q74DovXcaTlE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818230; x=1685410230; 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=j1v3xA/zfqLNzNAoaqJsJfIEYm18to5tH0r1cvaFvSo=; b=FPP7ZKlFl9wtjo3JX6jtjPClXjuUkryWTCfpuIGEIOTSz1px3d+MziUnqrg+ruVokB b6v2WkcJXb6u0Z9JQpemVoEYUb3mKaoxIr6mb1s6tYU6iswSPb8nAj3cczWZnpeEZuVC oRS+4P8Hr6AdvEdK3IuLWRkU68cStR9JsbbcfDaRSgxxvb5O1KxmRWYRfsv8V5Fxq583 1BpfLkK+2bQJzd+q0zRBSdt90PJvNZBzKziKQSWvwgpCUMVRMu7Ifr3tQckfddt4GUWw dGWkw4YaswDO7mXij0QRsktdouz/uqbHn4dVadapG7fqBrsMmhAc+dq4RQHkc5za2QOu U9eg== X-Gm-Message-State: AC+VfDx2RmHa8ZXAb1Fr5TgDBnO2wIUdAVru/+SgNzW2dJmXes47P+uA DmLLAJNermoWwIaWYA8t1om02OnplcRLZNQ29rg= X-Google-Smtp-Source: ACHHUZ7UFuiJPgvOYf1i51fE0J32ASQfxOEZRRSsoYcwZU2u1A2e0+kOv0sc8qp2yROuW3lLe7VJOA== X-Received: by 2002:a92:db43:0:b0:329:6231:68d6 with SMTP id w3-20020a92db43000000b00329623168d6mr5115733ilq.3.1682818230032; Sat, 29 Apr 2023 18:30:30 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:29 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass , Masahiro Yamada Subject: [PATCH v2 22/30] Makefile: Correct the ans1_compiler rule for MSYS2 Date: Sat, 29 Apr 2023 19:29:55 -0600 Message-ID: <20230430013003.1047454-23-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 the required extension to the Makefile rule. Signed-off-by: Simon Glass Reviewed-by: Tom Rini Reviewed-by: Bin Meng --- Changes in v2: - Use EXEEXT instead of ELFEXT Makefile | 1 + scripts/Makefile.build | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 240562dff00b..a328652f0f23 100644 --- a/Makefile +++ b/Makefile @@ -48,6 +48,7 @@ ifeq ($(MSYS_VERSION),0) export LIBEXT := so else export LIBEXT := dll +export EXEEXT := .exe endif # Avoid funny character set dependencies diff --git a/scripts/Makefile.build b/scripts/Makefile.build index 97dd4a64f6ef..a494e2f105b8 100644 --- a/scripts/Makefile.build +++ b/scripts/Makefile.build @@ -309,7 +309,7 @@ quiet_cmd_asn1_compiler = ASN.1 $@ cmd_asn1_compiler = $(objtree)/tools/asn1_compiler $< \ $(subst .h,.c,$@) $(subst .c,.h,$@) -$(obj)/%.asn1.c $(obj)/%.asn1.h: $(src)/%.asn1 $(objtree)/tools/asn1_compiler +$(obj)/%.asn1.c $(obj)/%.asn1.h: $(src)/%.asn1 $(objtree)/tools/asn1_compiler$(EXEEXT) $(call cmd,asn1_compiler) # Build the compiled-in targets From patchwork Sun Apr 30 01:29:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775320 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=hbAievD7; 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 4Q887V4jzQz1ydW for ; Sun, 30 Apr 2023 11:36:06 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 45B00863AA; Sun, 30 Apr 2023 03:31:09 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="hbAievD7"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id D4BFA861C0; Sun, 30 Apr 2023 03:30:35 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x12a.google.com (mail-il1-x12a.google.com [IPv6:2607:f8b0:4864:20::12a]) (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 601008619C for ; Sun, 30 Apr 2023 03:30:32 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x12a.google.com with SMTP id e9e14a558f8ab-32ad0eb84ffso2897025ab.3 for ; Sat, 29 Apr 2023 18:30:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818231; x=1685410231; 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=tNrSBOqPxvxFAW4wP9WypZZ8/kssfcH3d9329JjRPk0=; b=hbAievD7WScHxV+SR/bR5uZVfLOYYZC8brsTWU1eRSRwM5AepP+O0cE1BJfwSGtdwW 6BM+3ID695eGkihjQ2PAOgwmju5DnrAxGEq5rpl47FfpoVITrsPf0slt8ST8MpKH3xzg m/Z6ycuWJy2WFq3sC0HnA148CDIZFN/a7G7qQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818231; x=1685410231; 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=tNrSBOqPxvxFAW4wP9WypZZ8/kssfcH3d9329JjRPk0=; b=IWwQ9kLyILR+ceV9n0hcNbWQnfExcQCxEfY+1207fX40CIg1JNx1op5HWVOQc2HfUO WUtLz3+EJ1ccOviDaFvQgDJ0wBxcMNmRpTPUOkqRz260VcPJVSylQBle8CEvcCFL2WTS nZf0n8Wt3eLyHW4rR4lUVIKpxaOr419x/FJyJMBWSJr+pjB5JUzHapJgSqBlZrqjGUQO BL9k6P+7wpwprA+Ix0/1zjC374+HR5VY2JobXmv9cn0VPmpJo+U0Zz3ovX9Rdyt1EGJS ei8+hiadptSnqtNyIuz9zmGaHi1g5hZeL0avQz8XYeUmPwsuJqLI6R7791RRXV8lO4VJ yP1w== X-Gm-Message-State: AC+VfDyYoCKzPsrclesrsz1EDp1UtQmViPj9N2rONn3fK05Z/NYTSKcl MOXgJJW/+AOys/22mvZLE0UkLuWSuuwo0cJ3Vp4= X-Google-Smtp-Source: ACHHUZ55JWM06R96hrILKuzP9TGkVp8vsBbucpTivo8xTl+V1ejn/ZrkxyUVIzBxwVZEEF0cL1Retg== X-Received: by 2002:a5e:a815:0:b0:760:c072:d276 with SMTP id c21-20020a5ea815000000b00760c072d276mr5871371ioa.21.1682818230872; Sat, 29 Apr 2023 18:30:30 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:30 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 23/30] sandbox: Augment the linker script for MSYS2 Date: Sat, 29 Apr 2023 19:29:56 -0600 Message-ID: <20230430013003.1047454-24-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 We need to place the linker lists, etc. in the .rdata section but this is not possible with the default linker script. We can only add new sections, which causes Windows to give an "Exec format error" error. Add a rule to create a new linker script, by obtaining the one from the linker and adding some things to the end of the .rdata section. Signed-off-by: Simon Glass --- Changes in v2: - Add an awk script to augment the built-in link script Makefile | 17 ++++++++++++----- arch/sandbox/config.mk | 19 ++++++++++++++++++- arch/sandbox/cpu/u-boot-pe.lds.in | 25 +++++++++++++++++++++++++ scripts/add_to_rdata.awk | 25 +++++++++++++++++++++++++ 4 files changed, 80 insertions(+), 6 deletions(-) create mode 100644 arch/sandbox/cpu/u-boot-pe.lds.in create mode 100644 scripts/add_to_rdata.awk diff --git a/Makefile b/Makefile index a328652f0f23..760c143049aa 100644 --- a/Makefile +++ b/Makefile @@ -1734,6 +1734,12 @@ else u-boot-keep-syms-lto := endif +ifeq ($(MSYS_VERSION),0) +add_ld_script := -T u-boot.lds +else +add_ld_script := u-boot.lds +endif + # Rule to link u-boot # May be overridden by arch/$(ARCH)/config.mk ifeq ($(LTO_ENABLE),y) @@ -1742,7 +1748,7 @@ quiet_cmd_u-boot__ ?= LTO $@ $(CC) -nostdlib -nostartfiles \ $(LTO_FINAL_LDFLAGS) $(c_flags) \ $(KBUILD_LDFLAGS:%=-Wl,%) $(LDFLAGS_u-boot:%=-Wl,%) -o $@ \ - -T u-boot.lds $(u-boot-init) \ + $(add_ld_script) $(u-boot-init) \ -Wl,--whole-archive \ $(u-boot-main) \ $(u-boot-keep-syms-lto) \ @@ -1753,7 +1759,7 @@ quiet_cmd_u-boot__ ?= LTO $@ else quiet_cmd_u-boot__ ?= LD $@ cmd_u-boot__ ?= $(LD) $(KBUILD_LDFLAGS) $(LDFLAGS_u-boot) -o $@ \ - -T u-boot.lds $(u-boot-init) \ + $(add_ld_script) $(u-boot-init) \ --whole-archive \ $(u-boot-main) \ --no-whole-archive \ @@ -1905,10 +1911,11 @@ endif # prepare2 creates a makefile if using a separate output directory prepare2: prepare3 outputmakefile cfg +# Allow the linker script to be generated from LDSCRIPT_IN prepare1: prepare2 $(version_h) $(timestamp_h) $(dt_h) $(env_h) \ - include/config/auto.conf -ifeq ($(wildcard $(LDSCRIPT)),) - @echo >&2 " Could not find linker script." + include/config/auto.conf $(if $(LDSCRIPT_IN),$(LDSCRIPT)) +ifeq ($(wildcard $(LDSCRIPT))$(LDSCRIPT_IN),) + @echo >&2 " Could not find linker script $(LDSCRIPT)" @/bin/false endif diff --git a/arch/sandbox/config.mk b/arch/sandbox/config.mk index 2d184c5f652a..c97c39d4301b 100644 --- a/arch/sandbox/config.mk +++ b/arch/sandbox/config.mk @@ -1,4 +1,4 @@ -# SPDX-License-Identifier: GPL-2.0+ + # SPDX-License-Identifier: GPL-2.0+ # Copyright (c) 2011 The Chromium OS Authors. PLATFORM_CPPFLAGS += -D__SANDBOX__ -U_FORTIFY_SOURCE @@ -71,3 +71,20 @@ EFI_CRT0 := crt0_sandbox_efi.o EFI_RELOC := reloc_sandbox_efi.o AFLAGS_crt0_sandbox_efi.o += -DHOST_ARCH="$(HOST_ARCH)" CFLAGS_reloc_sandbox_efi.o += -DHOST_ARCH="$(HOST_ARCH)" + +ifneq ($(MSYS_VERSION),0) +LDSCRIPT := $(objtree)/u-boot-pe.lds + +AWK_RDATA := ${srctree}/scripts/add_to_rdata.awk +LDSCRIPT_IN := ${srctree}/arch/sandbox/cpu/u-boot-pe.lds.in + +quiet_cmd_gen_lds = GEN LDS $@ +cmd_gen_lds = echo "int main() { return 0; }" | $(CC) -x c - -Wl,-verbose | \ + awk -f $(AWK_RDATA) -v INFILE=$< >$@ + +# Write out the contents of INFILE immediately before the close of the .rdata +# block +$(LDSCRIPT): $(LDSCRIPT_IN) $(AWK_RDATA) FORCE + $(call if_changed,gen_lds) + +endif diff --git a/arch/sandbox/cpu/u-boot-pe.lds.in b/arch/sandbox/cpu/u-boot-pe.lds.in new file mode 100644 index 000000000000..0ec7ef3bb350 --- /dev/null +++ b/arch/sandbox/cpu/u-boot-pe.lds.in @@ -0,0 +1,25 @@ + /* U-Boot additions from here on */ + . = ALIGN(4); + KEEP(*(SORT(__u_boot_list*))); + + *(_u_boot_sandbox_getopt_start) + *(_u_boot_sandbox_getopt) + *(_u_boot_sandbox_getopt_end) + + *(___efi_runtime_start) + *(efi_runtime_text) + *(efi_runtime_data) + *(___efi_runtime_stop) + + *(___efi_runtime_rel_start) + *(.relefi_runtime_text) + *(.relefi_runtime_data) + *(___efi_runtime_rel_stop) + + . = ALIGN(4); + *(.rodata.ttf.init) + *(.rodata.splash.init) + *(.rodata.helloworld.init) + *(.dtb.init.rodata) + + /* U-Boot additions end */ diff --git a/scripts/add_to_rdata.awk b/scripts/add_to_rdata.awk new file mode 100644 index 000000000000..43fdfe8bb789 --- /dev/null +++ b/scripts/add_to_rdata.awk @@ -0,0 +1,25 @@ +# SPDX-License-Identifier: GPL-2.0+ +# +# Copyright 2023 Google, Inc +# +# Awk script to extract the default link script from the linker and write out +# the contents of INFILE immediately before the close of the .rdata section. + +# to a C string which can be compiled into U-Boot. + +# INS = 1 if we are inside the link script (delimited by ======== lines) +# INR = 1 if we are inside the .rdata section + +# When we see } while in the .rdata part of the link script, insert INFILE +/}/ { if (INS && INR) { while ((getline < INFILE) > 0) {print}; DONE=1; INR=0; $0="}"; }} + +# Find start and end of link script +/===================/ { if (INS) exit; INS=1; next; } + +# If inside the link script, print each line +{ if (INS) print; } + +# Detect the .rdata section and get ready to insert INFILE when we see the end } +/\.rdata.*:/ {INR=1; } + +END { if (!DONE) { print "add_to_rdata.awk: Could not find link script in ld output" > "/dev/stderr"; exit 1;} } From patchwork Sun Apr 30 01:29:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775321 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=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=AzwfWPR2; dkim-atps=neutral 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 (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Q887m704bz1ydW for ; Sun, 30 Apr 2023 11:36:20 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id B8F60863B0; Sun, 30 Apr 2023 03:31:11 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="AzwfWPR2"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 07A8A85C9B; Sun, 30 Apr 2023 03:30:36 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-io1-xd2d.google.com (mail-io1-xd2d.google.com [IPv6:2607:f8b0:4864:20::d2d]) (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 430E2861AC for ; Sun, 30 Apr 2023 03:30:33 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-io1-xd2d.google.com with SMTP id ca18e2360f4ac-760f5070ccfso107205039f.2 for ; Sat, 29 Apr 2023 18:30:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818232; x=1685410232; 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=1DZd4Uptictzjqx0qkhpzeo//xbWdS31aMkPGuNQHDs=; b=AzwfWPR2SybA3AGgIYoczW7eaQZ0hQt9XgGZ+WhK9l7VdDZHfbHYfur0qeEMj45uLj gvCL35LPp5YyOpRYNmFEI6vZFVereo4/DvuBDJ3WzkY/tgvFfdtJoribFOERHP8SLkhC BvfqYG21rRgp6I8gPSU3DXRt9vdEQwzhpTH0A= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818232; x=1685410232; 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=1DZd4Uptictzjqx0qkhpzeo//xbWdS31aMkPGuNQHDs=; b=ZNFgk3YOiWWoMoKZtJ1lU2oKwy7cgmXj9S0mK3isaNBYBYGnQy0Ijz764IKHbgGqNS 7JxAQL9h1G3KGSkw9YFj4oeof0owAC8qUt0iV0UaFvDiA14S3G/3MnW+lXYl5/EuoCYS d3JcdEkCTYRDmHteMlALDb0+BK3ssbZ+RQQKOfX8UOrz+Ijd7OF7NVYdYKzKpQFMJcMA 6F1RGQfuH73DOBazjvi8spjIVDq23Es3SbhmwOSizEbICGsYNxBZavYuGriQYjNWZtj/ TBMJVXtIPqtOPi/WDl5vPnsKuoPjzenFQLyFsvr8TqrjJ/rgBLc+E594tXiKoicDlmez oyTQ== X-Gm-Message-State: AC+VfDylEEKEvT3T9T2mYI08Mg7dGljnuX3cafePtPdOGGgOIcSXmea2 7ti9KFVRgfYkMmyrsB6t8U9pYMpMeYoHDuO/J5Q= X-Google-Smtp-Source: ACHHUZ58QKdKCM/VY5I/BktxRR7BDNm/Q12KEuv90NXO8l1un6jT88bzHoqoqt79Eh2osLDjx9WktA== X-Received: by 2002:a5d:9955:0:b0:750:c68e:f028 with SMTP id v21-20020a5d9955000000b00750c68ef028mr7275721ios.9.1682818231764; Sat, 29 Apr 2023 18:30:31 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:31 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 24/30] sandbox: Provide an EFI link script for PE Date: Sat, 29 Apr 2023 19:29:57 -0600 Message-ID: <20230430013003.1047454-25-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 another case for sandbox, when it is built on Windows. Signed-off-by: Simon Glass --- (no changes since v1) arch/sandbox/config.mk | 4 +- arch/x86/lib/crt0_x86_64_efi.S | 2 + arch/x86/lib/pe_x86_64_efi.lds | 83 ++++++++++++++++++++++++++++++++++ 3 files changed, 88 insertions(+), 1 deletion(-) create mode 100644 arch/x86/lib/pe_x86_64_efi.lds diff --git a/arch/sandbox/config.mk b/arch/sandbox/config.mk index c97c39d4301b..d397ae3fe29b 100644 --- a/arch/sandbox/config.mk +++ b/arch/sandbox/config.mk @@ -44,7 +44,9 @@ cmd_u-boot-spl = (cd $(obj) && $(CC) -o $(SPL_BIN) -Wl,-T u-boot-spl.lds \ -Wl,--no-whole-archive \ $(PLATFORM_LIBS) -Wl,-Map -Wl,u-boot-spl.map -Wl,--gc-sections) -ifeq ($(HOST_ARCH),$(HOST_ARCH_X86_64)) +ifneq ($(MSYS_VERSION),0) +EFI_LDS := ${SRCDIR}/../../../arch/x86/lib/pe_x86_64_efi.lds +else ifeq ($(HOST_ARCH),$(HOST_ARCH_X86_64)) EFI_LDS := ${SRCDIR}/../../../arch/x86/lib/elf_x86_64_efi.lds EFI_TARGET := --target=efi-app-x86_64 else ifeq ($(HOST_ARCH),$(HOST_ARCH_X86)) diff --git a/arch/x86/lib/crt0_x86_64_efi.S b/arch/x86/lib/crt0_x86_64_efi.S index 47ed5af97228..cd61b4bdd82f 100644 --- a/arch/x86/lib/crt0_x86_64_efi.S +++ b/arch/x86/lib/crt0_x86_64_efi.S @@ -15,6 +15,7 @@ _start: subq $8, %rsp +#ifndef __CYGWIN__ pushq %rcx pushq %rdx @@ -28,6 +29,7 @@ _start: testq %rax, %rax jnz .exit +#endif call efi_main .exit: diff --git a/arch/x86/lib/pe_x86_64_efi.lds b/arch/x86/lib/pe_x86_64_efi.lds new file mode 100644 index 000000000000..1ee08f6e662e --- /dev/null +++ b/arch/x86/lib/pe_x86_64_efi.lds @@ -0,0 +1,83 @@ +/* SPDX-License-Identifier: BSD-2-Clause */ +/* + * U-Boot EFI linker script + * + * Modified from usr/lib32/elf_x86_64_efi.lds in gnu-efi + */ + +OUTPUT_FORMAT("pe-x86-64", "pe-x86-64", "pe-x86-64") +OUTPUT_ARCH(i386:x86-64) +ENTRY(_start) +SECTIONS +{ + image_base = .; + .hash : { *(.hash) } /* this MUST come first, EFI expects it */ + . = ALIGN(4096); + .eh_frame : { + *(.eh_frame) + } + + . = ALIGN(4096); + + .text : { + *(.text) + *(.text.*) + *(.gnu.linkonce.t.*) + } + + . = ALIGN(4096); + + .reloc : { + *(.reloc) + } + + . = ALIGN(4096); + + .data : { + *(.rodata*) + *(.got.plt) + *(.got) + *(.data*) + *(.sdata) + /* the EFI loader doesn't seem to like a .bss section, so we stick + * it all into .data: */ + *(.sbss) + *(.scommon) + *(.dynbss) + *(.bss*) + *(COMMON) + *(.rel.local) + + /* U-Boot lists and device tree */ + . = ALIGN(8); + *(SORT(__u_boot_list*)); + . = ALIGN(8); + *(.dtb*); + } + + . = ALIGN(4096); + .dynamic : { *(.dynamic) } + . = ALIGN(4096); + + .rela : { + *(.rela.data*) + *(.rela.got) + *(.rela.stab) + *(.rela__u_boot_list*) + } + + . = ALIGN(4096); + .dynsym : { *(.dynsym) } + . = ALIGN(4096); + .dynstr : { *(.dynstr) } + . = ALIGN(4096); + + /DISCARD/ : { *(.eh_frame) } + + .ignored.reloc : { + *(.rela.reloc) + *(.note.GNU-stack) + } + + .comment 0 : { *(.comment) } +} From patchwork Sun Apr 30 01:29:58 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775322 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=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=g68gYKa0; dkim-atps=neutral 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 (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Q88843Y5Nz1ydW for ; Sun, 30 Apr 2023 11:36:36 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 8EBAC863BC; Sun, 30 Apr 2023 03:31:13 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="g68gYKa0"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 71BA985CD8; Sun, 30 Apr 2023 03:30:36 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x12a.google.com (mail-il1-x12a.google.com [IPv6:2607:f8b0:4864:20::12a]) (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 45E8B861AF for ; Sun, 30 Apr 2023 03:30:33 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x12a.google.com with SMTP id e9e14a558f8ab-32f397b44dcso30561035ab.1 for ; Sat, 29 Apr 2023 18:30:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818232; x=1685410232; 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=zI8uJNgAXAJ9qAdjoYtnQ2kBBz9p9YescElJ/jb3icw=; b=g68gYKa0QfjpoIke26sIRUy3pYXDUJCkOkRD6lHMwXywg81W+dV1aWyMuaz9QTf5p6 Z3dRnBoh5P8UmFply3mIFcPYrBPqFcaPUK5XbkH1UG247JvT+s//FHkWfVp0GgD1wIf4 SLkmoVwm4PlnK0PWVHTLdtkCEX4z0r4u9IiqI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818232; x=1685410232; 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=zI8uJNgAXAJ9qAdjoYtnQ2kBBz9p9YescElJ/jb3icw=; b=d7p4A/x8WMsmRNqlk4E8dYep02LqRUNlGDCnKu+i+WMzWKkuJXo+E0/v6Nw4N8u9Vj UCYfeDYYT3wl1OXnwLIPh71jA4MuisWGRygqAgO48GE6jtVaYsw9cpHuCNj5b6Qiw5FW +2KsBwGDaYMs97h3mxMSWvoE+7Vf2ns1VCjCo0BPPBPD9AXK2UcSUseoS6acl2l1yq8D NixAsdPKdGHqWMK/UCcpmwOcjtzlw6oLZTc36f+WPLS5BcVPuBWIXaJAaY1ruND20UAJ WFGY9yBQygk0/9Hk5uPQdsPM/xIunOcYd3IXEqwB1ZSClDXGYObZDAI/YyKwnBsHD3qO O1kw== X-Gm-Message-State: AC+VfDwkIzIbMsnDO9TO8K4sKDCLQ7syKPK1MqzFnHU5oZd4ivHCbPun OUVneEXAACSGfpUtRP9vMWw4dvdnQDs9eoS3pNU= X-Google-Smtp-Source: ACHHUZ4YJPV9ArS2Bi9dPRxIw99IBksBDTyQLMRts2CV7Yo0V9UE/kXYEjzuf1VzYiv36SMTJUGEuA== X-Received: by 2002:a92:b70e:0:b0:32f:80d5:7668 with SMTP id k14-20020a92b70e000000b0032f80d57668mr2527316ili.8.1682818232720; Sat, 29 Apr 2023 18:30:32 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:32 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 25/30] sandbox: Allow weak symbols to be dropped Date: Sat, 29 Apr 2023 19:29:58 -0600 Message-ID: <20230430013003.1047454-26-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 sandbox build makes use of a small number of weak symbols. Allow these to be dropped when building for the PE format, since its support for weak symbols is poor. Signed-off-by: Simon Glass --- (no changes since v1) cmd/bootefi.c | 3 ++- cmd/bootz.c | 3 +++ common/usb.c | 3 +++ drivers/core/root.c | 3 +++ drivers/spi/sandbox_spi.c | 3 +++ env/env.c | 6 ++++++ lib/efi_loader/efi_image_loader.c | 3 +++ lib/efi_loader/efi_runtime.c | 4 ++++ lib/lmb.c | 4 +++- lib/time.c | 3 +++ 10 files changed, 33 insertions(+), 2 deletions(-) diff --git a/cmd/bootefi.c b/cmd/bootefi.c index 8aa15a64c836..21e4a87da53a 100644 --- a/cmd/bootefi.c +++ b/cmd/bootefi.c @@ -358,7 +358,8 @@ static efi_status_t do_bootefi_exec(efi_handle_t handle, void *load_options) u16 *exit_data = NULL; /* On ARM switch from EL3 or secure mode to EL2 or non-secure mode */ - switch_to_non_secure_mode(); + if (IS_ENABLED(CONFIG_WEAK_SYMBOLS)) + switch_to_non_secure_mode(); /* * The UEFI standard requires that the watchdog timer is set to five diff --git a/cmd/bootz.c b/cmd/bootz.c index f1423573d23d..1ffafbd6f2b9 100644 --- a/cmd/bootz.c +++ b/cmd/bootz.c @@ -13,6 +13,8 @@ #include #include +#ifdef CONFIG_WEAK_SYMBOLS + int __weak bootz_setup(ulong image, ulong *start, ulong *end) { /* Please define bootz_setup() for your platform */ @@ -20,6 +22,7 @@ int __weak bootz_setup(ulong image, ulong *start, ulong *end) puts("Your platform's zImage format isn't supported yet!\n"); return -1; } +#endif /* * zImage booting support diff --git a/common/usb.c b/common/usb.c index ae9253dfc0ed..cff53254a379 100644 --- a/common/usb.c +++ b/common/usb.c @@ -1220,6 +1220,8 @@ int usb_new_device(struct usb_device *dev) } #endif +#ifdef CONFIG_WEAK_SYMBOLS + __weak int board_usb_init(int index, enum usb_init_type init) { @@ -1231,6 +1233,7 @@ int board_usb_cleanup(int index, enum usb_init_type init) { return 0; } +#endif /* CONFIG_WEAK_SYMBOLS */ bool usb_device_has_child_on_port(struct usb_device *parent, int port) { diff --git a/drivers/core/root.c b/drivers/core/root.c index c4fb48548bb3..e311f93a08c9 100644 --- a/drivers/core/root.c +++ b/drivers/core/root.c @@ -347,10 +347,13 @@ int dm_extended_scan(bool pre_reloc_only) } #endif +#ifdef CONFIG_WEAK_SYMBOLS + __weak int dm_scan_other(bool pre_reloc_only) { return 0; } +#endif #if CONFIG_IS_ENABLED(OF_PLATDATA_INST) && CONFIG_IS_ENABLED(READ_ONLY) void *dm_priv_to_rw(void *priv) diff --git a/drivers/spi/sandbox_spi.c b/drivers/spi/sandbox_spi.c index f844597d04cf..f68c9f33bdb4 100644 --- a/drivers/spi/sandbox_spi.c +++ b/drivers/spi/sandbox_spi.c @@ -41,12 +41,15 @@ struct sandbox_spi_priv { uint mode; }; +#ifdef CONFIG_WEAK_SYMBOLS + __weak int sandbox_spi_get_emul(struct sandbox_state *state, struct udevice *bus, struct udevice *slave, struct udevice **emulp) { return -ENOENT; } +#endif uint sandbox_spi_get_speed(struct udevice *dev) { diff --git a/env/env.c b/env/env.c index ad774f41175b..bcc66b4a6a12 100644 --- a/env/env.c +++ b/env/env.c @@ -53,6 +53,8 @@ static struct env_driver *_env_driver_lookup(enum env_location loc) return NULL; } +#ifdef CONFIG_WEAK_SYMBOLS + static enum env_location env_locations[] = { #ifdef CONFIG_ENV_IS_IN_EEPROM ENVL_EEPROM, @@ -88,6 +90,7 @@ static enum env_location env_locations[] = { ENVL_NOWHERE, #endif }; +#endif /* CONFIG_WEAK_SYMBOLS */ static bool env_has_inited(enum env_location location) { @@ -106,6 +109,8 @@ static void env_set_inited(enum env_location location) gd->env_has_init |= BIT(location); } +#ifdef CONFIG_WEAK_SYMBOLS + /** * arch_env_get_location() - Returns the best env location for an arch * @op: operations performed on the environment @@ -155,6 +160,7 @@ __weak enum env_location env_get_location(enum env_operation op, int prio) { return arch_env_get_location(op, prio); } +#endif /* CONFIG_WEAK_SYMBOLS */ /** * env_driver_lookup() - Finds the most suited environment location diff --git a/lib/efi_loader/efi_image_loader.c b/lib/efi_loader/efi_image_loader.c index 26df0da16c93..c473cd58cfb8 100644 --- a/lib/efi_loader/efi_image_loader.c +++ b/lib/efi_loader/efi_image_loader.c @@ -174,10 +174,13 @@ static efi_status_t efi_loader_relocate(const IMAGE_BASE_RELOCATION *rel, return EFI_SUCCESS; } +#ifdef CONFIG_WEAK_SYMBOLS + void __weak invalidate_icache_all(void) { /* If the system doesn't support icache_all flush, cross our fingers */ } +#endif /** * efi_set_code_and_data_type() - determine the memory types to be used for code diff --git a/lib/efi_loader/efi_runtime.c b/lib/efi_loader/efi_runtime.c index bf54d6ad871d..d7cf3b7e9dc8 100644 --- a/lib/efi_loader/efi_runtime.c +++ b/lib/efi_loader/efi_runtime.c @@ -375,6 +375,9 @@ out: return EFI_EXIT(EFI_UNSUPPORTED); #endif } + +#ifdef CONFIG_WEAK_SYMBOLS + /** * efi_reset_system() - reset system * @@ -399,6 +402,7 @@ void __weak __efi_runtime EFIAPI efi_reset_system( { return; } +#endif /* CONFIG_WEAK_SYMBOLS */ /** * efi_reset_system_init() - initialize the reset driver diff --git a/lib/lmb.c b/lib/lmb.c index b2c233edb64e..f46442aba48a 100644 --- a/lib/lmb.c +++ b/lib/lmb.c @@ -148,9 +148,11 @@ void arch_lmb_reserve_generic(struct lmb *lmb, ulong sp, ulong end, ulong align) lmb_reserve(lmb, sp, bank_end - sp + 1); +#ifdef CONFIG_WEAK_SYMBOLS + if (gd->flags & GD_FLG_SKIP_RELOC) lmb_reserve(lmb, (phys_addr_t)(uintptr_t)_start, gd->mon_len); - +#endif break; } } diff --git a/lib/time.c b/lib/time.c index 00f4a1ac8fb3..e8da2a3aa6a6 100644 --- a/lib/time.c +++ b/lib/time.c @@ -179,6 +179,8 @@ uint64_t usec_to_tick(unsigned long usec) return tick; } +#ifdef CONFIG_WEAK_SYMBOLS + void __weak __udelay(unsigned long usec) { uint64_t tmp; @@ -188,6 +190,7 @@ void __weak __udelay(unsigned long usec) while (get_ticks() < tmp+1) /* loop till event */ /*NOP*/; } +#endif /* ------------------------------------------------------------------------- */ From patchwork Sun Apr 30 01:29:59 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775323 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=jZ+2WKxr; 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 4Q888S0TYDz1ydW for ; Sun, 30 Apr 2023 11:36:56 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 36462863D4; Sun, 30 Apr 2023 03:31:15 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="jZ+2WKxr"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id D026B861D7; Sun, 30 Apr 2023 03:30:37 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x130.google.com (mail-il1-x130.google.com [IPv6:2607:f8b0:4864:20::130]) (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 F224A8615D for ; Sun, 30 Apr 2023 03:30:34 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x130.google.com with SMTP id e9e14a558f8ab-329673008e3so11047635ab.2 for ; Sat, 29 Apr 2023 18:30:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818233; x=1685410233; 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=r4NrcHQrBmuZJnQPQZPmUC5RjLYz9FGJpAKxZ0RmjD4=; b=jZ+2WKxrZFiV8DEM4scrTxG/qaoCbt29PBfNyXFYptLlbKR0nqPixlusBiFCu1OIeV SWkml+eUIbJMP0ENEZXQ/Ca/vms8yDMELY6ki9phu3U0bwkMRDECMf+HAYHig5L8i1VI yGp2tp8lHBkwKYJzmCq1Nj38G0P/frDd2vsOE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818233; x=1685410233; 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=r4NrcHQrBmuZJnQPQZPmUC5RjLYz9FGJpAKxZ0RmjD4=; b=jCQzayNNMl1J6MS4R0Ve23I95WrNbxeGivTvXUbWz0f8cC7bX3QHPJXvyOxjwGjruB 9CSo7jHuccMF5snc4FKOBqWq098OOKHuH5GOa+fub3wWLrk/OLSG4ec6ZQYddVn7ylzK S689Ek8gpJOAPpQXPOLthhzm0W68jkYkBesY2HkMnqlZvImq5EiSQBTuGGnBnbQP1IHL 6rbeTYH+Dpy54Rb5niN619YyDAspAvzj8tdpmIX3fCW8bodg5g5ANJNaEXKU65qz5X1l 9z6G7LrcuccUPc5HD+Y6Tqs/7xeSy/xljdv3xrrq223MzM68BidjCLoNmCQFPNbk8Sab kpKA== X-Gm-Message-State: AC+VfDxmBaOEcrZ36cHs2o03XWQotO2P2XsYm2QiIAQ88CQTck0lmhYv Ic/iBJJPdiZvfENY/L+A6DJuIjUvCnvQIrBkCpQ= X-Google-Smtp-Source: ACHHUZ6O8Zfa4TH+8KSTbTLP6YGdptYe5kHgbE4y8oqFAL4hk5FlkIjP0wSTc9fvPdJrzOGC7sSYpQ== X-Received: by 2002:a92:c052:0:b0:32b:529a:ece4 with SMTP id o18-20020a92c052000000b0032b529aece4mr7615367ilf.21.1682818233542; Sat, 29 Apr 2023 18:30:33 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:33 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 26/30] build: Disable weak symbols for MSYS2 Date: Sat, 29 Apr 2023 19:29:59 -0600 Message-ID: <20230430013003.1047454-27-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 Weak symbols are not well supported by the PE format, so disable them. We need to manually ensure that only one function is present in the source code. Add a Kconfig option to control this and enable it when building for Windows. Signed-off-by: Simon Glass --- (no changes since v1) Kconfig | 12 ++++++++++++ include/linux/compiler_attributes.h | 4 ++++ 2 files changed, 16 insertions(+) diff --git a/Kconfig b/Kconfig index 9ac816abef1c..985b09680934 100644 --- a/Kconfig +++ b/Kconfig @@ -75,6 +75,18 @@ config CLANG_VERSION config CC_IS_MSYS def_bool $(success,uname -o | grep -q Msys) +config WEAK_SYMBOLS + bool "Enable use of weak symbols" + default y if !CC_IS_MSYS + help + The Portable Executable (PE) format used by Windows does not support + weak symbols very well. Even where it can be made to work, the __weak + function attribute cannot be made to work with PE. Supporting weak + symbols would involve changing the source code in undesirable ways. + + This option controls whether weak symbols are used, or not. When + disabled, the __weak function attribute does nothing. + choice prompt "Optimization level" default CC_OPTIMIZE_FOR_SIZE diff --git a/include/linux/compiler_attributes.h b/include/linux/compiler_attributes.h index 44c9a08d7346..c954109a065b 100644 --- a/include/linux/compiler_attributes.h +++ b/include/linux/compiler_attributes.h @@ -268,6 +268,10 @@ * gcc: https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-weak-function-attribute * gcc: https://gcc.gnu.org/onlinedocs/gcc/Common-Variable-Attributes.html#index-weak-variable-attribute */ +#ifdef CONFIG_WEAK_SYMBOLS #define __weak __attribute__((__weak__)) +#else +#define __weak +#endif #endif /* __LINUX_COMPILER_ATTRIBUTES_H */ From patchwork Sun Apr 30 01:30:00 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775326 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=XCi3Ug11; 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 4Q889L2NRbz1ydW for ; Sun, 30 Apr 2023 11:37:42 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 3906E863DA; Sun, 30 Apr 2023 03:31:19 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="XCi3Ug11"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 59138861AF; Sun, 30 Apr 2023 03:30:42 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x136.google.com (mail-il1-x136.google.com [IPv6:2607:f8b0:4864:20::136]) (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 EE465861C8 for ; Sun, 30 Apr 2023 03:30:35 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x136.google.com with SMTP id e9e14a558f8ab-32951864ad9so2703725ab.0 for ; Sat, 29 Apr 2023 18:30:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818234; x=1685410234; 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=fn8U8wyCiUpJYRYljCO90qkQsgiy/v2809aXOaiFtdU=; b=XCi3Ug11SRp/LrPIJK77rg3HcQ+5DVLDXVh3yWI7ppJ9eO2Oou7lwfUTmp9c0lnqGM lokUXe14/fWH+LCziy1VE1sIV9UQnYAWZbm3p/4qJHoftLNJOrq5zL7GaEBI7hA9xYHU Cm/myIqTPaWM5P3n2m3I4isVRT6dDiKVjwp5A= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818234; x=1685410234; 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=fn8U8wyCiUpJYRYljCO90qkQsgiy/v2809aXOaiFtdU=; b=SYYFxXgTtfm3o5knSYKmDrq1h8Be1IuTJ9MtUpcMLJHPUtJA1wd/OwX+kKdzRsUwJH AMMqzJew7AR3wM5+YxWIDrPooXM4i+KrgMDJtz9n1atOjkaIqAx8UsA2XHxWmet2wYJ0 YitSpvXKdvRf/Z/IpV0CbD9Tp0DEu7GL+Uw7zld40tY1rfFKilIR9IYa0nsUainDQ43y dy3PIZxyxf+v/UM17udhQnlD75bauVBL9nxx3ywB3kuYL5EJPUC5fT9Dxd9aFCeOuIPD 3v7rrWspDt9r9kUzRLw0Kh89d5vmYvyV5aqRWXU3QadY/nwFg+f4UgNiH1mj7P5pouhI lUZQ== X-Gm-Message-State: AC+VfDwovR7sKIuKzXItfIVKNQXy2WXFx1ZPsl/p7K1IPcBnFt58pAFo 494/ak/xypmBYnZAKQw/mFYrD6LnN/bGBQizvNY= X-Google-Smtp-Source: ACHHUZ5q/h/D0xkx3mUnCBfPmqY0Yg66cjxR9Y3lFdzPo5DOu4EXRtWLYIfV3eXEPsDTpM0zmZFBYA== X-Received: by 2002:a5d:950e:0:b0:763:6855:750d with SMTP id d14-20020a5d950e000000b007636855750dmr6454021iom.9.1682818234544; Sat, 29 Apr 2023 18:30:34 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:34 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 27/30] doc: Update the MSYS2 packages and versions Date: Sat, 29 Apr 2023 19:30:00 -0600 Message-ID: <20230430013003.1047454-28-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 These are now quite out-of-date. Update to 2023 versions and bring in those are are needed for the newer tool features. Signed-off-by: Simon Glass --- (no changes since v1) doc/build/tools.rst | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/doc/build/tools.rst b/doc/build/tools.rst index ec0172292585..6b7342a27606 100644 --- a/doc/build/tools.rst +++ b/doc/build/tools.rst @@ -24,15 +24,18 @@ you can use MSYS2, a software distro and building platform for Windows. Download the MSYS2 installer from https://www.msys2.org. Make sure you have installed all required packages below in order to build these host tools:: - * gcc (9.1.0) - * make (4.2.1) - * bison (3.4.2) - * diffutils (3.7) - * openssl-devel (1.1.1.d) + * gcc (11.3.0-3) + * make (4.4.1-1) + * bison (3.8.2-4) + * diffutils (3.9-1) + * flex (2.6.4-3) + * libgnutls-devel (3.8.0-1) + * libutil-linux-devel (2.35.2) + * openssl-devel (3.1.0-1) Note the version numbers in these parentheses above are the package versions at the time being when writing this document. The MSYS2 installer tested is -http://repo.msys2.org/distrib/x86_64/msys2-x86_64-20190524.exe. +https://github.com/msys2/msys2-installer/releases/download/2023-03-18/msys2-x86_64-20230318.exe There are 3 MSYS subsystems installed: MSYS2, MinGW32 and MinGW64. Each subsystem provides an environment to build Windows applications. The MSYS2 @@ -43,5 +46,6 @@ applications using a linux toolchain (gcc, bash, etc), targeting respectively Launch the MSYS2 shell of the MSYS2 environment, and do the following:: - $ make tools-only_defconfig - $ make tools-only + $ pacman -S bison diffutils flex gcc libgnutls-devel libutil-linux-devel \ + make openssl-devel + $ make tools-only_defconfig tools-only From patchwork Sun Apr 30 01:30:01 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775324 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=l09J6YmS; 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 4Q888n6WD7z1ydW for ; Sun, 30 Apr 2023 11:37:13 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id ADFC4863BD; Sun, 30 Apr 2023 03:31:16 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="l09J6YmS"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id D7EB586154; Sun, 30 Apr 2023 03:30:38 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x132.google.com (mail-il1-x132.google.com [IPv6:2607:f8b0:4864:20::132]) (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 E1FF58619C for ; Sun, 30 Apr 2023 03:30:35 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x132.google.com with SMTP id e9e14a558f8ab-32b102ca487so10483025ab.2 for ; Sat, 29 Apr 2023 18:30:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818235; x=1685410235; 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=3SkyfxeMrkVAqYm8T+fA/ailQyFlytJxX+NqkV42V0c=; b=l09J6YmSdk0LV5Mf0DictGeiVrLguknTIGnVGkdLzobkw/3g2/IX61NAJwzOEsnKNo 1eFs5gmpf+9LQ8J+az1Spqcll8jv2csS/bk6EQUuPwVm1AsKvHMXwGPnw73IonHuHn/9 73sqyEKoSUR3a/JOU1Stj71mjlCWACS4GRKVY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818235; x=1685410235; 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=3SkyfxeMrkVAqYm8T+fA/ailQyFlytJxX+NqkV42V0c=; b=R5hOblKSuOVQ8kSHsQhC8Np8XSn/jkL2PcWuoVNc/sk57y93DOq5di4q6JPK9SW3C2 rWanH3Ve2nTsJXTY5iDAMu7gjrHMLnfVoPM+wZyVbnSwJOEErF0pUr7GoxMaeqoWl0uz WY/Gre/voqrYU3yYMCOYzhZU6KY/4mbRgG1doz89wMdOoHlVEik/5pw1cOB0hWfoLeG0 jprXF6iepx8g27tquSgSUnFScSekGHnovOVAqx236nocz0mMszvDtT4wpBhl+GPxnkHC pwPHseJJ1nOrE/VsN6lWWfa24s1AU0932USm7tnfBU23iOupN+kwwuYo2gl/jHc8sLOR 7V0A== X-Gm-Message-State: AC+VfDxs6Macuqthl6PYcae1StKrYCZwCo6EFyeGBksl0mN51SYhsJou 1y/U8H58yubUIxDlbWpk5fNuAd1AnkI5PhL+Kqs= X-Google-Smtp-Source: ACHHUZ60cvxz1WahGRoY/9xnjKp75bw4tcMEMsMRZXtj8aER71+hoYMr9MkH5ge8L7WoYlTFICxADw== X-Received: by 2002:a92:c709:0:b0:330:5071:748d with SMTP id a9-20020a92c709000000b003305071748dmr1642217ilp.23.1682818235430; Sat, 29 Apr 2023 18:30:35 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:35 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 28/30] doc: Show how to build sandbox for MSYS2 Date: Sat, 29 Apr 2023 19:30:01 -0600 Message-ID: <20230430013003.1047454-29-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 instructions for building u-boot.exe to run on Windows. Signed-off-by: Simon Glass --- Changes in v2: - Clearify the documentation to explain the environment better doc/build/gcc.rst | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/doc/build/gcc.rst b/doc/build/gcc.rst index a0650a51db4b..96861c2b3d90 100644 --- a/doc/build/gcc.rst +++ b/doc/build/gcc.rst @@ -184,8 +184,48 @@ Important ones are * clean - remove most generated files but keep the configuration * mrproper - remove all generated files + config + various backup files +Building on/for Windows +----------------------- + +Limited support is available for Windows, including building sandbox in the +MSYS2 environment. This produces native applications, but they must have access +to the `msys-2.0.dll` file. + +Note that this is not the same as running Windows Subsystem for Linux (WSL), +which is designed to build Linux applications. + +It is best to use an out-of-tree build, so you can build multiple boards, +with the output in a temporary directory like `/tmp/b`. + +First enable Windows developer mode with `Developer Mode`_ so that symbolic +links can be used. Then run the MSYS2 shell and enable symbolic links:: + + cd + echo "export MSYS=winsymlinks:nativestrict" >>.bashrc + +Close all MSYS2 shells so that the setting takes effect. + +To build sandbox, first install some required packages:: + + pacman install bc bison diffutils flex gcc libgnutls-devel \ + libutil-linux-devel make openssl-devel python python-setuptools swig + +then:: + + make O=/tmp/b/sandbox -j$(nproc) sandbox_defconfig all + +Note that it currently only gets as far as running binman, since this doesn't +fully work on Windows. + +You can also build sandbox_spl:: + + make O=/tmp/b/sandbox_spl -j$(nproc) sandbox_spl_defconfig all + + Installation ------------ The process for installing U-Boot on the target device is device specific. Please, refer to the board specific documentation :doc:`../board/index`. + +.. _`Developer Mode`: https://msdn.microsoft.com/en-us/windows/uwp/get-started/enable-your-device-for-development From patchwork Sun Apr 30 01:30:02 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775325 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=CjwLFtDi; 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 4Q88952RVvz1ydW for ; Sun, 30 Apr 2023 11:37:29 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 18CF1863D9; Sun, 30 Apr 2023 03:31:18 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="CjwLFtDi"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 2BDD7861EA; Sun, 30 Apr 2023 03:30:39 +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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x136.google.com (mail-il1-x136.google.com [IPv6:2607:f8b0:4864:20::136]) (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 D4558861AF for ; Sun, 30 Apr 2023 03:30:36 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x136.google.com with SMTP id e9e14a558f8ab-3294eacb2f6so2629935ab.3 for ; Sat, 29 Apr 2023 18:30:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818236; x=1685410236; 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=RZePRsHDBuVr7RkbIWVj/Q4fX/L++umtOl50dBq0flA=; b=CjwLFtDispoFcAXeJk11TEyiB6OFVs39x7FtpPsp0MUZJ6QeGnQJCT9kx84AxWFdpU Rcl/hJAZQOT1Cfm8mV19YYT4HLWU0n9JAOO4c5rld55QgO4+RZfk7mUoUMbrfLFpylwo RDwfm8GT7qqz2BBcZReUZpncHlpcjYU9mDTD0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818236; x=1685410236; 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=RZePRsHDBuVr7RkbIWVj/Q4fX/L++umtOl50dBq0flA=; b=Vl6craiOGcPB0EvqH7R1cntPeIdgfi6abjjfjNek5fsy0XZELFjH8p2wnLVuOTobTV a54BdBXPluZK+8sDQDIq1KcYyhlyenkP1XU3uA7oRNywb/hvWpH01FfGLsUGc9IURJ9G hCp7Mde+4mBhaQtyzT7UbpvAX1Lh5GDRxVnDdnNe4WYyEXmc84g1RsFdWzl4f53XhzIF gKiG8AFibj6v4UHGOhHEGmAhAg9l7p6QTKu1C8PwuOjCjxZnhSMuCcY+1u8wrQ+b860L DMg7Xr64eu/79LP+yu5OWK5r8GGDZEWmyCvKldZyg4AcSPdMVYWEa+SOJdfoXiUvQ4Q/ Enag== X-Gm-Message-State: AC+VfDxXZF6YDq7oVyIC44YlvxRANm1bdKpKFRxn8/9Lo7RY6R5gm68I xC/Rok91bnpXezN43NnooH95DsgJzj0vsX4Vits= X-Google-Smtp-Source: ACHHUZ6/KHdZzT4BA0a3e68ahvzCDrMPJwAXLVB2pIXGnA2Dh9iT2BKBRzfCuBbfDAxmkAwIg5go1g== X-Received: by 2002:a6b:4f03:0:b0:760:f795:ccdf with SMTP id d3-20020a6b4f03000000b00760f795ccdfmr6077197iob.8.1682818236360; Sat, 29 Apr 2023 18:30:36 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:36 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass , Masahiro Yamada Subject: [PATCH v2 29/30] Makefile: Drop unwind tables for MSYS Date: Sat, 29 Apr 2023 19:30:02 -0600 Message-ID: <20230430013003.1047454-30-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 These give lots of warnings for the form: lib/efi_loader/helloworld.o:helloworld.c:(.pdata+0x0): relocation truncated to fit: IMAGE_REL_AMD64_ADDR32NB against `.text' The tables are not needed except when debugging, so disable them for now. Signed-off-by: Simon Glass --- (no changes since v1) lib/efi_loader/Makefile | 8 ++++++++ scripts/Makefile.lib | 4 ++++ 2 files changed, 12 insertions(+) diff --git a/lib/efi_loader/Makefile b/lib/efi_loader/Makefile index 13a35eae6c06..c17d39eba91e 100644 --- a/lib/efi_loader/Makefile +++ b/lib/efi_loader/Makefile @@ -15,11 +15,19 @@ CFLAGS_efi_boottime.o += \ CFLAGS_boothart.o := $(CFLAGS_EFI) -Os -ffreestanding CFLAGS_REMOVE_boothart.o := $(CFLAGS_NON_EFI) CFLAGS_helloworld.o := $(CFLAGS_EFI) -Os -ffreestanding + +ifneq ($(MSYS_VERSION),0) +CFLAGS_helloworld.o += -fno-asynchronous-unwind-tables -fno-unwind-tables +endif + CFLAGS_REMOVE_helloworld.o := $(CFLAGS_NON_EFI) CFLAGS_dtbdump.o := $(CFLAGS_EFI) -Os -ffreestanding CFLAGS_REMOVE_dtbdump.o := $(CFLAGS_NON_EFI) CFLAGS_initrddump.o := $(CFLAGS_EFI) -Os -ffreestanding CFLAGS_REMOVE_initrddump.o := $(CFLAGS_NON_EFI) +ifneq ($(MSYS_VERSION),0) +CFLAGS_initrddump.o += -fno-asynchronous-unwind-tables -fno-unwind-tables +endif ifdef CONFIG_RISCV always += boothart.efi diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib index aaae37d50a43..e751e452214e 100644 --- a/scripts/Makefile.lib +++ b/scripts/Makefile.lib @@ -450,6 +450,10 @@ targets += $(obj)/efi_crt0.o $(obj)/efi_reloc.o $(obj)/efi_freestanding.o CFLAGS_REMOVE_efi_reloc.o := $(LTO_CFLAGS) CFLAGS_REMOVE_efi_freestanding.o := $(LTO_CFLAGS) +ifneq ($(MSYS_VERSION),0) +CFLAGS_efi_reloc.o += -fno-asynchronous-unwind-tables -fno-unwind-tables +CFLAGS_efi_freestanding.o += -fno-asynchronous-unwind-tables -fno-unwind-tables +endif # ACPI # --------------------------------------------------------------------------- From patchwork Sun Apr 30 01:30:03 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1775327 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 (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=RRN9FmT/; 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 4Q889b1GKVz1ydW for ; Sun, 30 Apr 2023 11:37:55 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id ADE20863CF; Sun, 30 Apr 2023 03:31:20 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="RRN9FmT/"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id B2EA0861A3; Sun, 30 Apr 2023 03:30: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.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, 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-il1-x135.google.com (mail-il1-x135.google.com [IPv6:2607:f8b0:4864:20::135]) (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 B4AD4861D3 for ; Sun, 30 Apr 2023 03:30:37 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-il1-x135.google.com with SMTP id e9e14a558f8ab-3294fd17f1cso2828465ab.1 for ; Sat, 29 Apr 2023 18:30:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682818237; x=1685410237; 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=YgIiQog8LijLtLR70KBPEQTXwBw91gcqkIci00mhzfg=; b=RRN9FmT/Xf4yhBu4g02dX2n4+Q1Wnu0G9FNnKKJEZD9sYgXIrP2dG31GEwiUSfPVVJ uUeYUEf4PoXf2NpiGqGEYGTvfpQ9uvLijhg2fbTJf+mh4deb+tSuohYnqWweDqeChTNc S1suS3Mon6NB047aeVMWME1agU1Q5gHKo4qHY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682818237; x=1685410237; 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=YgIiQog8LijLtLR70KBPEQTXwBw91gcqkIci00mhzfg=; b=izuOzk+zrol1QlJUlEgIwenmB6WMTlfQoBbcqOO28mmLiCAT7hqgJnSDYd5gwHuZEn t1dZtP8qvmV4sKnYGFAaqgpHIYWFNhJZ/jwKgbZ7AL5focwXv9++BjDqN//ChoQTiQhI 5KzqEpQF2ChKCGnSY9OShJwhAWZIFERcYtmDj0tl2OFywPqEVMF1+xzBnKs6x0S03VzZ Y0Wf2MTYTX+UIReN0/0PdsXPO1uAUUc0yIGEwvg6m+aDVw9mBS2CknIHl4pEyaeaSwwc /5luz7+aP0piZjyuoTBHoTOm/Hg/st+MhVC8ru/pG5IcuC0GVrx/OmMaJf5SH3YWNHjj QwrQ== X-Gm-Message-State: AC+VfDxi8RFz4P6e05ClgTgK4GLf3xou2hTH28L1q2TNut8eI3R2LEtd EBEc65XWKUdJm0pDv4LEwiLvROLO12eUTd4hjm0= X-Google-Smtp-Source: ACHHUZ5aSpee3wJ8hdkfBcrD0lHxcnG/KFtGhBk2y9GKBvWqEt1YIOcNmBAqrMdqRKX548ZzcMtcCQ== X-Received: by 2002:a92:c052:0:b0:32a:798e:5e6e with SMTP id o18-20020a92c052000000b0032a798e5e6emr6370734ilf.23.1682818237190; Sat, 29 Apr 2023 18:30:37 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id w4-20020a02cf84000000b0040f8ed3ab81sm7259429jar.129.2023.04.29.18.30.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Apr 2023 18:30:36 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Bin Meng , =?utf-8?q?Pali_Roh=C3=A1r?= , Heinrich Schuchardt , Tom Rini , Simon Glass Subject: [PATCH v2 30/30] CI: Enable sandbox build for Windows Date: Sat, 29 Apr 2023 19:30:03 -0600 Message-ID: <20230430013003.1047454-31-sjg@chromium.org> X-Mailer: git-send-email 2.40.1.495.gc816e09b53d-goog In-Reply-To: <20230430013003.1047454-1-sjg@chromium.org> References: <20230430013003.1047454-1-sjg@chromium.org> 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 new rule to build sandbox for Windows. For now, no tests are run in this configuration. Signed-off-by: Simon Glass --- Changes in v2: - Update the cover letter to better explain the motivation .azure-pipelines.yml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/.azure-pipelines.yml b/.azure-pipelines.yml index 76ffdeebd667..d15a86ff3650 100644 --- a/.azure-pipelines.yml +++ b/.azure-pipelines.yml @@ -39,6 +39,33 @@ stages: # Tell MSYS2 not to ‘cd’ our startup directory to HOME CHERE_INVOKING: yes + - job: sandbox_windows + displayName: 'Ensure sandbox build for Windows' + pool: + vmImage: $(windows_vm) + steps: + - powershell: | + (New-Object Net.WebClient).DownloadFile("https://github.com/msys2/msys2-installer/releases/download/2021-06-04/msys2-base-x86_64-20210604.sfx.exe", "sfx.exe") + displayName: 'Install MSYS2' + - script: | + sfx.exe -y -o%CD:~0,2%\ + %CD:~0,2%\msys64\usr\bin\bash -lc " " + %CD:~0,2%\msys64\usr\bin\bash -lc "pacman --noconfirm -Syuu" + %CD:~0,2%\msys64\usr\bin\bash -lc "pacman --noconfirm -Syuu" + displayName: 'Update MSYS2' + - script: | + %CD:~0,2%\msys64\usr\bin\bash -lc "pacman --noconfirm --needed -Sy bc bison diffutils flex gcc libgnutls-devel libutil-linux-devel make openssl-devel python python-setuptools swig" + displayName: 'Install Toolchain' + - script: | + echo make sandbox_defconfig all > build-tools.sh + %CD:~0,2%\msys64\usr\bin\bash -lc "bash build-tools.sh" + displayName: 'Build sandbox' + env: + # Tell MSYS2 we need a POSIX emulation layer + MSYSTEM: MSYS + # Tell MSYS2 not to ‘cd’ our startup directory to HOME + CHERE_INVOKING: yes + - job: tools_only_macOS displayName: 'Ensure host tools build for macOS X' pool: