1. 29 10月, 2018 2 次提交
    • A
      sunxi: store DRAM size in SPL header · 5776610e
      Andre Przywara 提交于
      At the moment we rely on the infamous get_ram_size() function to learn
      the actual DRAM size in U-Boot proper. This function has two issues:
      1) It only works if the DRAM size is a power of two. We start to see
      boards which have 3GB of (usable) DRAM, so this does not fit anymore.
      2) As U-Boot has no notion of reserved memory so far, it will happily
      ride through the DRAM, possibly stepping on secure-only memory. This
      could be a region of DRAM reserved for OP-TEE or some other secure
      payload, for instance. It will most likely crash in that case.
      
      As the SPL DRAM init routine has very accurate knowledge of the actual
      DRAM size, lets propagate this wisdom to U-Boot proper.
      We re-purpose a currently reserved word in our SPL header for that.
      The SPL itself stores the detected DRAM size there, and bumps the SPL
      header version number in that case. U-Boot proper checks for a valid
      SPL header and a high enough version number, then uses the DRAM size
      from there. If the SPL header field is not sufficient, we fall back to
      the old DRAM scanning routine.
      
      Part of the DRAM might be present and probed by SPL, but not accessible
      by the CPU. They're restricted in the main U-Boot binary, when accessing
      the DRAM size from SPL header.
      Signed-off-by: NAndre Przywara <andre.przywara@arm.com>
      Signed-off-by: NIcenowy Zheng <icenowy@aosc.io>
      Acked-by: NMaxime Ripard <maxime.ripard@bootlin.com>
      Reviewed-by: NJagan Teki <jagan@openedev.com>
      5776610e
    • A
      sunxi: Extend SPL header versioning · 55d481d2
      Andre Przywara 提交于
      On Allwinner SoCs we use some free bytes at the beginning of the SPL image
      to store various information. We have a version byte to allow updates,
      but changing this always requires all tools to be updated as well.
      
      Introduce the concept of semantic versioning [1] to the SPL header:
      The major part of the version number only changes on incompatible
      updates, a minor number bump indicates backward compatibility.
      This patch just documents the major/minor split, adds some comments
      to the header file and uses the versioning information for the existing
      users.
      
      [1] https://semver.orgSigned-off-by: NAndre Przywara <andre.przywara@arm.com>
      Signed-off-by: NIcenowy Zheng <icenowy@aosc.io>
      Acked-by: NMaxime Ripard <maxime.ripard@bootlin.com>
      Acked-by: NJagan Teki <jagan@openedev.com>
      55d481d2
  2. 31 7月, 2018 1 次提交
  3. 07 5月, 2018 1 次提交
    • T
      SPDX: Convert all of our single license tags to Linux Kernel style · 83d290c5
      Tom Rini 提交于
      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: NTom Rini <trini@konsulko.com>
      83d290c5
  4. 04 10月, 2017 1 次提交
  5. 18 5月, 2017 1 次提交
    • S
      sunxi: Store the device tree name in the SPL header · 7f0ef5a9
      Siarhei Siamashka 提交于
      This patch updates the mksunxiboot tool to optionally add
      the default device tree name string to the SPL header. This
      information can be used by the firmware upgrade tools to
      protect users from harming themselves by trying to upgrade
      to an incompatible bootloader.
      
      The primary use case here is a non-removable bootable media
      (such as NAND, eMMC or SPI flash), which already may have
      a properly working, but a little bit outdated bootloader
      installed. For example, the user may download or build a
      new U-Boot image for "Cubieboard", and then attemept to
      install it on a "Cubieboard2" hardware by mistake as a
      replacement for the already existing bootloader. If this
      happens, the flash programming tool can identify this
      problem and warn the user.
      
      The size of the SPL header is also increased from 64 bytes
      to 96 bytes to provide enough space for the device tree name
      string.
      [Andre: split patch to remove OF_LIST hash feature]
      Signed-off-by: NSiarhei Siamashka <siarhei.siamashka@gmail.com>
      Signed-off-by: NAndre Przywara <andre.przywara@arm.com>
      7f0ef5a9
  6. 05 4月, 2017 1 次提交
    • A
      sunxi: Kconfig: introduce CONFIG_SUNXI_HIGH_SRAM · bc613d85
      Andre Przywara 提交于
      Traditionally Allwinner SoCs have their boot ROM mapped just below 4GB,
      while the first SRAM region is mapped at address 0.
      With the extended physical memory support of the A80 this was changed,
      so the BROM is now at address 0 and the SRAM region starts right behind
      this at 64KB. This configuration seems to be called "high SRAM".
      Instead of enumerating the SoCs which have copied this configuration,
      let's call a spade a spade and introduce a Kconfig option for this setup.
      SoCs implementing this (A80, A64 and H5, so far), can then select this
      configuration.
      Simplify the config header definition on the way.
      Signed-off-by: NAndre Przywara <andre.przywara@arm.com>
      Acked-by: NMaxime Ripard <maxime.ripard@free-electrons.com>
      Reviewed-by: NJagan Teki <jagan@openedev.com>
      bc613d85
  7. 15 7月, 2016 1 次提交
    • B
      sunxi: FEL - Add the ability to recognize and auto-import uEnv-style data · 320e0570
      Bernhard Nortmann 提交于
      The patch converts one of the "reserved" fields in the sunxi SPL
      header to a fel_uEnv_length entry. When booting over USB ("FEL
      mode"), this enables the sunxi-fel utility to pass the string
      length of uEnv.txt compatible data; at the same time requesting
      that this data be imported into the U-Boot environment.
      
      If parse_spl_header() in the sunxi board.c encounters a non-zero
      value in this header field, it will therefore call himport_r() to
      merge the string (lines) passed via FEL into the default settings.
      Environment vars can be changed this way even before U-Boot will
      attempt to autoboot - specifically, this also allows overriding
      "bootcmd".
      
      With fel_script_addr set and a zero fel_uEnv_length, U-Boot is
      safe to assume that data in .scr format (a mkimage-type script)
      was passed at fel_script_addr, and will handle it using the
      existing mechanism ("bootcmd_fel").
      Signed-off-by: NBernhard Nortmann <bernhard.nortmann@web.de>
      Acked-by: NSiarhei Siamashka <siarhei.siamashka@gmail.com>
      Signed-off-by: NHans de Goede <hdegoede@redhat.com>
      320e0570
  8. 02 7月, 2016 1 次提交
  9. 25 5月, 2016 1 次提交
    • S
      sunxi: Increase SPL header size to 64 bytes to avoid code corruption · b19236fd
      Siarhei Siamashka 提交于
      The current SPL header, created by the 'mksunxiboot' tool, has size
      32 bytes. But the code in the boot ROM stores the information about
      the boot media at the offset 0x28 before passing control to the SPL.
      For example, when booting from the SD card, the magic number written
      by the boot ROM is 0. And when booting from the SPI flash, the magic
      number is 3. NAND and eMMC probably have their own special magic
      numbers too.
      
      Currently the corrupted byte is a part of one of the instructions in
      the reset vectors table:
      
          b     reset
          ldr   pc, _undefined_instruction
          ldr   pc, _software_interrupt      <- Corruption happens here
          ldr   pc, _prefetch_abort
          ldr   pc, _data_abort
          ldr   pc, _not_used
          ldr   pc, _irq
          ldr   pc, _fiq
      
      In practice this does not cause any visible problems, but it's still
      better to fix it. As a bonus, the reported boot media type can be
      later used in the 'spl_boot_device' function, but this is out of
      the scope of this patch.
      Signed-off-by: NSiarhei Siamashka <siarhei.siamashka@gmail.com>
      Reviewed-by: NHans de Goede <hdegoede@redhat.com>
      Signed-off-by: NHans de Goede <hdegoede@redhat.com>
      b19236fd
  10. 01 4月, 2016 1 次提交
  11. 29 9月, 2015 3 次提交
  12. 05 7月, 2014 1 次提交
  13. 25 5月, 2014 1 次提交
  14. 29 3月, 2014 1 次提交
  15. 24 7月, 2013 1 次提交
  16. 08 4月, 2013 1 次提交
    • T
      OMAP3/4/5/AM33xx: Correct logic for checking FAT or RAW MMC · c3d2c24f
      Tom Rini 提交于
      In the case of booting from certain peripherals, such as UART, we must
      not see what the device descriptor says for RAW or FAT mode because in
      addition to being nonsensical, it leads to a hang.  This is why we have
      a test currently for the boot mode being within range.  The problem
      however is that on some platforms we get MMC2_2 as the boot mode and not
      the defined value for MMC2, and in others we get the value for MMC2_2.
      This is required to fix eMMC booting on omap5_uevm.
      
      Tested on am335x_evm (UART, NAND, SD), omap3_beagle (NAND, SD on
      classic, SD only on xM rev C5) and omap5_uevm (SD, eMMC).
      Signed-off-by: NTom Rini <trini@ti.com>
      c3d2c24f
  17. 09 3月, 2013 1 次提交
  18. 28 9月, 2012 1 次提交
  19. 01 9月, 2012 1 次提交
  20. 10 12月, 2011 1 次提交
    • C
      S5PC2XX: Rename S5pc2XX to exynos · 393cb361
      Chander Kashyap 提交于
      As per new naming convention for Samsung SoC's, all Cortex-A9 and Cortex-A15
      based SoC's will be classified under the name Exynos. Cortex-A9 and Cortex-A15
      based SoC's will be sub-classified as Exynos4 and Exynos5 respectively.
      
      In order to better adapt and reuse code across various upcoming Samsung Exynos
      based boards, all uses of s5pc210 prefix/suffix/directory-names are renamed in
      this patch. s5pc210 is renamed as exynos4210 and S5PC210/s5pc210 suffix/prefix
      are renamed as exynos4/EXYNOS4.
      Signed-off-by: NChander Kashyap <chander.kashyap@linaro.org>
      Signed-off-by: NMinkyu Kang <mk7.kang@samsung.com>
      393cb361
  21. 02 2月, 2011 1 次提交
  22. 11 8月, 2010 1 次提交
  23. 16 7月, 2010 1 次提交
  24. 13 4月, 2010 1 次提交
  25. 28 11月, 2009 1 次提交
  26. 06 11月, 2009 1 次提交
  27. 26 6月, 2009 1 次提交
  28. 28 6月, 2003 1 次提交
    • W
      * Code cleanup: · 8bde7f77
      wdenk 提交于
        - remove trailing white space, trailing empty lines, C++ comments, etc.
        - split cmd_boot.c (separate cmd_bdinfo.c and cmd_load.c)
      
      * Patches by Kenneth Johansson, 25 Jun 2003:
        - major rework of command structure
          (work done mostly by Michal Cendrowski and Joakim Kristiansen)
      8bde7f77
  29. 19 11月, 2002 1 次提交
    • W
      * Patch by Thomas Frieden, 13 Nov 2002: · c7de829c
      wdenk 提交于
        Add code for AmigaOne board
        (preliminary merge to U-Boot, still WIP)
      
      * Patch by Jon Diekema, 12 Nov 2002:
        - Adding URL for IEEE OUI lookup
        - Making the autoboot #defines dependent on CONFIG_AUTOBOOT_KEYED
          being defined.
        - In the CONFIG_EXTRA_ENV_SETTINGS #define, the root-on-initrd and
          root-on-nfs macros are designed to switch how the default boot
          method gets defined.
      c7de829c
  30. 09 9月, 2002 2 次提交
  31. 14 12月, 2000 1 次提交
  32. 13 11月, 2000 1 次提交