ISSUE REGARDING PPA Fetch FOR NAND BOOT

cancel
Showing results for 
Search instead for 
Did you mean: 

ISSUE REGARDING PPA Fetch FOR NAND BOOT

398 Views
Contributor IV

Hi,

I am currently working on ls1043ardb board.In the reference board the ppa is fetched from NOR location(60500000) by default(for all boot modes). I am trying to change the ppa address for nand that is ,if i am booting from nand it should take ppa from nand itself.

I have modified the following files:

1=>include/configs/ls1043ardb.h

2=>arch/arm/cpu/armv8/fsl-lsh2/ppa.c

The modifications are given below:

1=>

#ifdef CONFIG_NAND_BOOT

#define CONFIG_SYS_LS_PPA_FW_IN_NAND

#ifdef CONFIG_SYS_LS_PPA_FW_IN_NAND

#define CONFIG_SYS_QE_FW_IN_NAND

#define CONFIG_SYS_LS_PPA_FW_ADDR       0x220000

#endif

#else

#define CONFIG_SYS_LS_PPA_FW_IN_NOR

#ifdef CONFIG_SYS_LS_PPA_FW_IN_NOR

#define CONFIG_SYS_LS_PPA_FW_ADDR       0x60500000

#endif

The above modifications are in file1.

2=>

#if defined(CONFIG_SYS_LS_PPA_FW_IN_NOR)

        fit_hdr = (void *)CONFIG_SYS_LS_PPA_FW_ADDR;

        printf("\nHEader1:%p",fit_hdr);

#elif defined(CONFIG_SYS_LS_PPA_FW_IN_NAND)

        fit_hdr = (void *)CONFIG_SYS_LS_PPA_FW_ADDR;

        printf("\nHeader:%p",fit_hdr);

#else

#error "No CONFIG_SYS_LS_PPA_FW_IN_xxx defined"

#endif

These modifications are in ppa.c

But still i am getting the below given issue:

fsl-ppa: Bad firmware image (not a FIT image)

fsl-ppa: error (-22)

tzc380_init: add 0 regions

tzc380: tzc380_reg_base = 0000000001500000

Whats the issue?Is there any other modifications needed apart from this??

Pls help

Thanks in advance

Tags (1)
0 Kudos
5 Replies

6 Views
NXP TechSupport
NXP TechSupport

Look at the following page:

https://www.mail-archive.com/search?l=u-boot@lists.denx.de&q=subject:%22Re%5C%3A+%5C%5BU%5C-Boot%5C%...

and

https://patchwork.ozlabs.org/patch/569954/


Have a great day,
Pavel Chubakov

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

6 Views
NXP TechSupport
NXP TechSupport
The LS1043 SDK 0.5 provides loading of the Primary Protected Application (PPA) image using NOR Flash only. Find the following in the ppa.c file:
#ifdef CONFIG_SYS_LS_PPA_FW_IN_NOR
                    fit_hdr = (void *)CONFIG_SYS_LS_PPA_FW_ADDR;
#else
#error "No CONFIG_SYS_LS_PPA_FW_IN_xxx defined"
#endif

See the following pages:

http://lists.denx.de/pipermail/u-boot/2016-February/246260.html

and

https://patchwork.ozlabs.org/patch/569954/

and

https://www.mail-archive.com/search?l=u-boot@lists.denx.de&q=subject:%22Re%5C%3A+%5C%5BU%5C-Boot%5C%...//www.mail-archive.com/search?l=u-boot@lists.denx.de&q=subject:%22Re%5C%3A+%5C%5BU%5C-Boot%5C%5D+%5C%5BPATCH+2%5C%2F3%5C%5D+ARMv8%5C%2Flayerscape%5C%3A+Add+FSL+PPA+support%22&o=newest&f=1


Have a great day,
Pavel Chubakov

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

6 Views
Contributor IV

Hi Pavel,

Is there any way to change the ppa.c so as to fetch ppa from NAND???

I have done the following modifications in ppa.c:

if defined(CONFIG_SYS_LS_PPA_FW_IN_NAND)

  nand_info_t nand_info[CONFIG_SYS_MAX_NAND_DEVICE];

  size_t fw_length = CONFIG_SYS_QE_FMAN_FW_LENGTH;

  void *fit_hdr = malloc(CONFIG_SYS_QE_FMAN_FW_LENGTH);

  rc = nand_read(&nand_info[0], (loff_t)CONFIG_SYS_LS_PPA_FW_ADDR,

                       &fw_length, (u_char *)fit_hdr);

        if (rc == -EUCLEAN) {

                printf("NAND read of PPA  at offset 0x%x failed %d\n",

                        CONFIG_SYS_LS_PPA_FW_ADDR, rc);

       }

But it seems like it does not work.Is there any other way to do it?

Pls help

0 Kudos

6 Views
NXP Employee
NXP Employee

Hi,

I'm not an u-boot or PPA guru, but as far I know no matter where you boot, the PPA firmware is loaded from NOR currently.

Thank you,

Marius

0 Kudos

6 Views
Contributor IV

Hi Marius,

But I need to change the ppa fetch address.I want to fetch ppa from nand itself.Is there any way?

Pls help

0 Kudos