From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 095A2C433F5 for ; Mon, 20 Sep 2021 12:19:02 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 66BD161040 for ; Mon, 20 Sep 2021 12:19:01 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 66BD161040 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id DF57E83257; Mon, 20 Sep 2021 14:18:58 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1632140339; bh=wa9IBJUemxHWbvHjE3rLtY/MvA2MLHfesFuXVDskqlo=; h=To:cc:From:Subject:In-reply-to:References:Date:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=lmCmJqXUntgEJuvxAk2XVVxtl/UE5c2ILKeOP1Vr1otWCy6Tsk7dVJ+1LjHRiYGMI aHNEQfrzpLsX3LeprEThZNIKiVQDTtIWscOWJkkEmyof7ril0lhdB5AcOZ+kXj7tlY nY37MMPB25dJ/tdMmWToH/KL9U3mg/pOummPUglRxakq3C1gG4Yk8T3I99ZCQCCgaA hilugzqaLjm+BFlAsJToJk79TL/hk857HomLXi4JuK3/ZcnPpeR+56KR2BrtAuvRrg 8PSyHkJSKGvJPmTYi/KKxs86Zkf7+qU16yfmAZb4y8nm1Au/WjV4xorzbxTBoHaItS lIUmY/yd/HvqQ== Received: from janitor.denx.de (unknown [62.91.23.180]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: noc@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 08E3383259 for ; Mon, 20 Sep 2021 14:18:57 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1632140337; bh=wa9IBJUemxHWbvHjE3rLtY/MvA2MLHfesFuXVDskqlo=; h=To:cc:From:Subject:In-reply-to:References:Date:From; b=WsF8xA+9d1eRng89SEDQJXwbNJna6WHBkmkcUt78Y9A2RVfbHphQWA+dH1QgEXnvb DUl7zXmnA64D+2w4l7IAQveZONt+dU2kqiNZnZIqAKTEqUPeSJpu+3nUguJQsKPEK6 yPt6TkuUJG3N/KTPGOMNEXkYMn6F60gUA738pdj381oFXpEpWjL82pOic2f6k2AxcO 2sANJd8tz+yfViJICG0jTrM3FMSc2thKCavcIm9RoOjHR8K8ASNfC7cxmaovQ7xdhH TVJMqZ5FRaFEnTnoYB2fJsdIb4lXleed9jUuu4DSiAdSPo5AgHdOlCfHHkIb4N6zYM ZOg8deft97qEQ== Received: by janitor.denx.de (Postfix, from userid 108) id 2B2BEA02A4; Mon, 20 Sep 2021 14:18:56 +0200 (CEST) Received: from gemini.denx.de (gemini.denx.de [10.4.0.2]) by janitor.denx.de (Postfix) with ESMTPS id 68E14A0058; Mon, 20 Sep 2021 14:18:48 +0200 (CEST) Received: from gemini.denx.de (localhost [IPv6:::1]) by gemini.denx.de (Postfix) with ESMTP id 580CF1E0F1B; Mon, 20 Sep 2021 14:18:48 +0200 (CEST) To: Simon Glass cc: U-Boot Mailing List , Tom Rini , Heinrich Schuchardt , Naoki Hayama , Patrick Delaunay , Rasmus Villemoes From: Wolfgang Denk Subject: Re: [PATCH v4 2/5] doc: Move environment documentation to rST MIME-Version: 1.0 Content-type: text/plain; charset=UTF-8 Content-transfer-encoding: 8bit In-reply-to: <20210919185950.3813952-3-sjg@chromium.org> References: <20210919185950.3813952-1-sjg@chromium.org> <20210919185950.3813952-3-sjg@chromium.org> Comments: In-reply-to Simon Glass message dated "Sun, 19 Sep 2021 12:59:47 -0600." Date: Mon, 20 Sep 2021 14:18:48 +0200 Message-ID: <1806581.1632140328@gemini.denx.de> 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.103.2 at phobos.denx.de X-Virus-Status: Clean Dear Simon, In message <20210919185950.3813952-3-sjg@chromium.org> you wrote: > Move this from the README to rST format. Just a few nitpicks... > diff --git a/doc/usage/environment.rst b/doc/usage/environment.rst > new file mode 100644 > index 00000000000..be785a8f717 > --- /dev/null > +++ b/doc/usage/environment.rst > @@ -0,0 +1,382 @@ > +.. SPDX-License-Identifier: GPL-2.0+ > + > +Environment Variables > +===================== > + > + > +U-Boot supports user configuration using Environment Variables which > +can be made persistent by saving to Flash memory. ...by saving to persistent storage, for example flash memory. > +Environment Variables are set using "setenv", printed using > +"printenv", and saved to Flash using "saveenv". Using "setenv" Environment Variables are set using "env set" (alias "setenv"), printed using "env print" (alias "printenv"), and saved to persistent storage using "env save" (alias "saveenv"). Using "env set" ... > +Some configuration options can be set using Environment Variables. This probably needs an explanation what "configuration options' means here? > +Image locations > +--------------- > + > +The following image location variables contain the location of images > +used in booting. The "Image" column gives the role of the image and is > +not an environment variable name. The other columns are environment > +variable names. "File Name" gives the name of the file on a TFTP > +server, "RAM Address" gives the location in RAM the image will be > +loaded to, and "Flash Location" gives the image's address in NOR > +flash or offset in NAND flash. > + > +*Note* - these variables don't have to be defined for all boards, some > +boards currently use other variables for these purposes, and some > +boards use these variables for other purposes. > + > +================= ============== ================ ============== > +Image File Name RAM Address Flash Location > +================= ============== ================ ============== > +u-boot u-boot u-boot_addr_r u-boot_addr > +Linux kernel bootfile kernel_addr_r kernel_addr > +device tree blob fdtfile fdt_addr_r fdt_addr > +ramdisk ramdiskfile ramdisk_addr_r ramdisk_addr > +================= ============== ================ ============== Maybe it should be pointed out that this is just a commonly used set of variable names, used in some other variable definitions, but is in no way hard coded anywhere in U-Boot code. OK, I see that "bootfile" and ""fdtfile" are now actually used in some code - but IMO this is a bad idea and should be fixed. > +Automatically updated variables > +------------------------------- > + > +The following environment variables may be used and automatically > +updated by the network boot commands ("bootp" and "rarpboot"), > +depending the information provided by your boot server: > + > +========= =================================================== > +Variable Notes > +========= =================================================== > +bootfile see above > +dnsip IP address of your Domain Name Server > +dnsip2 IP address of your secondary Domain Name Server > +gatewayip IP address of the Gateway (Router) to use > +hostname Target hostname > +ipaddr See above > +netmask Subnet Mask > +rootpath Pathname of the root filesystem on the NFS server > +serverip see above > +========= =================================================== This list is incomplete; for example, sysboot sets bootfile, too. For completeness, .flags etc. should be documented, too [but yes, this is a separate task of course]. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de I wrote my name at the top of the page. I wrote down the number of the question ``1''. After much reflection I put a bracket round it thus ``(1)''. But thereafter I could not think of anything connected with it that was either relevant or true. - Sir Winston Churchill _My Early Life_ ch. 2