19 Oct, 2020

1 commit

  • Conflicts:
    arch/arm/cpu/armv8/Kconfig
    drivers/pci/pcie_layerscape_fixup.c
    drivers/video/imx/Makefile
    drivers/video/nxp/Kconfig
    drivers/video/nxp/Makefile
    drivers/video/nxp/hdp/Makefile
    drivers/video/nxp/hdp/test_base_sw.c

    Signed-off-by: Ye Li

    Ye Li
     

28 Sep, 2020

1 commit

  • Enable "optee_rpmb" command to write/read named persistent values
    created on RPMB by opening session with OPTEE AVB TA.
    This provides easy test for establishing a session with OPTEE
    TA and storage of persistent data in MMC RPMB.

    It includes following subcommands:

    optee_rpmb read_pvalue - read persistent values on rpmb via OPTEE AVB TA
    optee_rpmb write_pvalue - write persistent values on rpmb via OPTEE AVB TA

    Signed-off-by: Ruchika Gupta

    Ruchika Gupta
     

25 Aug, 2020

3 commits

  • The code moves around 'tail' bytes to make room for the
    in-place substitution. But 'tail' should be the amount of
    bytes since the end of the to-be-substituted word until
    the end of the string, including the NULL character at the end.
    The 'tail' used to be calculated as the number of bytes until
    the end of the allocated buffer, which means that if we have to
    move the last 'tail' bytes to the right in order to make room
    for the substitution we will write past the buffer boundary.

    Issue: ALB-276
    Signed-off-by: Dan Nica

    Dan Nica
     
  • When mdio list command is called, it doesn't save previous parameter.
    So, when we press enter to repeat command, it doesn't show any thing.
    Remove return instruction when call do_mdio with "list" parameter.

    Signed-off-by: phu.luuan
    Signed-off-by: Dan Nica
    Issue: ALB-1741

    phu.luuan
     
  • The "pci" command may or may not re-enumerate the bus depending
    on a build time option. Add printf() calls to inform the user
    about whether or not the bus is being re-enumerated.

    Issue: ALB-1121
    Signed-off-by: Dan Nica

    Dan Nica
     

16 Jun, 2020

2 commits

  • Android use AVB to verify the kernel, hab authentication is
    not necessary for boot image.

    For imx8m, don't authenticate the kernel image when AVB
    (CONFIG_AVB_SUPPORT) is enabled. For imx8q, as android uses
    different 'CONFIG_EXTRA_ENV_SETTINGS' and 'CONFIG_BOOTCOMMAND'
    with linux bsp, so it won't try to do kernel hab authentication.
    by default.

    Test: boot imx8mp with "CONFIG_IMX_HAB" and imx8qxp with
    'CONFIG_AHAB_BOOT'.

    Change-Id: I1b2087ce7d8f9795422a053b6b68a694c86f0b3d
    Signed-off-by: Ji Luo
    (cherry picked from commit f907e4ac090e960ba5110b8039cccc4296841595)

    Ji Luo
     
  • The video link framework bases a port-endpoint gragh in DTB to
    connect the video components in uclass like: video, display, bridge,
    and panel.

    Using the port-endpoint gragh, we manage multiple video link and
    user can select one of them for splash screen.

    Signed-off-by: Ye Li
    (cherry picked from commit d6e6b1293f89b8a26033ac2f82151985f70e4036)

    Ye Li
     

06 May, 2020

15 commits

  • On imx8 platform, the usb2 and usb3 ports are both supported. Which
    means we can use usb2(ci_udc_otg) and usb3(cdns3_generic_peripheral)
    gadget driver to run sdp/fastboot/ums at the same time.

    For sdp and the fastboot that runs automatically when uboot starts,
    board_usb_gadget_port_auto() is added to autodetect usb port, this
    means that we don't have to specify which USB port should be used to
    download in code, now we can just connect either usb port then it
    will download automatically.

    Signed-off-by: Sherry Sun
    (cherry picked from commit 2b6fd3da6fffae0732e8e91ef5c1f870ea393ca9)

    Sherry Sun
     
  • mtdparts quit when invalid mtd devices found. Add thes patches to skip
    the invalid devices, so NAND partitions can be alway found to burn boot
    images.

    For instance,

    On i.MX6DL Sabreauto, nand config u-boot didn't enable the weim nor, so
    parsing 8000000.nor leads to error:

    Device nor0 not found!

    With the patches, we can skip this invalid device and still get nand
    boot partition table:

    Device nor0 not found!
    current device is invalid, skip it and check the next one

    device nand0 , # parts = 5
    0: nandboot 0x04000000 0x00000000 0
    1: nandkernel 0x01000000 0x04000000 0
    2: nanddtb 0x01000000 0x05000000 0
    3: nandtee 0x01000000 0x06000000 0
    4: nandrootfs 0xf9000000 0x07000000 0

    active partition: nand0,0 - (nandboot) 0x04000000 @ 0x00000000

    Signed-off-by: Han Xu
    (cherry picked from commit e674896123983e152ef3cc9d1304b775e5086a5e)

    Han Xu
     
  • add a new option in mtdparts to skip the invalid devices rather than
    just quit

    Signed-off-by: Han Xu
    (cherry picked from commit dbe3763931e536cba4925fdd04fda39cc748fc1c)

    Han Xu
     
  • Porting the FSL android fastboot features from imx u-boot v2018.03 to
    support all SoCs: imx6/imx7/imx7ulp/imx8/imx8m.

    The UUU commands like UCmd and ACmd are also added. Users need set
    CONFIG_FASTBOOT_UUU_SUPPORT=y to enable the feature.

    Signed-off-by: Frank Li
    Signed-off-by: Ye Li
    (cherry picked from commit 65120b06a7f750b9b1a6e0db3d2082cc7088d5a8)
    (cherry picked from commit 9b149c2a28829fe7017f83981d634157bc31cc94)

    Ye Li
     
  • When IMX_OPTEE is enabled for secure boot, update bootm to authenticate the optee
    image and the kernel zImage before booting into optee.

    Signed-off-by: Ye Li
    (cherry picked from commit d3bee08f12f1d41c83c47773aec6cfa28056694a)
    (cherry picked from commit 3825c3fedbbe59fdf8c4f59f10221823a5fc6f03)
    (cherry picked from commit a09dca5eff735ef8ef46313de09cfa0f3b4cf189)
    (cherry picked from commit c83877f5ad9385279c5db3d6ab78ed103d45d1d5)

    Ye Li
     
  • When sata stop is executed, the sata_curr_device is not reset to -1, so
    any following sata commands will not initialize the sata again and cause
    problem.

    Additional, in sata init implementation, the sata_curr_device should be updated,
    otherwise sata will be initialized again when doing other sata commands like
    read/write/info/part/device.

    Signed-off-by: Ye Li
    (cherry picked from commit 9bccfd01c618a5d059f332c000c42e5bf39880d9)
    (cherry picked from commit f162bbb14b5c9b0c4073eee5ceeea6a9d1780394)

    Ye Li
     
  • This fix a wrong trace error while executing caam genlob command.

    Signed-off-by: Aymen Sghaier
    (cherry picked from commit 7b80598100baf38562bee10bb4a19c3c834b945b)
    (cherry picked from commit 878d0d145482683bd7d3b89f3cbd74878b5d1064)

    Aymen Sghaier
     
  • Add the fsl CAAM driver and new commands to implement DEK blob operations,
    like "caam genblob" to generate encrypted blob and "caam decap" to output
    orignal plain data.

    Signed-off-by: Ye Li
    (cherry picked from commit 4ec81a0b075d8d853ac696172660a7771064405d)
    (cherry picked from commit fcd29e9dd2e13e4650741603ca1bfb40fe1a9ede)

    Ye Li
     
  • This patch enable blob command for mScale platforms.

    Signed-off-by: Aymen Sghaier
    (cherry picked from commit 895669394f6aae633abf6ea3f327d6093562edde)
    (cherry picked from commit bac8ed98778c93ef43ce9093efa3b9999d650576)
    (cherry picked from commit 2542f195b484dcd09bbf72406c7951bee06b52a5)

    Aymen Sghaier
     
  • Signed-off-by: Franck LENORMAND
    (cherry picked from commit 03cb71cd22ff6ab1e2005a4bcb183c65f49b6e4e)
    (cherry picked from commit 5d797db35da7fa3f7971df8811b6a1e800786ced)
    (cherry picked from commit dd2e4b027122aa6724985f23319bebd89dfc1f39)

    Franck LENORMAND
     
  • U-Boot can instantiate CAAM RNG if needed by crypto operations.
    Call sec_init() prior running a blob operation to ensure
    RNG is correctly instantiated.

    Make sure CAAM clock is enabled and check if a job ring is
    available for that operation.

    Signed-off-by: Breno Lima
    Reviewed-by: Ye Li
    (cherry picked from commit b2b745515d06f05ea288524e26cf2389d6924ff2)
    (cherry picked from commit fe33f7296336b7364fb24ad21b0be32eb5810262)
    (cherry picked from commit 1339300cba26dc32289633c3a8c2cc86a1180949)

    Breno Lima
     
  • In order to build CMD_BLOB on i.MX CAAM supported devices it's
    necessary to select IMX_HAB. Add IMX_HAB and CAAM supported
    SoCs as dependency.

    Signed-off-by: Breno Lima
    Reviewed-by: Ye Li
    (cherry picked from commit 4afb519038d190687cac6d410e9ad65d0655f1c0)
    (cherry picked from commit acda6159eefbefaee15b19568fd1c4665c047432)
    (cherry picked from commit c9de383878c5e248ae549182a9f2477f5bb2a5f5)

    Breno Lima
     
  • When secure boot is enabled, add authenticate_image in booti to authenticate
    kernel image.

    Signed-off-by: Ye Li
    (cherry picked from commit f29a143cdb8c74566113737e9be7e1bcd8c625f4)
    (cherry picked from commit 1e33f493a55dad7e016f948b932000ec295c6df4)
    (cherry picked from commit 677c332120eff7161532288685c58f246d1f00ff)

    Ye Li
     
  • To support the trust boot chain, we integrate the authentication
    into the kernel image loading process. The kernel image will be verified
    at its load address. So when signing the kernel image, we need to
    use this load address which may change on different platforms.

    Signed-off-by: Ye Li
    (cherry picked from commit 3c118b8d6bbe1a25ca8c8bafeb528309f16fc73d)
    (cherry picked from commit fd9a9759ed9b3a9fc26b18aff00880382213b1ca)
    (cherry picked from commit 98d4faefdb83579d4a5a170e06af5efb64ad2b3c)
    (cherry picked from commit 3c0f0eed6cb703cd7d67ec97520b1990b5e35fb2)

    Ye Li
     
  • The usb mass storage (f_mass_storage.c) uses fixed usb index 0,
    this causes problem while CDNS3 USB controller index is 1.
    Modify the API of fsg to pass the controller index.

    Signed-off-by: Ye Li
    Reviewed-by: Jun Li
    (cherry picked from commit c633b49f9140390323e5e6e16ba57b8531d964a3)

    Ye Li
     

