From patchwork Wed Mar 17 19:55:02 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ilias Apalodimas X-Patchwork-Id: 403222 Delivered-To: patch@linaro.org Received: by 2002:a02:8562:0:0:0:0:0 with SMTP id g89csp777835jai; Wed, 17 Mar 2021 12:56:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw+Y7PsZa3uc6/DbBQxPMJsd6x9tDiHHhiag4BGcQGq+Qgvb+T7GlQ0QP2bMDpK8KVRH9cC X-Received: by 2002:a17:906:4107:: with SMTP id j7mr21181302ejk.185.1616010978529; Wed, 17 Mar 2021 12:56:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616010978; cv=none; d=google.com; s=arc-20160816; b=ityFgOZFKuoiEhUBo2cTuigDG4WMh0RSYWHWjazK8qwYy98IQJOKMpH6jCTaxErPMa iU0VT+X9W1WNPDeQf14/mnhrZiVInDBXAL9LBJbvdTYCAy5he3M+2hRZwaNBfnmcGmzm INH6/OEdazCxroRkLzYFpWkWqGTMVVvDCkQeRwE9CtQ4QbOqsCVjgPIJ3zv/ZyCXtRx/ wSnHXO+NUhda6irpKapeFvt2CvTxeQFgEkN9CFd/mlTCIZuUZlBK4gF8i7Bb+n72Z20G ygfU/Nst0Vpw1IjsfDuvyMnKJapG6KTDKxPXG3NYzabrBHzhK4n84cfKmSNa6d9Zj4CX I1Qg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=b4yBEWn5yECl/rzZ1xVHDu04NjaniuENu9JDQI28m+4=; b=oYTxt2gOHsKaOS5nJg5hHNHdgnXXnQHu5C9xRjwHBdpkZuAHN+ZCmpJff92mVqGuVq 6mFwRDOvRLTcWja1WZ/nkFNMAC4MsxD4woOR8AFGqrQNe1UD4mpJaX8e0w/hz1RVgWKR DvSHhPM6jzKmLZEz15M/3k4+liWN3+6hpITQh7y3tzX+sEAZAgfJAoCu7mtIcHdFF/Iy aOlxlyNOwre+VU7DOp6r5pDYqB3us6CBI5ZTaSbg47O+4gEF28QNnfg9QfA7siuVfKvr K7ONPhEEbs6c91cBsJMRVESzAfZn2o+nw7c8raoKe6oQQVUQu20Whbj5vNJr5/h66kvu RYmQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=BzhRIPfd; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [85.214.62.61]) by mx.google.com with ESMTPS id n12si16152083edo.340.2021.03.17.12.56.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Mar 2021 12:56:18 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) client-ip=85.214.62.61; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=BzhRIPfd; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 4D9BA8276D; Wed, 17 Mar 2021 20:55:40 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="BzhRIPfd"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id DD3138285A; Wed, 17 Mar 2021 20:55:35 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,SPF_HELO_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wr1-x42c.google.com (mail-wr1-x42c.google.com [IPv6:2a00:1450:4864:20::42c]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id C306982815 for ; Wed, 17 Mar 2021 20:55:29 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=ilias.apalodimas@linaro.org Received: by mail-wr1-x42c.google.com with SMTP id b9so3081466wrt.8 for ; Wed, 17 Mar 2021 12:55:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=b4yBEWn5yECl/rzZ1xVHDu04NjaniuENu9JDQI28m+4=; b=BzhRIPfd39v0HcpXUSxtuyPiwhLWZBfrGVbGgKvvxmE4N0Un2Qi7FeW3u5GL/Dm1na l1sYRmopUaWbhW9k9SkiTfzTCBcqMZI+3pCw1XqhLsZQl047D5Qf2uuVeE065NO4U4ER vVBh4jmMZ9a1vGxFIVe4ZN7dE/OvfGIRtTJnuew5v4OGlo0m7D8taTZeSwvKcAXYT2+S tKWMNFUBMyRJVuGqYPK2nA3AgcWVQyHAK5o6Bj0xQlooIzOovZdWNuWYF2GBKnAFfJsX Y9WnclY1EqmYrK+TmLxOMxPRcLofvBCnzCojtvjY4YFNXjCaJGwK6wPoh5d05VDbShH6 Gotw== 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:mime-version:content-transfer-encoding; bh=b4yBEWn5yECl/rzZ1xVHDu04NjaniuENu9JDQI28m+4=; b=sbN5F7bLUILCvDDRB5Bh5lMWY1vufUQGKHWxArVD5ltxCceR308/KKZFCpQxzhr9ea bCVljSEqMUBm9Ma3c8vsgL9nxFYfMs3bh01KTvNc5SFDM73t4PpTAZ6ylDb6kD4Dcgxf 0zb/Yp8C+qGi9k/oXRHDmozj+/oQHOb32I3y3L2LNcOJUyZ/0R3wqNpySB+xj8RnPItD 5SlZ0bBZooBZt+jL6P8z8bSh7FKeKyA2GO3SN5IYvx4/48m8BUpyJlKalv+Lz6kJ302+ yR8X5zJupACPF64pJYEFv4YdzWqZrIfHUSpsB9Qee7/7PCGT8uW51u0p1y5Gq1Re+21y EEXg== X-Gm-Message-State: AOAM530cu0u69aSNrd9sm7zCACx6O1HAUR8f1X4QOKf/ETZJKNTy9Olb crOvPgJmbywyORecdBZ72emygQ== X-Received: by 2002:adf:fb42:: with SMTP id c2mr6097018wrs.83.1616010929259; Wed, 17 Mar 2021 12:55:29 -0700 (PDT) Received: from localhost.localdomain (ppp-94-64-113-158.home.otenet.gr. [94.64.113.158]) by smtp.gmail.com with ESMTPSA id z82sm3343853wmg.19.2021.03.17.12.55.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Mar 2021 12:55:28 -0700 (PDT) From: Ilias Apalodimas To: xypron.glpk@gmx.de Cc: takahiro.akashi@linaro.org, Ilias Apalodimas , Alexander Graf , Sughosh Ganu , u-boot@lists.denx.de Subject: [PATCH 5/5 v4] doc: Update uefi documentation for initrd loading options Date: Wed, 17 Mar 2021 21:55:02 +0200 Message-Id: <20210317195505.337105-6-ilias.apalodimas@linaro.org> X-Mailer: git-send-email 2.31.0 In-Reply-To: <20210317195505.337105-1-ilias.apalodimas@linaro.org> References: <20210317195505.337105-1-ilias.apalodimas@linaro.org> MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.102.4 at phobos.denx.de X-Virus-Status: Clean Document the command line options for efidebug and initrd loading Signed-off-by: Ilias Apalodimas --- doc/uefi/uefi.rst | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) -- 2.31.0 diff --git a/doc/uefi/uefi.rst b/doc/uefi/uefi.rst index b3494c22e073..d92a32016ec0 100644 --- a/doc/uefi/uefi.rst +++ b/doc/uefi/uefi.rst @@ -180,6 +180,12 @@ Set up boot parameters on your board:: efidebug boot add -b 1 HELLO mmc 0:1 /helloworld.efi.signed "" +Since kernel 5.7 there's an alternative way of loading an initrd using +LoadFile2 protocol if CONFIG_EFI_LOAD_FILE2_INITRD is enabled. +The initrd path can be specified with:: + + efidebug boot add -b ABE0 'kernel' mmc 0:1 Image -i mmc 0:1 initrd + Now your board can run the signed image via the boot manager (see below). You can also try this sequence by running Pytest, test_efi_secboot, on the sandbox @@ -484,7 +490,21 @@ The load file 2 protocol can be used by the Linux kernel to load the initial RAM disk. U-Boot can be configured to provide an implementation with:: EFI_LOAD_FILE2_INITRD=y - EFI_INITRD_FILESPEC=interface dev:part path_to_initrd + +When the option is enabled the user can add the initrd path with the efidebug +command. + +Load options Boot#### have a FilePathList[] member. The first element of +the array (FilePathList[0]) is the EFI binary to execute. When an initrd +is specified the Device Path for the initrd is denoted by a VenMedia node +with the EFI_INITRD_MEDIA_GUID. Each entry of the array is terminated by the +'end of entire device path' subtype (0xff). If a user wants to define multiple +initrds, those must by separated by the 'end of this instance' identifier of +the end node (0x01). + +So our final format of the FilePathList[] is:: + + Loaded image - end node (0xff) - VenMedia - initrd_1 - [end node (0x01) - initrd_n ...] - end node (0xff) Links -----