Skip to content
Snippets Groups Projects
  1. Jul 30, 2018
  2. Jul 21, 2018
  3. Jul 20, 2018
  4. Jul 19, 2018
    • Yaniv Levinsky's avatar
      env: common: accept flags on reset to default env · c5d548a9
      Yaniv Levinsky authored
      
      The function set_default_env() sets the hashtable flags for import_r().
      Formally set_default_env() doesn't accept flags from its callers. In
      practice the caller can (un)set the H_INTERACTIVE flag, but it has to be
      done using the first character of the function's string argument. Other
      flags like H_FORCE can't be set by the caller.
      
      Change the function to accept flags argument. The benefits are:
      1. The caller will have to explicitly set the H_INTERACTIVE flag,
         instead of un-setting it using a special char in a string.
      2. Add the ability to propagate flags from the caller to himport(),
         especially the H_FORCE flag from do_env_default() in nvedit.c that
         currently gets ignored for "env default -a -f" commands.
      3. Flags and messages will not be coupled together. A caller will be
         able to set flags without passing a string and vice versa.
      
      Please note:
      The propagation of H_FORCE from do_env_default() does not introduce any
      functional changes, because currently himport_r() is set to destroy the
      old environment regardless if H_FORCE flag is set or not. More changes
      are needed to utilize the propagation of H_FORCE.
      
      Signed-off-by: default avatarYaniv Levinsky <yaniv.levinsky@compulab.co.il>
      Acked-by: default avatarIgor Grinberg <grinberg@compulab.co.il>
      c5d548a9
    • Yaniv Levinsky's avatar
      cmd: nvedit: set H_INTERACTIVE in do_env_default · 5a04264e
      Yaniv Levinsky authored
      
      The function set_default_vars() in common.c adds H_INTERACTIVE to the
      h_import() flag, but the function has no way of telling if the command
      actually was user directed like this flag suggest. The flag should be
      set by the calling function do_env_default() in nvedit.c instead, where
      the command is certainty user directed.
      
      Move the H_INTERACTIVE flag from set_default_vars() to do_env_default().
      
      Signed-off-by: default avatarYaniv Levinsky <yaniv.levinsky@compulab.co.il>
      Acked-by: default avatarIgor Grinberg <grinberg@compulab.co.il>
      5a04264e
    • Yaniv Levinsky's avatar
      cmd: nvedit: propagate envflag to set_default_vars · 477f8116
      Yaniv Levinsky authored
      
      The env_flag in do_env_default() doesn't get propagated and therefore
      gets ignored by himport_r(). This breaks to ability to "forcibly" reset
      variables to their default values using the environment command.
      
      Scenario example of the problem:
      	# setenv kernel uImage
      	# setenv .flags kernel:so
      	# env default -f kernel
      	## Error: Can't overwrite "kernel"
      	himport_r: can't insert "kernel=zImage" into hash table
      
      Change the call path so it will pass the flag correctly.
      
      Signed-off-by: default avatarYaniv Levinsky <yaniv.levinsky@compulab.co.il>
      Acked-by: default avatarIgor Grinberg <grinberg@compulab.co.il>
      477f8116
    • Vipul Kumar's avatar
      env: Added support to save env to spi through Kconfig · 2a30809c
      Vipul Kumar authored
      
      This patch added support to enable CONFIG_ENV_SIZE, CONFIG_ENV_OFFSET
      and CONFIG_ENV_SECT_SIZE through Kconfig for Zynq and Zynqmp.
      
      Signed-off-by: default avatarVipul Kumar <vipul.kumar@xilinx.com>
      Signed-off-by: default avatarMichal Simek <michal.simek@xilinx.com>
      2a30809c
  5. Jun 13, 2018
  6. May 07, 2018
    • Tom Rini's avatar
      SPDX: Convert all of our single license tags to Linux Kernel style · 83d290c5
      Tom Rini authored
      
      When U-Boot started using SPDX tags we were among the early adopters and
      there weren't a lot of other examples to borrow from.  So we picked the
      area of the file that usually had a full license text and replaced it
      with an appropriate SPDX-License-Identifier: entry.  Since then, the
      Linux Kernel has adopted SPDX tags and they place it as the very first
      line in a file (except where shebangs are used, then it's second line)
      and with slightly different comment styles than us.
      
      In part due to community overlap, in part due to better tag visibility
      and in part for other minor reasons, switch over to that style.
      
      This commit changes all instances where we have a single declared
      license in the tag as both the before and after are identical in tag
      contents.  There's also a few places where I found we did not have a tag
      and have introduced one.
      
      Signed-off-by: default avatarTom Rini <trini@konsulko.com>
      83d290c5
  7. Apr 27, 2018
  8. Apr 16, 2018
  9. Apr 09, 2018
  10. Apr 07, 2018
    • Sjoerd Simons's avatar
      env: Properly check for BLK support · d48b8d11
      Sjoerd Simons authored
      
      Use CONFIG_IS_ENABLED to see if CONFIG_BLK is enabled. Otherwise
      SPL compilation breaks on boards which do have CONFIG_BLK enabled but
      not DM_MMC for the SPL as follows:
      
      env/mmc.c: In function ‘init_mmc_for_env’:
      env/mmc.c:164:6: warning: implicit declaration of function ‘blk_get_from_parent’; did you mean ‘efi_get_ram_base’? [-Wimplicit-function-declaration]
        if (blk_get_from_parent(mmc->dev, &dev))
            ^~~~~~~~~~~~~~~~~~~
            efi_get_ram_base
      env/mmc.c:164:29: error: ‘struct mmc’ has no member named ‘dev’
        if (blk_get_from_parent(mmc->dev, &dev))
                                   ^~
      
      Signed-off-by: default avatarSjoerd Simons <sjoerd.simons@collabora.co.uk>
      Reviewed-by: default avatarSimon Glass <sjg@chromium.org>
      d48b8d11
    • Rasmus Villemoes's avatar
      Allow providing default environment from file · f3d8f7dd
      Rasmus Villemoes authored
      
      Modifying the default environment via CONFIG_EXTRA_ENV_SETTINGS is
      somewhat inflexible, partly because the cpp language does not allow
      appending to an existing macro. This prevents reuse of "environment
      fragments" for different boards, which in turn makes maintaining that
      environment consistently tedious and error-prone.
      
      This implements a Kconfig option for allowing one to define the entire
      default environment in an external file, which can then, for example, be
      generated programmatically as part of a Yocto recipe, or simply be kept
      in version control separately from the U-boot repository.
      
      Tested-by: default avatarSean Nyekjaer <sean.nyekjaer@prevas.dk>
      Signed-off-by: default avatarRasmus Villemoes <rasmus.villemoes@prevas.dk>
      Reviewed-by: default avatarLukasz Majewski <lukma@denx.de>
      f3d8f7dd
  11. Apr 06, 2018
    • Christophe Leroy's avatar
      common: env_embedded: allow fine placement of environment object · 23ac79ff
      Christophe Leroy authored
      
      Commit 7653942b ("common/env_embedded.c: drop support for
      CONFIG_SYS_USE_PPCENV") dropped the .ppcenv section which was
      used in linking scripts to allow fine placement of embedded
      environment sections.
      
      This implies that GCC randomly places objects from env/embedded.o
      and environment is not guaranteed to be located at the correct address:
      
      04003df8 g     F .text  00000038 mii_init
      04004000 g     O .text  00000004 env_size
      04004004 g     O .text  00002000 environment
      04006004 g     F .text  00000040 .hidden __lshrdi3
      
      This patch restores this capability by allocating each object marked
      with __UBOOT_ENV_SECTION__ into a different section. Hence
      'environment' will be alone in .text.environment, allowing a
      fine placement in u-boot.lds with:
      
      		. = DEFINED(env_offset) ? env_offset : .;
      		env/embedded.o			(.text.environment)
      
      Fixes: 7653942b ("common/env_embedded.c: drop support for CONFIG_SYS_USE_PPCENV")
      Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Signed-off-by: default avatarChristophe Leroy <christophe.leroy@c-s.fr>
      23ac79ff
  12. Apr 04, 2018
  13. Mar 24, 2018
    • Petr Vorel's avatar
      Convert CONFIG_UBI_SILENCE_MSG to Kconfig · c0ce4cea
      Petr Vorel authored
      
      Signed-off-by: default avatarPetr Vorel <petr.vorel@gmail.com>
      c0ce4cea
    • Petr Vorel's avatar
      Convert CONFIG_UBIFS_SILENCE_MSG to Kconfig · afb6fda2
      Petr Vorel authored
      
      Introduce another difference from upstream (kernel) source in
      fs/ubifs/super.c: adding preprocessor condition as y variable in
      mount_ubifs() depends on CONFIG_UBIFS_SILENCE_MSG:
      fs/ubifs/super.c:1337:15: error: variable ?y? set but not used [-Werror=unused-but-set-variable]
        long long x, y;
      
      Not setting CONFIG_UBIFS_SILENCE_MSG in am335x_igep003x_defconfig and
      igep0032_defconfig. Although it was defined in their config headers, it
      depends on CMD_UBIFS which is not set for them.
      
      Signed-off-by: default avatarPetr Vorel <petr.vorel@gmail.com>
      Cc: Joe Hershberger <joe.hershberger@ni.com>
      Cc: Heiko Schocher <hs@denx.de>
      afb6fda2
  14. Feb 20, 2018
  15. Feb 16, 2018
  16. Feb 12, 2018
  17. Feb 01, 2018
  18. Jan 31, 2018
  19. Jan 27, 2018
Loading