09 Apr, 2020

1 commit


31 Mar, 2020

2 commits


28 Mar, 2020

2 commits


17 Mar, 2020

3 commits

  • Currently, bootefi only parses memory reservation block to setup
    EFI reserved memory mappings. However, it doesn't parse the
    reserved-memory[1] device tree node that also can contain the
    reserved memory regions.

    Add capability to parse reserved-memory node and update the EFI memory
    mappings accordingly.

    1. /doc/device-tree-bindings/reserved-memory/reserved-memory.txt]

    Signed-off-by: Atish Patra

    Fix an endless loop.

    The /reserved-memory node may have children without reg property. Remove
    a superfluous debug statement.

    Signed-off-by: Heinrich Schuchardt

    Atish Patra
     
  • Addresses in the sandbox's device tree are in the sandbox's virtual address
    space. If we want to compare memory reservations in the device-tree with
    the output of 'efidebug memmap', we need to convert back to this address
    space.

    Adjust the output of the 'efidebug memmap' command.

    Signed-off-by: Heinrich Schuchardt

    Heinrich Schuchardt
     
  • Some memory reservations are made in ft_board_setup(). Ensure that we
    create reserved memory map entries after ft_board_setup().

    The downside of this patch is that if bootefi is called multiple times with
    an devicetree argument superfluous reservations for the old copies of the
    device tree will exist. But that is still better than missing a reservation.

    Deleting the superfluous reservations is not possible because reservations
    in the memory map are rounded to page size and may be coallesced.

    Signed-off-by: Heinrich Schuchardt

    Heinrich Schuchardt
     

