22 Mar, 2018

12 commits


21 Mar, 2018

1 commit


20 Mar, 2018

27 commits

  • Fix NOR, SD and QSPI fallback option in case of secure boot failure.

    Signed-off-by: Vinitha V Pillai
    Reviewed-by: York Sun

    Vinitha V Pillai
     
  • IFC-NOR and QSPI-NOR pins are multiplexed on SoC, so they cannot be
    accessed simultaneously. IFC-NOR can be accessed along with SD-BOOT.

    Ls1088aqds_sdcard_ifc_defconfig is default config for SD boot and
    IFC-NOR to be used as flash. This allows writing to IFC-NOR flash.
    QSPI and DSPI cannot be accessed in this defconfig.
    IFC-NOR image is generated using ls1088aqds_defconfig.

    Signed-off-by: Ashish Kumar
    Reviewed-by: York Sun

    Ashish Kumar
     
  • This function is required for enabling access to early i2c function
    for correct usage of QIXIS_READ and QIXIS_WRITE.

    Signed-off-by: Ashish Kumar
    Reviewed-by: York Sun

    Ashish Kumar
     
  • get_board_ddr_clk(), get_board_sys_clk() and if_board_diff_clk() is
    now available for SPL build.

    Signed-off-by: Ashish Kumar
    Reviewed-by: York Sun

    Ashish Kumar
     
  • Signed-off-by: Ashish Kumar
    Reviewed-by: York Sun

    Ashish Kumar
     
  • Tom Rini
     
  • Tom Rini
     
  • This patch makes it possible to verify the contents and location of an
    OPTEE image in DRAM prior to handing off control to that image. If image
    verification fails we won't try to boot any further.

    Signed-off-by: Bryan O'Donoghue
    Suggested-by: Andrew F. Davis
    Cc: Harinarayan Bhatta
    Cc: Andrew F. Davis
    Cc: Tom Rini
    Cc: Kever Yang
    Cc: Philipp Tomsich
    Cc: Peng Fan

    Bryan O'Donoghue
     
  • This patch adds a new type IH_OS_TEE. This new OS type will be used for
    chain-loading to Linux via a TEE.

    With this patch in-place you can generate a bootable OPTEE image like this:

    mkimage -A arm -T kernel -O tee -C none -d tee.bin uTee.optee

    where "tee.bin" is the input binary prefixed with an OPTEE header and
    uTee.optee is the output prefixed with a u-boot wrapper header.

    This image type "-T kernel -O tee" is differentiated from the existing
    IH_TYPE_TEE "-T tee" in that the IH_TYPE is installed by u-boot (flow
    control returns to u-boot) whereas for the new IH_OS_TEE control passes to
    the OPTEE firmware and the firmware chainloads onto Linux.

    Andrew Davis gave the following ASCII diagram:

    IH_OS_TEE: (mkimage -T kernel -O tee)
    Non-Secure Secure

    BootROM
    |
    -------------
    |
    v
    SPL
    |
    v
    U-Boot ------>


    Suggested-by: Andrew F. Davis
    Cc: Harinarayan Bhatta
    Cc: Andrew F. Davis
    Cc: Tom Rini
    Cc: Kever Yang
    Cc: Philipp Tomsich
    Cc: Peng Fan
    Link: http://mrvan.github.io/optee-imx6ul

    Bryan O'Donoghue
     
  • When encountering an error in OPTEE verification print out various details
    of the OPTEE header to aid in further debugging of encountered errors.

    Signed-off-by: Bryan O'Donoghue
    Cc: Harinarayan Bhatta
    Cc: Andrew F. Davis
    Cc: Tom Rini
    Cc: Kever Yang
    Cc: Philipp Tomsich
    Cc: Peng Fan
    Tested-by: Peng Fan

    Bryan O'Donoghue
     
  • This patch adds optee_verify_bootm_image() which will be subsequently used
    to verify the parameters encoded in the OPTEE header match the memory
    allocated to the OPTEE region, OPTEE header magic and version prior to
    handing off control to the OPTEE image.

    Signed-off-by: Bryan O'Donoghue
    Cc: Harinarayan Bhatta
    Cc: Andrew F. Davis
    Cc: Tom Rini
    Cc: Kever Yang
    Cc: Philipp Tomsich
    Cc: Peng Fan

    Bryan O'Donoghue
     
  • This patch adds optee_image_get_load_addr() a helper function used to
    calculate the load-address of an OPTEE image based on the lower
    entry-point address given in the OPTEE header.

    Signed-off-by: Bryan O'Donoghue
    Cc: Harinarayan Bhatta
    Cc: Andrew F. Davis
    Cc: Tom Rini
    Cc: Kever Yang
    Cc: Philipp Tomsich
    Cc: Peng Fan
    Tested-by: Peng Fan

    Bryan O'Donoghue
     
  • Add a helper function for extracting the least significant 32 bits from the
    OPTEE entry point address, which will be good enough to load OPTEE binaries
    up to (2^32)-1 bytes.

    We may need to extend this out later on but for now (2^32)-1 should be
    fine.

    Signed-off-by: Bryan O'Donoghue
    Cc: Harinarayan Bhatta
    Cc: Andrew F. Davis
    Cc: Tom Rini
    Cc: Kever Yang
    Cc: Philipp Tomsich
    Cc: Peng Fan
    Tested-by: Peng Fan

    Bryan O'Donoghue
     
  • CONFIG_OPTEE_LOAD_ADDR is used to tell u-boot where to load the OPTEE
    binary into memory prior to handing off control to OPTEE.

    We need to pull this value out of u-boot in order to produce an IMX IVT/CSF
    signed pair for the purposes of secure boot. The best way to do that is to
    have CONFIG_OPTEE_LOAD_ADDR appear in u-boot.cfg.

    Adding new CONFIG entires to u-boot should be kconfig driven so this patch
    does just that.

    Signed-off-by: Bryan O'Donoghue
    Reviewed-by: Ryan Harkin

    Bryan O'Donoghue
     
  • OPTEE is currently linked to a specific area of memory called the TrustZone
    DRAM. This patch adds a CONFIG entry for the default address of TrustZone
    DRAM that a board-port can over-ride. The region that U-Boot sets aside for
    the OPTEE run-time should be verified before attempting to hand off to the
    OPTEE run-time. Each board-port should carefully ensure that the TZDRAM
    address specified in the OPTEE build and the TZDRAM address specified in
    U-Boot match-up.

    Further patches will use TZDRAM address with other defines and variables to
    carry out a degree of automated verification in U-Boot prior to trying to
    boot an OPTEE image.

    Signed-off-by: Bryan O'Donoghue
    Cc: Harinarayan Bhatta
    Cc: Andrew F. Davis
    Cc: Tom Rini
    Cc: Kever Yang
    Cc: Philipp Tomsich

    Bryan O'Donoghue
     
  • OPTEE is currently linked to a specific area of memory called the TrustZone
    DRAM. This patch adds a CONFIG entry for the default size of TrustZone DRAM
    that a board-port can over-ride. The region that U-Boot sets aside for the
    OPTEE run-time should be verified before attempting to hand off to the
    OPTEE run-time. Each board-port should carefully ensure that the TZDRAM
    size specified in the OPTEE build and the TZDRAM size specified in U-Boot
    match-up.

    Further patches will use TZDRAM size with other defines and variables to
    carry out a degree of automated verification in U-Boot prior to trying to
    boot an OPTEE image.

    Signed-off-by: Bryan O'Donoghue
    Cc: Harinarayan Bhatta
    Cc: Andrew F. Davis
    Cc: Tom Rini
    Cc: Kever Yang
    Cc: Philipp Tomsich
    Cc: Peng Fan
    Tested-by: Peng Fan

    Bryan O'Donoghue
     
  • This patch adds code to lib to enable sharing of useful OPTEE code between
    board-ports and architectures. The code on lib/optee/optee.c comes from the
    TI omap2 port. Eventually the OMAP2 code will be patched to include the
    shared code. The intention here is to add more useful OPTEE specific code
    as more functionality gets added.

    Signed-off-by: Bryan O'Donoghue
    Cc: Harinarayan Bhatta
    Cc: Andrew F. Davis
    Cc: Tom Rini
    Cc: Kever Yang
    Cc: Philipp Tomsich
    Cc: Peng Fan
    Tested-by: Peng Fan

    Bryan O'Donoghue
     
  • ppc4xx support was removed some time ago. Lets remove the now unused
    entry in MAINTAINERS as well.

    Signed-off-by: Stefan Roese
    Cc: Heinrich Schuchardt

    Stefan Roese
     
  • ppc4xx support was removed some time ago. Lets remove the now unused
    "pci_fb" variable from "struct pci_controller" as well.

    Signed-off-by: Stefan Roese
    Cc: Bin Meng
    Cc: Simon Glass

    Stefan Roese
     
  • ppc4xx support was removed some time ago. Lets remove the now unused
    NAND driver and all its references for this platform as well.

    Signed-off-by: Stefan Roese
    Cc: Heinrich Schuchardt
    Cc: Scott Wood

    Stefan Roese
     
  • Add first support for STM32MP157C-ED1 board with "Basic" boot chain
    1/ Boot Rom: load SPL with STM32 image header in SYSRAM
    2/ SPL: power up and initialize the DDR and load U-Boot image
    from SDCARD in DDR
    3/ U-Boot: search and load extlinux.conf in SDCARD
    (DISTRO activated)

    Signed-off-by: Patrick Delaunay

    Patrick Delaunay
     
  • Add minimal devicetree for STM32MP157C-ED1 board,
    with only the devices to allow boot from SDCARD:
    - RCC for clock and reset
    - UART4 for console
    - I2C and PMIC
    - DDR
    - SDMMC0 for SDCard

    Waiting Kernel upstream for alignment.

    Signed-off-by: Patrick Delaunay

    Patrick Delaunay
     
  • add binding and code for clock tree initialization from device tree

    Signed-off-by: Patrick Delaunay

    Patrick Delaunay
     
  • add RCC clock driver for STMP32MP157
    - base on driver model = UCLASS_CLK
    - support ops to enable, disable and get rate
    of all SOC clock needed by U-Boot

    Signed-off-by: Patrick Delaunay

    Patrick Delaunay
     
  • - move to livetree and allow to get address to parent
    - add stm32mp1 compatible for probe

    Signed-off-by: Patrick Delaunay

    Patrick Delaunay
     
  • - add the 2 new compatible used by STM32MP157
    "st,stm32mp157-pinctrl"
    "st,stm32mp157-z-pinctrl"
    - update the mask for the port

    Signed-off-by: Patrick Delaunay

    Patrick Delaunay
     
  • This driver implements register read/write operations for STPMU1.

    The STPMU1 PMIC provides 4 BUCKs, 6 LDOs, 1 VREF
    and 2 power switches. It is accessed via an I2C interface.
    This device is used with STM32MP1 SoCs.

    Signed-off-by: Patrick Delaunay

    Patrick Delaunay