From patchwork Wed Jun 21 07:22:34 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexandre Ghiti X-Patchwork-Id: 110849 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp4197970vqr; Wed, 21 Jun 2023 01:06:23 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6Dx1WVhwakJYZl60EG7kPqqGzG4KM/10VBAxH7rfdE0lcQ86SMbPN0sjVPMow91JdDBgaO X-Received: by 2002:ac8:7fd6:0:b0:3f6:bffe:3c02 with SMTP id b22-20020ac87fd6000000b003f6bffe3c02mr8993228qtk.45.1687334782896; Wed, 21 Jun 2023 01:06:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687334782; cv=none; d=google.com; s=arc-20160816; b=S58+0UJV2UWf3Mj4/jWiPcmmiwXrG0iyQ7QZi3MD7g6cXD+U7AAtAdBTIjlKscB8j/ jY3IZ7F1L4t/u3ZcVJjZ4KZES0YzlaseEittc/ADgBqguSfiyrZFnWWfpJaEPFxIRxFx 3fIAoINSHQRYD6ZbnxTU7GyMcRKh0vo9T7SPUmVQyIMgLYKSv5ubFwKWYlPqByBPs5Q/ gDTpMKGycrgxjXBccPTVjEki3/bikHzZvXuowxUs4sx9YRB8DQBhJXCUgwjWh1v2NceS SQiYRDKiV8SswkxOrylsOh3b2g5Gis/3cleKFDjRk6zMVogk14N9kgX1SwdYNOjmSL/l M+Ww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=YQDRIqOL25lhh2vW3phUacbtXDC/Hgmm9aSu83e6n78=; b=ySvr2FnUdjx0n7JYfqk/NJvrOAKZZwOuSFdQO8dizNWwKCe7eIsIgje1Ar90e7kuXL 0qe7l0GppBoE8Ksf/UFs0cH6mAgEnNW3t6+IE4rG8++9pXk67DaguiSBTW6qrnglnTrF Ce6tHlZBLc+bCePyeRHQp0V66wCuH4Hn448iBUgodBp2pxzzDYZulNk9H1sxBjBee/wI Kkdsp12H4h6NC5a7VdLyuymixp7kOZQhKHMxIKhG7iQVw8H12G7tS9e+L6Ys65zqmW5B GnLetVgdS8ANe2C+0nEzEAWBGUduwFrhB0S6ur44zQfNGL5EuoFAz6taHSdD4wqRNJBI CJaw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rivosinc-com.20221208.gappssmtp.com header.s=20221208 header.b=x1xZiuSc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u4-20020a17090a400400b0025679bf9761si3507922pjc.56.2023.06.21.01.06.10; Wed, 21 Jun 2023 01:06:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@rivosinc-com.20221208.gappssmtp.com header.s=20221208 header.b=x1xZiuSc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231411AbjFUHZD (ORCPT + 99 others); Wed, 21 Jun 2023 03:25:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55966 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229877AbjFUHYm (ORCPT ); Wed, 21 Jun 2023 03:24:42 -0400 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AA74DE6C for ; Wed, 21 Jun 2023 00:24:41 -0700 (PDT) Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-3f9b258f3d8so25149105e9.1 for ; Wed, 21 Jun 2023 00:24:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20221208.gappssmtp.com; s=20221208; t=1687332280; x=1689924280; 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=YQDRIqOL25lhh2vW3phUacbtXDC/Hgmm9aSu83e6n78=; b=x1xZiuScOCs29m4m9pPxoAs5kRoFSS8kxXOiTaBfJ84sHlZ9664m08lrFjOAnyDA4r GluBnz5W9XdgDQlJieE05espwRJ5BGtnyYHjFfqLuhWKNHyQE1V2OdOEs4WGtJhkdYyn E+6c9H8DAwTdQPWh30EDyF57rZuBbWHtfrXwoSV4LKYvcueXWpyMmAdPQmF0MEGZYr5e 9YckhhDptG8R6YxttjX08SH+x19OGMv610eFAoRiuDeCaW0qu+1iANLvc61fDTNQPY6e JNNWraib49EaorsHJkrKw0gA+RDawGSsyjhtJJxTtvJtamcBuDPdHPuURmVMCHTQR8jW oPmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687332280; x=1689924280; 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=YQDRIqOL25lhh2vW3phUacbtXDC/Hgmm9aSu83e6n78=; b=gmbv5u/7n7uyZCfq7bq1p+u2VwaiLIJ7czTxtryx555yfjYESP1TZaiYSvlZv2eo4a s+FaVD3Oce0RAG5yFSBIRs4PVNQqfLoBzRE6DziJC93Bid7pQbBZsfD7TYPZ7kdcvO36 f5igRMkHISYQkV/QMx9TVB1hv/XxX0X0jK4VvNkjR01JBXK4CaE3l2rjEiO8UgC0mnUA ypb1pAutpnPRJjdTVpuP47juzgYZTzLFTEAIGExtdn/6+09IhpRKOKy+qd14ZD7FRJny +GcicPUyBLCS5xoic1ON4EEeppYkdIOx+45dNc3WZokjUNGc0kAi7+BCoOw8ewEVvKDq hZxA== X-Gm-Message-State: AC+VfDy7k8ZXEktoySSLIGuH1SH/bNJ4Sib5bYmT4kSL5ro4rUCw1lTw +CZEx2S9S/uxxcKyktruWw/wIg== X-Received: by 2002:a05:600c:ad2:b0:3f9:bb86:bdd3 with SMTP id c18-20020a05600c0ad200b003f9bb86bdd3mr1606118wmr.7.1687332280108; Wed, 21 Jun 2023 00:24:40 -0700 (PDT) Received: from localhost.localdomain (amontpellier-656-1-456-62.w92-145.abo.wanadoo.fr. [92.145.124.62]) by smtp.gmail.com with ESMTPSA id u15-20020a05600c210f00b003f18b942338sm4181118wml.3.2023.06.21.00.24.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 21 Jun 2023 00:24:39 -0700 (PDT) From: Alexandre Ghiti To: Jonathan Corbet , Paul Walmsley , Palmer Dabbelt , Albert Ou , Conor Dooley , Sunil V L , Song Shuai , linux-doc@vger.kernel.org, linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org Cc: Alexandre Ghiti , Atish Patra Subject: [PATCH v2 3/3] Documentation: riscv: Update boot image header since EFI stub is supported Date: Wed, 21 Jun 2023 09:22:34 +0200 Message-Id: <20230621072234.9900-3-alexghiti@rivosinc.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230621072234.9900-1-alexghiti@rivosinc.com> References: <20230621072234.9900-1-alexghiti@rivosinc.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1769298757350276488?= X-GMAIL-MSGID: =?utf-8?q?1769298757350276488?= The EFI stub is supported on RISC-V so update the documentation that explains how the boot image header was reused to support it. Signed-off-by: Alexandre Ghiti Reviewed-by: Atish Patra Reviewed-by: Palmer Dabbelt Acked-by: Palmer Dabbelt --- Documentation/riscv/boot-image-header.rst | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Documentation/riscv/boot-image-header.rst b/Documentation/riscv/boot-image-header.rst index a4a45310c4c4..df2ffc173e80 100644 --- a/Documentation/riscv/boot-image-header.rst +++ b/Documentation/riscv/boot-image-header.rst @@ -28,11 +28,11 @@ header in future. Notes ===== -- This header can also be reused to support EFI stub for RISC-V in future. EFI - specification needs PE/COFF image header in the beginning of the kernel image - in order to load it as an EFI application. In order to support EFI stub, - code0 should be replaced with "MZ" magic string and res3(at offset 0x3c) should - point to the rest of the PE/COFF header. +- This header is also reused to support EFI stub for RISC-V. EFI specification + needs PE/COFF image header in the beginning of the kernel image in order to + load it as an EFI application. In order to support EFI stub, code0 is replaced + with "MZ" magic string and res3(at offset 0x3c) points to the rest of the + PE/COFF header. - version field indicate header version number