13 Mar, 2020

1 commit

  • 4dbc107f4683 ("cmd: gpio: Correct do_gpio() return value") correctly
    changed the behaviour of the gpio command to return CMD_RET_SUCCESS or
    CMD_RET_FAILURE, but any existing script which expects the return value
    to be the pin value is broken by this change.

    Reinstate the legacy behaviour for `gpio input` only.

    Fixes: 4dbc107f4683 ("cmd: gpio: Correct do_gpio() return value")
    Signed-off-by: Alex Kiernan
    Signed-off-by: Alex Kiernan
    Reviewed-by: Simon Glass

    Alex Kiernan
     

11 Mar, 2020

2 commits


29 Feb, 2020

1 commit

  • Following kernel's proposal for an arch-agnostic initrd loading
    mechanism [1] let's implement the U-boot counterpart.
    This new approach has a number of advantages compared to what we did up
    to now. The file is loaded into memory only when requested limiting the
    area of TOCTOU attacks. Users will be allowed to place the initramfs
    file on any u-boot accessible partition instead of just the ESP one.
    Finally this is an attempt of a generic interface across architectures
    in the linux kernel so it makes sense to support that.

    The file location is intentionally only supported as a config option
    argument(CONFIG_EFI_INITRD_FILESPEC), in an effort to enhance security.
    Although U-boot is not responsible for verifying the integrity of the
    initramfs, we can enhance the offered security by only accepting a
    built-in option, which will be naturally verified by UEFI Secure Boot.
    This can easily change in the future if needed and configure that via ENV
    or UEFI variable.

    [1] https://lore.kernel.org/linux-efi/20200207202637.GA3464906@rani.riverdale.lan/T/#m4a25eb33112fab7a22faa0fd65d4d663209af32f

    Signed-off-by: Ilias Apalodimas
    Signed-off-by: Heinrich Schuchardt

    Ilias Apalodimas
     

27 Feb, 2020

1 commit


19 Feb, 2020

1 commit


11 Feb, 2020

1 commit


09 Feb, 2020

1 commit

  • Both CMD_MX_CYCLIC and MX_CYCLIC are in use and defined in Kconfig,
    but only the non-CMD version currently does anything. This changes all
    usages to prefer the CMD_MX_CYCLIC option (since it's only affecting
    addition of the commands), and switches defconfigs using the non-CMD
    version to use the CMD version.

    Signed-off-by: Joel Johnson
    Reviewed-by: Tom Rini

    Joel Johnson
     

08 Feb, 2020

2 commits

  • Based on reading the text of the license comment this appears to be
    the BSD-2-Clause license but with an imperfect word match as
    BSD-2-Clause was not (as far as I recall) a common license choice at the
    time the code was written.

    Cc: Wolfgang Denk
    Signed-off-by: Tom Rini

    Tom Rini
     
  • Use the correct return value in function do_gpio() and update
    commands documentation with the return values from command_ret_t enum.

    CMD_RET_SUCCESS is returned on command success and CMD_RET_FAILURE is
    returned on command failure.

    The command was returning the pin value, which caused confusion when
    debugging (#define DEBUG).

    Signed-off-by: Luka Kovacic
    Tested-by: Robert Marko

    Luka Kovacic