From patchwork Mon Jan 29 05:48:22 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Haojian Zhuang X-Patchwork-Id: 126145 Delivered-To: patch@linaro.org Received: by 10.46.84.92 with SMTP id y28csp2158304ljd; Sun, 28 Jan 2018 21:48:42 -0800 (PST) X-Google-Smtp-Source: AH8x2254ydM7b5iore0N7aDRshFGu//PHWAJMZRVtEwhuCRrYKpCbELYcNNXjdZOOT3MvgzGiqnH X-Received: by 10.200.7.198 with SMTP id m6mr38692476qth.11.1517204922456; Sun, 28 Jan 2018 21:48:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517204922; cv=none; d=google.com; s=arc-20160816; b=de5aUeBK1X4/vasZcd+1v3xo+a/4PZqIUqIYrwddyDdmedtzHjwtkmJt8YaolhNRVk 3F/8p9Nyr7M8dMoLNIjYUCDhMFnYtUSHXZu8/Zp1TVNzD9YUg/1TwXSUMHefADhgAzuR HWzf43BJTS2Wbw7oqBEll6ic7kkt2sw6emr4DPRUFYgBia5eeZ+wRbPYoWs8+LBUZTmw ANpSkjtg0Bp42mcwZtJGktNnce1a50Oesu7frzsBC85jTyXJMgUPg1D74I9VAwCcUzQR 6X39bqLPIddsos3BZSfqjjEIDmZRH6/ve1L+rnOYvohK7HjktzFn9WHYgeofgHrEBhMO x4tw== 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:message-id:date:to:from:delivered-to :arc-authentication-results; bh=kbXHdm9OCb+ShE7Vz2SluuwZOCoFcjtPxd2L+bChArE=; b=Bt1G7q8LzQlt6197w4qPQXvK7ZG+mu2cG4dNQvdbqPRPveZ61FYSrj+Sw9pWUNMPg+ Wjg+VbL7Uwyqs3FYMowkQxELoQSzLb5oHytQNEHWtRO4tDEmbsiDaOFe9ig/fhoG7vbF RkngToa+fwWEipLlJT68RtyPhuGHm+fL6mrMYbLA381+aS0i+AOdAVxp8tpVxDwJeSy3 TO/ZIeYCzJk7Y1JI65GIrLQ2qQUmMpyspxbV4VQSgpVUfBUFnIG4bIQhAH8b3+bY+GIb Y6nUsFewBCgNx63DmS74owxz4i5AAHcBW8WEGfqkWn9LYdjYoH9BfQ0xcI3xlcNoJ7qN nBBw== 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 u29si6762477qke.42.2018.01.28.21.48.41; Sun, 28 Jan 2018 21:48:42 -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 98BF56174F; Mon, 29 Jan 2018 05:48:41 +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 B355061512; Mon, 29 Jan 2018 05:48:37 +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 3D2E5616F8; Mon, 29 Jan 2018 05:48:36 +0000 (UTC) Received: from mail-pg0-f67.google.com (mail-pg0-f67.google.com [74.125.83.67]) by lists.linaro.org (Postfix) with ESMTPS id 241FC60D8D for ; Mon, 29 Jan 2018 05:48:35 +0000 (UTC) Received: by mail-pg0-f67.google.com with SMTP id j16so2217621pgn.9 for ; Sun, 28 Jan 2018 21:48:35 -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; bh=mctPiyCAPb9xlSS4fhwl+cTNyYJZMDzEXevhrkEy3EU=; b=MxxhhNwRzNLKP27a3L8A48TAV3OI6sfRDEgzNwU+LXFujdxRI0MYT22t6x+YDspUnJ q0l8LrKVZA4pLIyUuM4wTyDugTMgcJ56Jq3TLP5ZOsHku6Bbx+qJ/nsIuKaDQjaGQAnk GaVbtbekEy1/cBm6KK8g8hpNSQwtoHxnGwoQk4Jd6zSuSWheqkoM4ePjbK/KC0A4poYo h209HfJNq4Wkil8Ji8BQsVUyft1tfuB/Lmaf/IaarXQd+9Jzxgok7VtmV+8iKpmzILmc vuzzZnyGSLZz/r47jldOFMnPw0T3Z60en/yGUPg2wonwMX7GMKeo0drGsuGeBSfRhH8i 572Q== X-Gm-Message-State: AKwxyteI0oiocdv5iwDss0SUVo0xUCKgZxoQkl+GM5to/smqxMtsst9R M6gp0pmBPjmyYdj6kPZWve/5PWYpkgAPEw== X-Received: by 2002:a17:902:b413:: with SMTP id x19-v6mr113855plr.420.1517204914156; Sun, 28 Jan 2018 21:48:34 -0800 (PST) Received: from localhost.localdomain ([45.56.159.198]) by smtp.gmail.com with ESMTPSA id e4sm26059180pff.116.2018.01.28.21.48.30 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 28 Jan 2018 21:48:33 -0800 (PST) From: Haojian Zhuang To: linaro-uefi@lists.linaro.org, leif.lindholm@linaro.org, ard.biesheuvel@linaro.org Date: Mon, 29 Jan 2018 13:48:22 +0800 Message-Id: <1517204902-23796-1-git-send-email-haojian.zhuang@linaro.org> X-Mailer: git-send-email 2.7.4 Subject: [Linaro-uefi] [PATCH] atf-build: migrate to bl2_el3 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" When migrate to BL2_EL3 in ARM Trusted Firmware, bl2.bin should be built out of fip.bin. Otherwise, non-TF ROM failes to load bl2.bin because it doesn't recognize fip.bin format. So copy bl2.bin to UEFI folder after ATF built. Signed-off-by: Haojian Zhuang --- atf-build.sh | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/atf-build.sh b/atf-build.sh index 65d4dbc..db741f5 100755 --- a/atf-build.sh +++ b/atf-build.sh @@ -182,9 +182,15 @@ function build_platform # Copy resulting images to UEFI image dir # if [ $VERBOSE -eq 1 ]; then - echo "Copying bl1.bin and fip.bin to "$WORKSPACE/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/"" + echo "Copying bl1.bin bl2.bin and fip.bin to "$WORKSPACE/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/"" fi - cp -a build/"$ATF_PLATFORM/$BUILD_TYPE"/{bl1,fip}.bin "$WORKSPACE/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/" + if [ -f build/"$ATF_PLATFORM/$BUILD_TYPE"/bl1.bin ]; then + cp -a build/"$ATF_PLATFORM/$BUILD_TYPE"/bl1.bin "$WORKSPACE/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/" + fi + if [ -f build/"$ATF_PLATFORM/$BUILD_TYPE"/bl2.bin ]; then + cp -a build/"$ATF_PLATFORM/$BUILD_TYPE"/bl2.bin "$WORKSPACE/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/" + fi + cp -a build/"$ATF_PLATFORM/$BUILD_TYPE"/fip.bin "$WORKSPACE/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/" else return 1 fi