From patchwork Thu Nov 2 06:44:59 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahisa Kojima X-Patchwork-Id: 740435 Delivered-To: patch@linaro.org Received: by 2002:a5d:538f:0:b0:32d:baff:b0ca with SMTP id d15csp672860wrv; Wed, 1 Nov 2023 23:48:47 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGlTzs08LTW6rlFpQYWKqwzzmXRRXc/l6dC60tPF7MVjZL5tROO0SovcrDIxJkdyqMfDMG7 X-Received: by 2002:a5d:6789:0:b0:32f:ace2:15ac with SMTP id v9-20020a5d6789000000b0032face215acmr338892wru.59.1698907727793; Wed, 01 Nov 2023 23:48:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698907727; cv=none; d=google.com; s=arc-20160816; b=PnN/qeSzl/Z72/6XQ/JxC+S6nvgEA9XKeaQJQS5fseWZeAVeqomUdVRMhBPg/h8KiV Wm/LkWIrps5L4+EKRkJr4L9jSZkTsS1V9FAXC64U3cpZRHiat8XN+ZNzUoQLNbZ2H7hq KZnv7eRPGmWdHoPRn7qB1N2nQgT/00hpuBgZRwepprBcrivu6/H/vqXVcd0r0AagEFJ1 duRDR2zOL65zmU/xAl7mR/7u/XMn1x1UhuPB7n2BXXTXPIr/v3q5tGRbv74Gj3WX7tRz Paeyen/4XByvYmLcMJhC+msfUn4ajGjSKoT/StWmn5psJ7+Yt77XH/xyykHt5zLNowk0 BQtg== 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=9yfAtkx/MLAaC2e3oTVCEdGrlnmIaFPaJzkqM3lqaYU=; fh=I7E+BwgHMByijVVN/pPHsLSpz7oP4y4e73noHEekrEE=; b=xFUFZ2YihNjuTLUdWxez7tkQPDVcokGhGgOAG1Va2ROarVkmbr6l7tq241I48+dBVG Np/zblAD7AlKkLhAPlWHFwGXNpRAkgxgxt/YTSpLyO/eTgRYaTGmbHXVykjDVv8YnUzo PSbiKcHkl7y/7BD4tRWZJtxK6UqJ/X+Y5zjOD+mr9EZLIBIB/ePeoc931cnhWd7iGby0 g0QrPctBMT8YBYNl2Qym3DzzrnAq+Q4asSNpKahW5URC82zoiGSfBPu7iOX37C/Ek05I 1K384LJpP5NzNae4jZwhrYpQgzcG8A4s87uXtw1AuU0jykzz1SIoFbD0ClASz6tGjsXk GKGg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ClOmdnkO; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 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. [2a01:238:438b:c500:173d:9f52:ddab:ee01]) by mx.google.com with ESMTPS id n2-20020a5d4202000000b0032da29266fbsi963430wrq.678.2023.11.01.23.48.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Nov 2023 23:48:47 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ClOmdnkO; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 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 EED3D8771C; Thu, 2 Nov 2023 07:46:57 +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="ClOmdnkO"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 83735876AE; Thu, 2 Nov 2023 07:46:54 +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=-0.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NUMERIC_HTTP_ADDR,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-pg1-x534.google.com (mail-pg1-x534.google.com [IPv6:2607:f8b0:4864:20::534]) (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 60BC186F26 for ; Thu, 2 Nov 2023 07:46:50 +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=masahisa.kojima@linaro.org Received: by mail-pg1-x534.google.com with SMTP id 41be03b00d2f7-5aaebfac4b0so439178a12.2 for ; Wed, 01 Nov 2023 23:46:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1698907608; x=1699512408; darn=lists.denx.de; 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=9yfAtkx/MLAaC2e3oTVCEdGrlnmIaFPaJzkqM3lqaYU=; b=ClOmdnkO/q0kR7oTl+9SsxxWY+hvvy+vL9S4RI0vPXv7Y+wveSWkWiQ7U4DJQydvPD Q2pP/7SgkfRE1P+h/BwbmzVJbk7QKHRQaQ5lthUe4NICqJR9Z2bApRGTL0VjQN1oeTU1 FeO43wbFs8ykePaDYLLb47GAwhX9glP3hHjSTBvw0VmjMgyynVi0gTJZTWCb9fLozn2+ gXNJlGYvdUPka+ynjnWW2ZBEa/PPCF6i1K7Oy4JQNF8+w3F0fUHEVFtCa7s9b7j4c0qe yYUB7U+b/oprqumj2pGNVdAle8Cn+n48Jk49xDmyEDao+adcSe1LmrgPLep2a6pUXKp+ MZoQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698907608; x=1699512408; 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=9yfAtkx/MLAaC2e3oTVCEdGrlnmIaFPaJzkqM3lqaYU=; b=WFIk/sNv8IYoUJJcMFEAtsLxvdk2HUDfh0iW/p0+RvRIHqbdu5klCXCeZwVUld/c8Y C9R1TT7GrH7p3F4Ut8tWgGsKBSX/TPOv7zJVdXCNYlG/4sLSVuYadkzzFFZ+CCySXvKX hh6T45IsLsQmIHrCXAtSSONO/KDVutKTMKwyXKcvPw9IoIzh/ne2u1qi3fkr1L2Lf/NN C+bmF1NiSSwRgS9k2Zc1ogTdjZsTiyI6xj6u1QMBOQ2qg2tD+5QvGhvwVjXT9PnOGi1C gHwSv+dGoC2JC6Tosw+zvoYetaTgaag9+WsZjqur5UBL77c9gm0ne6AQH99kbco4/SOC Cf4g== X-Gm-Message-State: AOJu0YyBaWN88ZFDF8veahBXBKS89Pj9nr4jwFlOUn4Oui2r+CjPoUjV QxKrwI4fUPBvxyRtMsZG2EEucZztoo30/QZhGfI= X-Received: by 2002:a05:6a20:431c:b0:181:9b65:b4b5 with SMTP id h28-20020a056a20431c00b001819b65b4b5mr965182pzk.3.1698907608448; Wed, 01 Nov 2023 23:46:48 -0700 (PDT) Received: from localhost ([164.70.16.189]) by smtp.gmail.com with ESMTPSA id x18-20020a17090300d200b001bfd92ec592sm2328697plc.292.2023.11.01.23.46.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Nov 2023 23:46:47 -0700 (PDT) From: Masahisa Kojima To: u-boot@lists.denx.de Cc: Heinrich Schuchardt , Ilias Apalodimas , Simon Glass , Takahiro Akashi , Michal Simek , Masahisa Kojima Subject: [PATCH v9 9/9] doc: uefi: add HTTP Boot support Date: Thu, 2 Nov 2023 15:44:59 +0900 Message-Id: <20231102064459.3466953-10-masahisa.kojima@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231102064459.3466953-1-masahisa.kojima@linaro.org> References: <20231102064459.3466953-1-masahisa.kojima@linaro.org> MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 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.103.8 at phobos.denx.de X-Virus-Status: Clean This adds the description about HTTP Boot. Signed-off-by: Masahisa Kojima Reviewed-by: Ilias Apalodimas --- doc/develop/uefi/uefi.rst | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/doc/develop/uefi/uefi.rst b/doc/develop/uefi/uefi.rst index fb16ac743a..ca9a573669 100644 --- a/doc/develop/uefi/uefi.rst +++ b/doc/develop/uefi/uefi.rst @@ -642,6 +642,36 @@ UEFI variables. Booting according to these variables is possible via:: As of U-Boot v2020.10 UEFI variables cannot be set at runtime. The U-Boot command 'efidebug' can be used to set the variables. +UEFI HTTP Boot +~~~~~~~~~~~~~~ + +HTTP Boot provides the capability for system deployment and configuration +over the network. HTTP Boot can be activated by specifying:: + + CONFIG_CMD_DNS + CONFIG_CMD_WGET + CONFIG_BLKMAP + +Set up the load option specifying the target URI:: + + efidebug boot add -u 1 netinst http://foo/bar + +When this load option is selected as boot selection, resolve the +host ip address by dns, then download the file with wget. +If the downloaded file extension is .iso or .img file, efibootmgr tries to +mount the image and boot with the default file(e.g. EFI/BOOT/BOOTAA64.EFI). +If the downloaded file is PE-COFF image, load the downloaded file and +start it. + +The current implementation tries to resolve the IP address as a host name. +If the uri is like "http://192.168.1.1/foobar", +the dns process tries to resolve the host "192.168.1.1" and it will +end up with "host not found". + +We need to preset the "httpserverip" environment variable to proceed the wget:: + + setenv httpserverip 192.168.1.1 + Executing the built in hello world application ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~