From patchwork Sun Oct 18 05:14:47 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anup Patel X-Patchwork-Id: 1383799 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.infradead.org (client-ip=2001:8b0:10b:1231::1; helo=merlin.infradead.org; envelope-from=opensbi-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=wdc.com Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=merlin.20170209 header.b=OQAfeEeq; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=wdc.com header.i=@wdc.com header.a=rsa-sha256 header.s=dkim.wdc.com header.b=dpIZSLQu; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=sharedspace.onmicrosoft.com header.i=@sharedspace.onmicrosoft.com header.a=rsa-sha256 header.s=selector2-sharedspace-onmicrosoft-com header.b=RuWyBCdn; dkim-atps=neutral Received: from merlin.infradead.org (merlin.infradead.org [IPv6:2001:8b0:10b:1231::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4CDSlB3YYbz9sTR for ; Sun, 18 Oct 2020 16:15:33 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=jN6z59NZMfZIrldjwZK0FiiRxQHc5qTKZx/GXu+esoA=; b=OQAfeEeq6miWmKEaeLG8oBuGq lsy4Emfj7ZNzP+tbgmkCHryMxthzYw7MRTonQFH8VHiZ/25OrwuQ1m13hsl1XoQRVFcMJLjC9S1gI E4MmhFHS40iu1e3QtO6SRPsATkHhVS9oq9BXv4d5uY8ov+wlHJe5ipcLQ6QLwwjTEtsZ5zWASY0az VHuHG6L7ahRtTQVIZVRSmoxBYg10MVsMoDn9+mD/K64K+QGY4LbgwiMRReBV+TLYM/+qX9aldpIBd HeYYW6M8QsZzI5TJbVNuVukE3fmTgB65I6Mb/TjIRquQiSpeK5WxFZaweBoOwDLkEGCDSa3Q9BFDD RshfY2kAg==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kU12V-000160-MK; Sun, 18 Oct 2020 05:15:27 +0000 Received: from esa3.hgst.iphmx.com ([216.71.153.141]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kU12S-00014v-80 for opensbi@lists.infradead.org; Sun, 18 Oct 2020 05:15:25 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1602998125; x=1634534125; h=from:to:cc:subject:date:message-id:in-reply-to: references:content-transfer-encoding:mime-version; bh=gEZRgpeOC5lRb3pFi87RjPwRMLH4/O5KR2V6xEN7pUE=; b=dpIZSLQu4m2wTS1Fb/0yS8sMsx3D9W5iahNrKk+qJ08BqYBIf/uiRt71 4eLCW694WA6+v/X3BX7RxBmHuOy5Cq/k2VwNsbzAl66pzlXlt8D1xajDV WMOmFaO2I6WzjNTvx3Odweu1LIOhS8Iohm1jhFKTVMxecLikR26yRn3HD N5nybnb8rGumazBmKnZMUjuTuA+ijBbHPXVB24L/oT16pzvhnagXJfQxR mL1o1jtfJr8X6iSRO5AtQ7P8nh7jKRK7sCACiw18rOs+Qkw4XYRZj1HbE d6Y4Bp+dnDFJ6Ign998YdFlOB86+RjRp+E/YY01pWYt84+DS88fMd465x w==; IronPort-SDR: 9xLFafjVgAH3rbABNJkj0sQ3d/xg5q/Mj1Tarye7id3EklnMnjnXmyZI8gkZE+5RmsXIrbgWbT n9KJOxKCFwsuSOk0JuLa7Ge4LAa/ULgYenjeQlikgOU9aNW1qer+q1CnNf+W61uRMQE63ylW41 Mg9qtVdfegq+bwyn30n0UIfXMQFg6asGaVsLsITud2L1bTJX4Tcw68SsrMUOZSIeRldnXRzpYA GlxVTdZNwvh6a42hxEUOSc61aYmItdwtr3hDqXuUIcj5dbgXcC5HZ32Mlzef7wbBnNKJGbYofJ 8ys= X-IronPort-AV: E=Sophos;i="5.77,388,1596470400"; d="scan'208";a="154677435" Received: from mail-co1nam11lp2171.outbound.protection.outlook.com (HELO NAM11-CO1-obe.outbound.protection.outlook.com) ([104.47.56.171]) by ob1.hgst.iphmx.com with ESMTP; 18 Oct 2020 13:15:24 +0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=gzZjLs7HkfHYz7fQaaXjII8Tgea8bSxtGUhE3I/rbrz/YRgLVJEk1KcrV5BJGUvo5PG3Sr0Y60W3mZtsiFHLZF7c/9Wl8u4Od8R0YHTalGi59SS+2QhsPkkqee1XwzebSQXF4uREVxNvD9/wtB+q4NmVb68WpWXwCle4cg+htugMZuwZLxvQXbaciawFwmmcgNbBu1V49T8OkLacG619XepK3K7w85oTpBas0ftfeyODni2n9W0y9deAFRp23a6TPu2rRfl89OfcbJDxKrRug4dO5jgOKR73qbQQXiqUD7Cx+yIBzB+99xF+dxeMdFbnvAWZtpf2Be+B0UblSnMAbg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=88Ug7gQZZ3nRSqCoihNIFlE47iwZoWSaWdBhCcBZtn0=; b=itp9m43NJVEz7aas7W36FLjY0tLuzMnKiLVP6sP9N1OI8UmYLvBhV3V1AspQtUfwezbU/1NqcXUW6MDay7dAZ2UKmR8bHm1DHzBdMeXxj0SMAwxjXKwA9EpucnyPxtqJmUWjPZYEdIwUlZBOPHkeYKs+stZzvH83l/nUPIOX2D+0c6i/o+3E01fKdfLWX42vY1XOPxJ29s7OtkT6ICUYZ8jUTUchlEfTwqHLZODPTnawEO/9EtJ2ePHRu9cCE3jlvfPgzOo2cLmxkIVkAppTkQttG3JpUw5roo+bH2iYLDUZF/q83kYYzEMlCq9MepXKRv/kei4CfaNOYTR+zp1gqg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=wdc.com; dmarc=pass action=none header.from=wdc.com; dkim=pass header.d=wdc.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sharedspace.onmicrosoft.com; s=selector2-sharedspace-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=88Ug7gQZZ3nRSqCoihNIFlE47iwZoWSaWdBhCcBZtn0=; b=RuWyBCdnfQjdeoyGrX4owsKdJG1W5HMdaPjmzd4Tu1/SAh9AzN9TSJ5ilqJj5Hx8L5kUJC/FotUto64yJOVdXPCbkHZ1r81uqfU7MVsvf+4NI/ebW0HKoAQaj7Cy6uc27JpjTwjD9Gk2OljA+/LmUHdJkRQH5hZfh+kGxSboTrA= Authentication-Results: wdc.com; dkim=none (message not signed) header.d=none;wdc.com; dmarc=none action=none header.from=wdc.com; Received: from DM6PR04MB6201.namprd04.prod.outlook.com (2603:10b6:5:127::32) by DM5PR04MB0348.namprd04.prod.outlook.com (2603:10b6:3:72::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.20; Sun, 18 Oct 2020 05:15:22 +0000 Received: from DM6PR04MB6201.namprd04.prod.outlook.com ([fe80::d035:e2c6:c11:51dd]) by DM6PR04MB6201.namprd04.prod.outlook.com ([fe80::d035:e2c6:c11:51dd%6]) with mapi id 15.20.3477.028; Sun, 18 Oct 2020 05:15:22 +0000 From: Anup Patel To: Atish Patra , Alistair Francis Subject: [PATCH v2 3/5] firmware: Remove FW_PAYLOAD_FDT_PATH compile-time option Date: Sun, 18 Oct 2020 10:44:47 +0530 Message-Id: <20201018051449.2368918-4-anup.patel@wdc.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201018051449.2368918-1-anup.patel@wdc.com> References: <20201018051449.2368918-1-anup.patel@wdc.com> X-Originating-IP: [122.179.120.189] X-ClientProxiedBy: MAXPR0101CA0033.INDPRD01.PROD.OUTLOOK.COM (2603:1096:a00:d::19) To DM6PR04MB6201.namprd04.prod.outlook.com (2603:10b6:5:127::32) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from wdc.com (122.179.120.189) by MAXPR0101CA0033.INDPRD01.PROD.OUTLOOK.COM (2603:1096:a00:d::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Sun, 18 Oct 2020 05:15:19 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 2c7bb33e-fa86-4ab5-f784-08d87324cfab X-MS-TrafficTypeDiagnostic: DM5PR04MB0348: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: WDCIPOUTBOUND: EOP-TRUE X-MS-Oob-TLC-OOBClassifiers: OLM:8273; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 3PYfcXdOqW0k/3h92LyZeTkPeKx1qyMZwFDSvdvj2c2+tmKRAuhBizuLCg/RepGyxwB/LWa06+Yvc1ZMMBtHlpWHzsij4PQlP39w4+9iKTKnZQ/C0G94OXRKNzTOL39O4pL0rWtp2PUdx1HU9ex6iGqpnWlr5zHKDqga3WyJh5bgfoNeDH99Tjdt8eSTxbyNAxTUihfgeIGcxYOXaUpgrvUUJQ0tkv/ZZFZEFzBKteHpmDD9Yqx2CXqW63/9lI7fMJ8BFLBrl7gyw1HivNIE53udsOqRsSNK8qoDWRRl85q5YKVccDmVDXXanFpok7tIIubkmaXlRMJXVZLsYgOlzu3F5qWaeiyPHIPCAyJYnLze4Sud/JdojCcHZAVMN4J3hCMs6B9PO7/Sz7g0b9yvhw== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM6PR04MB6201.namprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(346002)(376002)(396003)(39850400004)(136003)(366004)(110136005)(316002)(478600001)(36756003)(966005)(6636002)(2906002)(956004)(2616005)(44832011)(6666004)(66946007)(5660300002)(86362001)(83380400001)(54906003)(66556008)(66476007)(8886007)(52116002)(7696005)(26005)(8936002)(8676002)(4326008)(55016002)(186003)(16526019)(1076003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData: yr8f6U9wEzqmuEBI/kbyAfnfWUZepoo1iz+MCuYjHvwaCITMFW6ZOyWmoBX6JPyFzRGqfEfTP/BGPLPj+e0939UGqA8rBNeYl6VYYNEazmUUrNprTPWlg7C6MfSdqEICLCY1OQObA0TEMdVBXRSbBAekUbQdUNmjxHHXNWZbIbOUcQywvpaOj7xV9Q7ZJO/ZggSEmW8uwp9wiSRcQ1tCe6d/3uYi7qmvdgDxRNpP9+DlOSBWpUdmRoOiCA6RxUYpoYY5s9xOicbhBiDRAoci7/nEUVOd5hCJcnRUBWkWBUQ5WqhmJWYHezg5pl62goAVg0Tea9vtgfMXejllbU4/+LH7fdTjr+L3yNdoOS29VIkcngLe2djLbPRu1vj4jRNE74pZAjafTkxr4HV7x0tyg7qH4h4roE8n3mZy/Tq8iAvSclM23yMp2Fmvki3Ug9wNtkHoF9O4mCfUFNIhxDnm95bQkzdoEPx7fMvr97NVM96ChFQgiwHDS5Xa5EccU55htFnogcvIDwpI3hBEv+ZBc4l13VdI9tNSq6i7brCWsXpSi1IQQLt1krMQNUR7r9T0+AgsZCwhdGBpqhTonEAptqzZ9np4lcyUqjh+5/j83MUJ1RjIZZsRdQvRKqM1QBFgqUb4vG+gLkl4kWUMposVNQ== X-OriginatorOrg: wdc.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2c7bb33e-fa86-4ab5-f784-08d87324cfab X-MS-Exchange-CrossTenant-AuthSource: DM6PR04MB6201.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Oct 2020 05:15:21.7063 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: b61c8803-16f3-4c35-9b17-6f65f441df86 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: tAx7pUGCuOvDshalWKynzlaYSagQGX7idxSuf/G3LRnkXW7VbwqzTnJmRlqutuSDXEPenBBDepPZ4cPo76VsWA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR04MB0348 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201018_011524_569558_6355A406 X-CRM114-Status: GOOD ( 20.18 ) X-Spam-Score: -2.5 (--) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (-2.5 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [216.71.153.141 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain 0.0 MSGID_FROM_MTA_HEADER Message-Id was added by a relay X-BeenThere: opensbi@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Anup Patel , Damien Le Moal , Anup Patel , opensbi@lists.infradead.org Sender: "opensbi" Errors-To: opensbi-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org The FW_PAYLOAD_FDT_PATH compile-time option is replaced by FW_FDT_PATH compile-time option which is more flexible and common across all OpenSBI firmwares. This patch removes FW_PAYLOAD_FDT_PATH and updates related documentation to use FW_FDT_PATH. Signed-off-by: Anup Patel Reviewed-by: Atish Patra --- docs/firmware/fw_payload.md | 9 ++------- docs/platform/andes-ae350.md | 4 ++-- docs/platform/shakti_cclass.md | 4 ++-- docs/platform/sifive_fu540.md | 6 +++--- firmware/external_deps.mk | 1 - firmware/fw_base.S | 9 --------- firmware/fw_dynamic.S | 13 ------------- firmware/fw_jump.S | 13 ------------- firmware/fw_payload.S | 25 ------------------------- firmware/objects.mk | 3 --- platform/template/config.mk | 4 +++- 11 files changed, 12 insertions(+), 79 deletions(-) diff --git a/docs/firmware/fw_payload.md b/docs/firmware/fw_payload.md index bc712d2..0947448 100644 --- a/docs/firmware/fw_payload.md +++ b/docs/firmware/fw_payload.md @@ -55,14 +55,9 @@ file. The parameters currently defined are as follows: automatically generated and used as a payload. This test payload executes an infinite `while (1)` loop after printing a message on the platform console. -* **FW_PAYLOAD_FDT_PATH** - Path to an external flattened device tree binary - file to be embedded in the *.text* section of the final firmware. If this - option is not provided then the firmware will expect the FDT to be passed - as an argument by the prior booting stage. - * **FW_PAYLOAD_FDT_ADDR** - Address where the FDT passed by the prior booting - stage or specified by the *FW_PAYLOAD_FDT_PATH* parameter and embedded in - the *.text* section will be placed before executing the next booting stage, + stage or specified by the *FW_FDT_PATH* parameter and embedded in the + *.rodata* section will be placed before executing the next booting stage, that is, the payload firmware. If this option is not provided, then the firmware will pass the FDT address passed by the previous booting stage to the next booting stage. diff --git a/docs/platform/andes-ae350.md b/docs/platform/andes-ae350.md index 5a98707..46889a1 100644 --- a/docs/platform/andes-ae350.md +++ b/docs/platform/andes-ae350.md @@ -19,12 +19,12 @@ Building Andes AE350 Platform ----------------------------- To use Linux v5.2 should be used to build Andes AE350 OpenSBI binaries by using -the compile time option FW_PAYLOAD_FDT_PATH. +the compile time option FW_FDT_PATH. AE350's dts is included in https://github.com/andestech/linux/tree/ast-v3_2_0-release-public **Linux Kernel Payload** ``` -make PLATFORM=andes/ae350 FW_PAYLOAD_PATH=/arch/riscv/boot/Image FW_PAYLOAD_FDT_PATH= +make PLATFORM=andes/ae350 FW_PAYLOAD_PATH=/arch/riscv/boot/Image FW_FDT_PATH= ``` diff --git a/docs/platform/shakti_cclass.md b/docs/platform/shakti_cclass.md index 2f4a699..05c9b3a 100644 --- a/docs/platform/shakti_cclass.md +++ b/docs/platform/shakti_cclass.md @@ -23,11 +23,11 @@ Building Shakti C-class Platform **Linux Kernel Payload** ``` -make PLATFORM=generic FW_PAYLOAD_PATH=/arch/riscv/boot/Image FW_PAYLOAD_FDT_PATH= +make PLATFORM=generic FW_PAYLOAD_PATH=/arch/riscv/boot/Image FW_FDT_PATH= ``` **Test Payload** ``` -make PLATFORM=generic FW_PAYLOAD_FDT_PATH= +make PLATFORM=generic FW_FDT_PATH= ``` diff --git a/docs/platform/sifive_fu540.md b/docs/platform/sifive_fu540.md index 1008432..c9513eb 100644 --- a/docs/platform/sifive_fu540.md +++ b/docs/platform/sifive_fu540.md @@ -29,13 +29,13 @@ DT (device tree) is not backward compatible with the DT passed from FSBL. To use Linux v5.2 (or higher, the pre-built DTB (DT binary) from Linux v5.2 (or higher) should be used to build SiFive FU540 OpenSBI binaries by using -the compile time option *FW_PAYLOAD_FDT_PATH*. +the compile time option *FW_FDT_PATH*. ``` make PLATFORM=sifive/fu540 FW_PAYLOAD_PATH=/arch/riscv/boot/Image or (For Linux v5.2 or higher) -make PLATFORM=sifive/fu540 FW_PAYLOAD_PATH=/arch/riscv/boot/Image FW_PAYLOAD_FDT_PATH= +make PLATFORM=sifive/fu540 FW_PAYLOAD_PATH=/arch/riscv/boot/Image FW_FDT_PATH= ``` **U-Boot Payload** @@ -147,7 +147,7 @@ booti ${kernel_addr_r} - ${fdt_addr_r} QEMU Specific Instructions -------------------------- If you want to test OpenSBI with QEMU 'sifive_u' machine, please follow the -same instructions above, with the exception of not passing FW_PAYLOAD_FDT_PATH. +same instructions above, with the exception of not passing FW_FDT_PATH. This is because QEMU generates a device tree blob on the fly based on the command line parameters and it's compatible with the one used in the upstream diff --git a/firmware/external_deps.mk b/firmware/external_deps.mk index f43ac06..6264005 100644 --- a/firmware/external_deps.mk +++ b/firmware/external_deps.mk @@ -12,4 +12,3 @@ $(platform_build_dir)/firmware/fw_jump.o: $(FW_FDT_PATH) $(platform_build_dir)/firmware/fw_payload.o: $(FW_FDT_PATH) $(platform_build_dir)/firmware/fw_payload.o: $(FW_PAYLOAD_PATH_FINAL) -$(platform_build_dir)/firmware/fw_payload.o: $(FW_PAYLOAD_FDT_PATH) diff --git a/firmware/fw_base.S b/firmware/fw_base.S index 95197da..1d9b375 100644 --- a/firmware/fw_base.S +++ b/firmware/fw_base.S @@ -187,15 +187,6 @@ _bss_zero: la a1, fw_fdt_bin #endif - /* Override previous arg1 */ - MOV_3R s0, a0, s1, a1, s2, a2 - call fw_prev_arg1 - add t1, a0, zero - MOV_3R a0, s0, a1, s1, a2, s2 - beqz t1, _prev_arg1_override_done - add a1, t1, zero -_prev_arg1_override_done: - /* * Initialize platform * Note: The a0 to a4 registers passed to the diff --git a/firmware/fw_dynamic.S b/firmware/fw_dynamic.S index d658011..8b56947 100644 --- a/firmware/fw_dynamic.S +++ b/firmware/fw_dynamic.S @@ -86,19 +86,6 @@ fw_save_info: 2: ret - .section .entry, "ax", %progbits - .align 3 - .global fw_prev_arg1 - /* - * We can only use a0, a1, and a2 registers here. - * The a0, a1, and a2 registers will be same as passed by - * previous booting stage. - * The previous arg1 should be returned in 'a0'. - */ -fw_prev_arg1: - add a0, zero, zero - ret - .section .entry, "ax", %progbits .align 3 .global fw_next_arg1 diff --git a/firmware/fw_jump.S b/firmware/fw_jump.S index afbcec0..8553f8c 100644 --- a/firmware/fw_jump.S +++ b/firmware/fw_jump.S @@ -34,19 +34,6 @@ fw_boot_hart: fw_save_info: ret - .section .entry, "ax", %progbits - .align 3 - .global fw_prev_arg1 - /* - * We can only use a0, a1, and a2 registers here. - * The a0, a1, and a2 registers will be same as passed by - * previous booting stage. - * The previous arg1 should be returned in 'a0'. - */ -fw_prev_arg1: - add a0, zero, zero - ret - .section .entry, "ax", %progbits .align 3 .global fw_next_arg1 diff --git a/firmware/fw_payload.S b/firmware/fw_payload.S index 9805d8c..1ef121e 100644 --- a/firmware/fw_payload.S +++ b/firmware/fw_payload.S @@ -34,23 +34,6 @@ fw_boot_hart: fw_save_info: ret - .section .entry, "ax", %progbits - .align 3 - .global fw_prev_arg1 - /* - * We can only use a0, a1, and a2 registers here. - * The a0, a1, and a2 registers will be same as passed by - * previous booting stage. - * The previous arg1 should be returned in 'a0'. - */ -fw_prev_arg1: -#ifdef FW_PAYLOAD_FDT_PATH - la a0, fdt_bin -#else - add a0, zero, zero -#endif - ret - .section .entry, "ax", %progbits .align 3 .global fw_next_arg1 @@ -102,14 +85,6 @@ fw_options: add a0, zero, zero ret -#ifdef FW_PAYLOAD_FDT_PATH - .section .text, "ax", %progbits - .align 4 - .globl fdt_bin -fdt_bin: - .incbin FW_PAYLOAD_FDT_PATH -#endif - .section .payload, "ax", %progbits .align 4 .globl payload_bin diff --git a/firmware/objects.mk b/firmware/objects.mk index 2eea54c..b2ace75 100644 --- a/firmware/objects.mk +++ b/firmware/objects.mk @@ -48,9 +48,6 @@ ifdef FW_PAYLOAD_ALIGN firmware-genflags-$(FW_PAYLOAD) += -DFW_PAYLOAD_ALIGN=$(FW_PAYLOAD_ALIGN) endif -ifdef FW_PAYLOAD_FDT_PATH -firmware-genflags-$(FW_PAYLOAD) += -DFW_PAYLOAD_FDT_PATH=\"$(FW_PAYLOAD_FDT_PATH)\" -endif ifdef FW_PAYLOAD_FDT_ADDR firmware-genflags-$(FW_PAYLOAD) += -DFW_PAYLOAD_FDT_ADDR=$(FW_PAYLOAD_FDT_ADDR) endif diff --git a/platform/template/config.mk b/platform/template/config.mk index 7bcf937..f817342 100644 --- a/platform/template/config.mk +++ b/platform/template/config.mk @@ -34,6 +34,9 @@ platform-ldflags-y = # Firmware load address configuration. This is mandatory. FW_TEXT_START=0x80000000 +# Optional parameter for path to external FDT +# FW_FDT_PATH="path to platform flattened device tree file" + # # Dynamic firmware configuration. # Optional parameters are commented out. Uncomment and define these parameters @@ -71,5 +74,4 @@ FW_PAYLOAD_OFFSET=0x200000 endif # FW_PAYLOAD_ALIGN=0x1000 # FW_PAYLOAD_PATH="path to next boot stage binary image file" -# FW_PAYLOAD_FDT_PATH="path to platform flattened device tree file" # FW_PAYLOAD_FDT_ADDR=0x82200000