Changing FMAN Ucode Address for NAND in LS1043ARDB

cancel
Showing results for 
Search instead for 
Did you mean: 

Changing FMAN Ucode Address for NAND in LS1043ARDB

592 Views
nikhilprakash
Contributor IV

Hi,

I am currently working on ls1043ardb board.In the reference board for different boot modes  the fman ucode is taken form nor bank by default.I want to change the address of fman-ucode to the one depending on boot mode, that is if i am booting from nand it should take fman ucode from nand itself.What changes should be done in the config files.I am a bit confused about how to give the address for nand  case(in the case of nor it is memory mapped ).

I tried the following changes in the ls1043ardb.h and ls1043a_common.h:

#ifdef CONFIG_NAND_BOOT

#define CONFIG_SYS_FMAN_FW_ADDR 0x7fd00000

#define CONFIG_SYS_LS_PPA_FW_ADDR 0x7fe00000

But it didn't work.

What exactly should be done for this?

Pls help

Tags (2)
0 Kudos
4 Replies

142 Views
bpe
NXP TechSupport
NXP TechSupport

You should define CONFIG_SYS_QE_FMAN_FW_IN_NAND and define CONFIG_SYS_FMAN_FW_ADDR as an offset into NAND. See details in the README in the top directory of u-Boot source code and drivers/net/fm/fm.c

Have a great day,
Platon

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

0 Kudos

142 Views
nikhilprakash
Contributor IV

Hi Platon,

I tried the above given definitions and it worked for FMAN.

Similarly i tried for PPA as well.But then i am getting an error as:

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

fsl-ppa: error (-22)

I gave the offset for ppa as 0x300000(for fman it was 0x200000).

Whats the issue?

Pls help.

0 Kudos

142 Views
bpe
NXP TechSupport
NXP TechSupport

There is no support for fetching  PPA images from  NAND Flash in the current SDK release. If you wish to

implement is by yourself, look at ppa.c

0 Kudos

142 Views
nikhilprakash
Contributor IV

Hi Platon,

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