Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp1854198pxk; Fri, 2 Oct 2020 23:40:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxr0jdc42LS9EAvHpEQraEReA3LuGMdIHTdm+Dfjn5lFxNFs2Y6rrCvMGU8MaGYu0LWYMxP X-Received: by 2002:aa7:d488:: with SMTP id b8mr6498498edr.21.1601707256377; Fri, 02 Oct 2020 23:40:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601707256; cv=none; d=google.com; s=arc-20160816; b=lv/goXj9NhC+W2MLr1yf9eains+FxFRHZdwyRcrClfNIvUWSOKIVNvymfczBpjTG9r 8r2onpHEHvi05Sy8EGYRQsAw5q9j3FQW3QZaob+W3LM3SLrY09o8rCtWGRNbJPFe3+pm eTHMMF2yXX7Cj7Ys9MCEi9N1TWfvaXmum/ZtHyacslSZlOHam2ZWYiF22jMOi0vDMI+T e4BJzNHank2oBZvezI9V46hdeNud9lX/2USBGpxN1XZS/Tbn8IsYQQoa+KJeU7YjXNuI an7T8bqi3kkKjnsGeteyVMs/TH+fUBHHWH8xMYXvwQQ9PoaekLR9nNJeZ2B5DUp0A4TL VpHw== 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=HhJ0GPsMwMf8n6VYoFdKfDn2+3Ce06M7sHf9hXFXOcU=; b=B5Ph9VmqHG1Qw3RoHEFbd8k1d8zXYDOsNpk5bMKJFdLCQEP6QSmAvGM1E2fW9JzRmZ SGZeGI2JOmLNTe0eAOChYl+f3+FuCqn17SiftSzyZq5tzFjW3lk5Pvo8nZKYsejpIlBs SulRWd5mn/ZB2UzrnjRN212GXkkY687b0kIBF559JEXl9FCRN1Hb5QKYizLbBcJUoeoA rUHtiZmzrwIdyjhc3C+8N4/FwZJzhrdOBY2JcKvtgNEZ73XEZxML/opAnGJgBZ2fANRg P5MHYWR7XgqlahdJsqg+P+fYk6ob/miciN8j3gCzBMAo/tuRN69NlsGfFLOONo/pTKbE It2Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmx.net header.s=badeba3b8450 header.b=MR2S4uqJ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f12si2849366edx.121.2020.10.02.23.40.06; Fri, 02 Oct 2020 23:40:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmx.net header.s=badeba3b8450 header.b=MR2S4uqJ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725801AbgJCGiP (ORCPT + 99 others); Sat, 3 Oct 2020 02:38:15 -0400 Received: from mout.gmx.net ([212.227.17.20]:47939 "EHLO mout.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725681AbgJCGiO (ORCPT ); Sat, 3 Oct 2020 02:38:14 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1601707074; bh=md0r0m36JBviEhAlMywLuogQp9PqQBA26y2UxZb0WKw=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date:In-Reply-To:References; b=MR2S4uqJT6zeEuMKunqAU8seXGD3k5im+o8JRx+AyzgzgMsGEcD8Koam5EqTpkEGi DKl47rQfF9z5WXK53+nFUAmNArPXCRTUC2t3//VRvzA8D8LcCTelrot4I4Ffhurubz HJYsllbeYRAS9/3sJ1z43gqo076pqTEp8G1Md0fE= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from LT02.fritz.box ([178.202.41.107]) by mail.gmx.com (mrgmx105 [212.227.17.174]) with ESMTPSA (Nemesis) id 1MulmF-1khESP2Q1j-00roqy; Sat, 03 Oct 2020 08:37:54 +0200 From: Heinrich Schuchardt To: Ard Biesheuvel Cc: Jonathan Corbet , Paul Walmsley , Palmer Dabbelt , Albert Ou , linux-efi@vger.kernel.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org, Atish Patra , Heinrich Schuchardt Subject: [PATCH v2 1/2] docs: admin-guide: fdt and initrd load in EFI stub Date: Sat, 3 Oct 2020 08:37:24 +0200 Message-Id: <20201003063725.8698-2-xypron.glpk@gmx.de> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201003063725.8698-1-xypron.glpk@gmx.de> References: <20201003063725.8698-1-xypron.glpk@gmx.de> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:GPrLsj9lxvHLBZU79XBKoGh3Tqybvf/pk+6ebZSYKfl9LsWZe9M BCkoXUBoP42pRKZvaX+A+f7GpZGLX8NUkJ00fdbt2e/rt22sk+FwjNk9mtxZSRZFSn5F4rw 8+ff7EHNinTQyOmdS5699oVnFYj+nzycp57KzC3APNGuh9q5SlCZlj5EKYdAE3W/4+AFaAZ VTNluNFlCUWY/fn2r0nNw== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:LQMjD0Ttnxc=:yjwDY+VJpjraaTbaIxLNtR UhWnTe+z00u8DzzGXQQsnF4y56JE6nS6AHEu5UXA0KG/dj2lEhhYzKP+Dw236eAMiT8gdU5aM IRhTjAz1HXwbOgL/Sc341q6i8M8nX9ctxs/eDdgU6np6kxjx8NqzQw5OaOEf6aCSI32mHa3C0 0lBj3r7iE5HO06W4ptJlCknGUA/bLpo7ceA+zFT2tSpLPI8NKKZ+S8c/BwH35/4g6vhj5+ZIo 7iFsNLg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ID: X-Mailing-List: linux-kernel@vger.kernel.org Describe how a device tree and an initial RAM disk can be passed to the EF= I Boot Stub. Signed-off-by: Heinrich Schuchardt =2D-- v2: mention EFI_GENERIC_STUB_INITRD_CMDLINE_LOADER (thx Atish) =2D-- Documentation/admin-guide/efi-stub.rst | 35 ++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/Documentation/admin-guide/efi-stub.rst b/Documentation/admin-= guide/efi-stub.rst index 833edb0d0bc4..4965dec48af4 100644 =2D-- a/Documentation/admin-guide/efi-stub.rst +++ b/Documentation/admin-guide/efi-stub.rst @@ -38,6 +38,34 @@ arch/arm/boot/zImage should be copied to the system par= tition, and it may not need to be renamed. Similarly for arm64, arch/arm64/boot/Image should be copied but not necessarily renamed. +Passing an initial RAM disk to the EFI Boot Stub +------------------------------------------------ + +The following means sorted by decreasing priority can be used to provide = an +initial RAM disk to the EFI Boot Stub: + +* The firmware may provide a UEFI Load File 2 Protocol. The stub will try= to + load the RAM disk by calling the LoadFile() service of the protocol usi= ng + a vendor device path with the vendor GUID + 5568e427-0x68fc-4f3d-ac74-ca555231cc68. +* Next the EFI stub will try to load the file indicated by the "initrd=3D= " command + line parameter if CONFIG_EFI_GENERIC_STUB_INITRD_CMDLINE_LOADER is enab= led. +* The prior boot stage may pass the location of the initial RAM disk via = the + "linux,initrd-start" and "linux,initrd-end" properties of the "/chosen"= node + of the device-tree. + +The first two items are inhibited by the "noinitrd" command line paramete= r. + +Passing a device-tree to the EFI Boot Stub +------------------------------------------ + +A device-tree can be passed to the EFI Boot Stub in decreasing priority u= sing + +* command line option dtb=3D +* a UEFI configuration table with GUID b1b621d5-f19c-41a5-830b-d9152c69aa= e0. + +The command line option is only available if CONFIG_EFI_ARMSTUB_DTB_LOADE= R=3Dy +and secure boot is disabled. Passing kernel parameters from the EFI shell -------------------------------------------- @@ -46,6 +74,10 @@ Arguments to the kernel can be passed after bzImage.efi= , e.g.:: fs0:> bzImage.efi console=3DttyS0 root=3D/dev/sda4 +The "noinitrd" option +--------------------- + +The "noinitrd" option stops the EFI stub from loading an initial RAM disk= . The "initrd=3D" option -------------------- @@ -98,3 +130,6 @@ CONFIGURATION TABLE. "dtb=3D" is processed in the same manner as the "initrd=3D" option that i= s described above. + +This option is only available if CONFIG_EFI_ARMSTUB_DTB_LOADER=3Dy and se= cure +boot is disabled. =2D- 2.28.0