Re: [U-Boot] [PATCH v2 07/17] warp7: Specify CONFIG_OPTEE_LOAD_ADDR

2018-04-13 Thread Bryan O'Donoghue



On 07/04/18 13:23, Breno Matheus Lima wrote:

Hi Bryan,

2018-04-02 19:42 GMT-03:00 Bryan O'Donoghue :

In order to sign images with the IMX code-signing-tool (CST) we need to
know the load address of a given image. The best way to derive this load
address is to make it into a define - so that u-boot.cfg contains the
address - which we can then parse when generating the IMX CST headers.

This patch makes the OPTEE_LOAD_ADDR available via u-boot.cfg for further
parsing by external tools.

Signed-off-by: Bryan O'Donoghue 
Reviewed-by: Ryan Harkin 
---
  configs/warp7_defconfig | 1 +
  include/configs/warp7.h | 1 +
  2 files changed, 2 insertions(+)

diff --git a/configs/warp7_defconfig b/configs/warp7_defconfig
index 3dbcd69..c647cd0 100644
--- a/configs/warp7_defconfig
+++ b/configs/warp7_defconfig
@@ -45,3 +45,4 @@ CONFIG_USB_ETH_CDC=y
  CONFIG_USBNET_HOST_ADDR="de:ad:be:af:00:00"
  CONFIG_OF_LIBFDT=y
  CONFIG_OPTEE=y
+CONFIG_OPTEE_LOAD_ADDR=0x8400



I'm seeing the following in my U-Boot environment variables, seems
that CONFIG_OPTEE_LOAD_ADDR it's not being correctly defined:


Can you try again after doing this

make clean; make mrproper; make warp7_config;make u-boot.imx arch=ARM 
CROSS_COMPILE=/opt/linaro/gcc-linaro-7.2.1-2017.11-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-


works for me
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] [PATCH v2 07/17] warp7: Specify CONFIG_OPTEE_LOAD_ADDR

2018-04-07 Thread Breno Matheus Lima
Hi Bryan,

2018-04-02 19:42 GMT-03:00 Bryan O'Donoghue :
> In order to sign images with the IMX code-signing-tool (CST) we need to
> know the load address of a given image. The best way to derive this load
> address is to make it into a define - so that u-boot.cfg contains the
> address - which we can then parse when generating the IMX CST headers.
>
> This patch makes the OPTEE_LOAD_ADDR available via u-boot.cfg for further
> parsing by external tools.
>
> Signed-off-by: Bryan O'Donoghue 
> Reviewed-by: Ryan Harkin 
> ---
>  configs/warp7_defconfig | 1 +
>  include/configs/warp7.h | 1 +
>  2 files changed, 2 insertions(+)
>
> diff --git a/configs/warp7_defconfig b/configs/warp7_defconfig
> index 3dbcd69..c647cd0 100644
> --- a/configs/warp7_defconfig
> +++ b/configs/warp7_defconfig
> @@ -45,3 +45,4 @@ CONFIG_USB_ETH_CDC=y
>  CONFIG_USBNET_HOST_ADDR="de:ad:be:af:00:00"
>  CONFIG_OF_LIBFDT=y
>  CONFIG_OPTEE=y
> +CONFIG_OPTEE_LOAD_ADDR=0x8400


I'm seeing the following in my U-Boot environment variables, seems
that CONFIG_OPTEE_LOAD_ADDR it's not being correctly defined:
...
mmcpart=1
optee_addr=CONFIG_OPTEE_LOAD_ADDR
rootpart=2
...

Moving CONFIG_OPTEE_LOAD_ADDR to Kconfig address this issue, can you
please check if the same is happening in your side?

--- a/board/warp7/Kconfig
+++ b/board/warp7/Kconfig
@@ -20,4 +20,10 @@ config SYS_FDT_ADDR
 help
   The address the FDT file should be loaded to.

+config OPTEE_LOAD_ADDR
+hex "OPTEE load address"
+default 0x8400
+help
+  The address the OPTEE binary should be loaded to.
+
 endif

--- a/scripts/config_whitelist.txt
+++ b/scripts/config_whitelist.txt
@@ -1469,6 +1469,7 @@ CONFIG_OMAP_EHCI_PHY2_RESET_GPIO
 CONFIG_OMAP_EHCI_PHY3_RESET_GPIO
 CONFIG_OMAP_USB2PHY2_HOST
 CONFIG_OMAP_USB3PHY1_HOST
+CONFIG_OPTEE_LOAD_ADDR
 CONFIG_ORIGEN

U-Boot environment variables after applying the patch above:
...
mmcpart=1
optee_addr=0x8400
rootpart=2
...

Thanks,
Breno Lima
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot