From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Warren Date: Wed, 26 Jun 2013 14:16:44 -0600 Subject: [U-Boot] [PATCH v2 5/5] RFC: tegra: Convert to using environment files In-Reply-To: <1372106765-18401-6-git-send-email-sjg@chromium.org> References: <1372106765-18401-1-git-send-email-sjg@chromium.org> <1372106765-18401-6-git-send-email-sjg@chromium.org> Message-ID: <51CB4C2C.1000906@wwwdotorg.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 06/24/2013 02:46 PM, Simon Glass wrote: > This seems more intuitive that the current #define way of doing things. > The resulting code is shorter, avoids the quoting and line continuation > pain, and also improves the clumsy way that stdio variables are created: > > #ifdef CONFIG_VIDEO_TEGRA > #define STDOUT_LCD ",lcd" > #else > #define STDOUT_LCD "" > #endif > > ... > #define TEGRA_DEVICE_SETTINGS \ > "stdout=serial" STDOUT_LCD "\0" \ > ... > > The MEM_LAYOUT_ENV_SETTINGS variable is left in the header files, since > it depends on the SOC type and we probably don't want to add .emv files > for each board at this stage. Presumably e.g. seaboard.env could #include "tegra20.env" in order to allow *.env to define MEM_LAYOUT_ENV_SETTINGS? BTW, what's the #include -I path for these files? Perhaps it's worth setting it up as board/$vendor/$board/env board/$vendor/env arch/$arch/env to match the dtc+cpp patches I posted? > diff --git a/board/nvidia/env/common.env b/board/nvidia/env/common.env > +bootcmd_mmc0=setenv devnum 0; run mmc_boot > +bootcmd_mmc1=setenv devnum 1; run mmc_booxt > +boot_targets+= mmc1 mmc0 The first two lines there have no space after = and the last has space after +=. Does that get stripped? Should it? > diff --git a/include/configs/tegra-common-post.h b/include/configs/tegra-common-post.h > -#ifdef CONFIG_BOOTCOMMAND > - > -#define BOOTCMDS_COMMON "" > - > -#else ... Overall this change seems reasonable, but as I alluded to earlier, removing this from tegra-common-post.h will break Tegra boards for vendors other than NVIDIA. I guess that's part of why this patch is RFC.