From patchwork Fri Mar 2 03:49:44 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Victor Chong X-Patchwork-Id: 130439 Delivered-To: patch@linaro.org Received: by 10.46.66.2 with SMTP id p2csp828766lja; Thu, 1 Mar 2018 19:50:41 -0800 (PST) X-Google-Smtp-Source: AG47ELuaLuXeAkUXCw9+5x/uB30m6NPFB0vJbfN6ItYZcBCfyTihI6C/DqAkNrsFUrlrl9gU20xK X-Received: by 10.237.63.28 with SMTP id p28mr6547483qtf.104.1519962640946; Thu, 01 Mar 2018 19:50:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519962640; cv=none; d=google.com; s=arc-20160816; b=c4PGyeiRQA1T113H7o8+kYIapqtBBYGGW65G243flkDRAm9viEkoKMbyDIJwifKAWU XOr8mSxhwihD7gdCPr9/syVxV2CpFxAwRRMIAYwyt3EyCYl9SQ+2kHgVmoC9b3t7nJ6l nwXnzcHlQLD3jGzZ1jIQW8w0DpR83oT2OKpKfpgWm4PY3mCA6Q2WDydZWUcm0oQwnOJG SMPMo2oLvvH7r3nxkkBugTe7NBaZq4hSus8ircXf0cGpewKpIYGchprH3pGEi2nPGiJr 2Uil39u4b4AzBokFcdJrYPAtwfvAxkv7BxqPmHCVTXKg5JnxyySsjmTdo16Vf+1SLn8Z d9ew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:cc:references:in-reply-to:message-id :date:to:from:delivered-to:arc-authentication-results; bh=nkxUrZZlBeia0CSvwfRqeDX72THAQwUcndIzN1qO9ao=; b=xj4mEferjd8tvDjk9guwI+0XuydJTzD4xP9kZydhBQpWH/N44/p0qj0tHp9/bKV8CB he51ZVmCGznsysWpIzHmrbmGrQMvjS4dLEJ9fr507aX/k/SEZXG19eJ84khcXexuDQ9z wOvbKCPfEnMSOblI+eIC75FjswBaiDiM75AAjmUtLjKgLMIO8abMlgBEQSm8Ckn1+7o4 /YrDOxqSVC5Yw+9ZNq4SWxrVPWb3IOnZcW2//xyC/HUMgBIpTzPy2M5poBig9o5p1fHC lhjzqt6TEB1KhJeP5tfxtqfVotGlhslEpaQZ5EY/1udkEMHI7OkXyJiIr1RpL1ZzPcT2 dWmQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linaro-uefi-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) smtp.mailfrom=linaro-uefi-bounces@lists.linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.linaro.org (ec2-54-197-127-237.compute-1.amazonaws.com. [54.197.127.237]) by mx.google.com with ESMTP id y80si5861900qkg.84.2018.03.01.19.50.40; Thu, 01 Mar 2018 19:50:40 -0800 (PST) Received-SPF: pass (google.com: domain of linaro-uefi-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) client-ip=54.197.127.237; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linaro-uefi-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) smtp.mailfrom=linaro-uefi-bounces@lists.linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 7E9C660721; Fri, 2 Mar 2018 03:50:40 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id 5FB0F617D5; Fri, 2 Mar 2018 03:50:21 +0000 (UTC) X-Original-To: linaro-uefi@lists.linaro.org Delivered-To: linaro-uefi@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 929A4617D5; Fri, 2 Mar 2018 03:50:17 +0000 (UTC) Received: from mail-wm0-f68.google.com (mail-wm0-f68.google.com [74.125.82.68]) by lists.linaro.org (Postfix) with ESMTPS id 5FAEE60698 for ; Fri, 2 Mar 2018 03:50:12 +0000 (UTC) Received: by mail-wm0-f68.google.com with SMTP id x7so687511wmc.0 for ; Thu, 01 Mar 2018 19:50:12 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=aLhZOXd0hJUlzbXyAYDSBtSFYUr+vLvE1ITaUP9Vo6E=; b=AQpGzha8gqtlCUMJS/iYD5asLPgqTPuIzbdBm8ifNIXbQrEve7TPW1nJT2pvv/ym1B naMsNuJVLWNrMBPZ0yuNU+v7snDZW0S3851ml0vFP9XXY1AlsAA2ZpyXWkESCN234iB2 n6pgVu5uAYliA5FZMkpNF8SLFB3zPEQFVnu/cyPjN96Q8Ceyqrm6zVHZ2YSU+JJjKbLq ueNDS9YZ57cIQhqNNBjGjVGhn/c2nujAO7TXbZ7EVw1Ev0RsQ8blQDws/H88pjse2HdK V/s3k2MnAjFcfGapKLJ+adMq2FF2vxLtvqQX8PPSwggtsuk2+BUrTrHk9UidPuAHwQmF LUOQ== X-Gm-Message-State: AElRT7FzDEePpJ+vEAjn/CLez181emurp3aG7ebwQkpsAnpf2JIyyarS 5TBJ+u8w4emvBapcgg73G2Cs8PcQ X-Received: by 10.28.22.145 with SMTP id 139mr313232wmw.56.1519962611486; Thu, 01 Mar 2018 19:50:11 -0800 (PST) Received: from hackbox.linaro.org ([81.128.185.36]) by smtp.gmail.com with ESMTPSA id e15sm567395wmd.26.2018.03.01.19.50.10 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 01 Mar 2018 19:50:10 -0800 (PST) From: Victor Chong To: leif.lindholm@linaro.org Date: Fri, 2 Mar 2018 03:49:44 +0000 Message-Id: <20180302034946.30580-2-victor.chong@linaro.org> X-Mailer: git-send-email 2.15.1 In-Reply-To: <20180302034946.30580-1-victor.chong@linaro.org> References: <20180302034946.30580-1-victor.chong@linaro.org> Cc: Victor Chong , linaro-uefi@lists.linaro.org Subject: [Linaro-uefi] [PATCH v2 1/3] atf, opteed: Support BL32_EXTRA1 and BL32_EXTRA2 X-BeenThere: linaro-uefi@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "For discussions about Linaro-related UEFI development. Not a substitute for edk2-devel." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: linaro-uefi-bounces@lists.linaro.org Sender: "Linaro-uefi" Previously, we were using a 'headless' version of optee_os binary for hikey and hikey960. With BL32_EXTRA1 and BL32_EXTRA2, we now enable optee_os header parsing to allow dynamic runtime support of either a 64- or 32-bit optee_os builds, and also the pager feature. Signed-off-by: Victor Chong --- atf-build.sh | 14 ++++++++++++-- opteed-build.sh | 4 ++++ 2 files changed, 16 insertions(+), 2 deletions(-) -- 2.15.1 diff --git a/atf-build.sh b/atf-build.sh index 5e03569..fb80ad0 100755 --- a/atf-build.sh +++ b/atf-build.sh @@ -67,7 +67,7 @@ function build_platform echo "PLATFORM_BUILDFLAGS=$PLATFORM_BUILDFLAGS" fi - unset BL30 BL31 BL32 BL33 + unset BL30 BL31 BL32 BL32_EXTRA1 BL32_EXTRA2 BL33 BL30="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o scp_bin`" if [ $ATF_BUILDVER -gt 1 ]; then unset SCP_BL2 @@ -100,9 +100,17 @@ function build_platform SPD="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o atf_spd`" TOS_BIN="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o tos_bin`" + TOS_BIN_EXTRA1="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o tos_bin_extra1`" + TOS_BIN_EXTRA2="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o tos_bin_extra2`" if [ X"$TOS_BIN" != X"" ]; then BL32=$WORKSPACE/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/$TOS_BIN fi + if [ X"$TOS_BIN_EXTRA1" != X"" ]; then + BL32_EXTRA1=$WORKSPACE/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/$TOS_BIN_EXTRA1 + fi + if [ X"$TOS_BIN_EXTRA2" != X"" ]; then + BL32_EXTRA2=$WORKSPACE/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/$TOS_BIN_EXTRA2 + fi if [ X"$SPD" != X"" ] && [ X"$BL32" != X"" ]; then # @@ -149,7 +157,7 @@ function build_platform ;; esac - export BL30 BL31 BL32 BL33 + export BL30 BL31 BL32 BL32_EXTRA1 BL32_EXTRA2 BL33 echo "BL30=$BL30" if [ $ATF_BUILDVER -gt 1 ] && [ X"$BL30" != X"" ]; then @@ -158,6 +166,8 @@ function build_platform fi echo "BL31=$BL31" echo "BL32=$BL32" + echo "BL32_EXTRA1=$BL32_EXTRA1" + echo "BL32_EXTRA2=$BL32_EXTRA2" echo "BL33=$BL33" echo "$SPD_OPTION" echo "BUILD_TYPE=$BUILD_TYPE" diff --git a/opteed-build.sh b/opteed-build.sh index 4de48d3..008e033 100755 --- a/opteed-build.sh +++ b/opteed-build.sh @@ -103,10 +103,14 @@ function build_platform # Copy resulting images to UEFI image dir # TOS_BIN="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o tos_bin`" + TOS_BIN_EXTRA1="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o tos_bin_extra1`" + TOS_BIN_EXTRA2="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o tos_bin_extra2`" if [ $VERBOSE -eq 1 ]; then echo "Copying '$TOS_BIN' to '$EDK2_DIR/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/'" fi cp -a out/arm-plat-"$TOS_PLATFORM"/core/"$TOS_BIN" "$EDK2_DIR/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/" + cp -a out/arm-plat-"$TOS_PLATFORM"/core/"$TOS_BIN_EXTRA1" "$EDK2_DIR/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/" + cp -a out/arm-plat-"$TOS_PLATFORM"/core/"$TOS_BIN_EXTRA2" "$EDK2_DIR/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/" else return 1 fi