Boot from NAND on P1020 WLAN

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Boot from NAND on P1020 WLAN

1,732 Views
kevincheng
Contributor III

Hi ,

We begin to study P1020 Chip on P1020WLAN EVB. And Try to boot from NAND. There have some trouble.

When we boot u-boot from NOR Flash, and try to load u-boot-nand.bin from tftp. And do the command from document "BSP Targeting P1020/P2020 RDB" section "5.3.13".

Beside tftp work , the follow command seems not work,

When do "nand erase 0 80000", show the follow message, it is correct?

  Skipping bad block at  0x00000000

  Skipping bad block at  0x00020000

  Skipping bad block at  0x00040000

  Skipping bad block at  0x00060000

  Skipping bad block at  0x00080000

---------------------------------------------------------------

And next command "nand write 1000000 0 80000", show the follow message. It seems not write date to the nand flash.

NAND write: device 0 offset 0x0, size 0x80000

Attempt to write outside the flash area

0 bytes written: ERROR

---------------------------------------------------------------

Try to do "nand dump 0", message always display "F0".

Page 00000000 dump:

        f0 f0 f0 f0 f0 f0 f0 f0  f0 f0 f0 f0 f0 f0 f0 f0

        f0 f0 f0 f0 f0 f0 f0 f0  f0 f0 f0 f0 f0 f0 f0 f0

        f0 f0 f0 f0 f0 f0 f0 f0  f0 f0 f0 f0 f0 f0 f0 f0

        f0 f0 f0 f0 f0 f0 f0 f0  f0 f0 f0 f0 f0 f0 f0 f0

        f0 f0 f0 f0 f0 f0 f0 f0  f0 f0 f0 f0 f0 f0 f0 f0

On the above action, have someone tell us what thing we lose or not to do ?  Thanks!!

Regards,

Kevin

9 Replies

848 Views
yipingwang
NXP TechSupport
NXP TechSupport

Hello Kevin,

What u-boot do you use on the target? Is it configured correctly for P1020WLAN platform?

Please boot up Linux Kernel on the target board, and try whether you could use "flash_erase" provided by the package "mtd-utils".


Have a great day,
Yiping

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

848 Views
kevincheng
Contributor III

Hi Yiping,

We boot up Linux Kernel on target board, but "flash_erase" can't work. But we try to use "dd" command. It seems work.

We found the nand partition layout , and remove "read-only" from u-boot layout in linux kernel,

[    0.848674] 0x000000000000-0x000000100000 : "NAND U-Boot Image"

[    0.861274] 0x000000100000-0x000000200000 : "NAND DTB Image"

[    0.873558] 0x000000200000-0x000000700000 : "NAND Linux Kernel Image"

[    0.886584] 0x000000700000-0x000000b00000 : "NAND Compressed RFS Image"

[    0.899777] 0x000000b00000-0x000002100000 : "NAND JFFS2 Root File System"

[    0.913177] 0x000002100000-0x000008000000 : "NAND Writable User area"

We do the follow command,

dd if=./u-boot-nand-P1020RDB-PD_NAND.bin of=/dev/mtdblock5

And shutdown,

change J6 jumper to 1-2 and 3-4, but console still no information.

Have any way, to check it?     Thanks~

--

Kevin

0 Kudos

848 Views
yipingwang
NXP TechSupport
NXP TechSupport

Hello Kevin Cheng,

According to your log, you flashed NAND u-boot for P1020RDB-PD, but you are using P1020WLAN.

Please note P1020RDB software cannot be used on P1020WLAN. P1020WLAN is not integrated in Linux SDK.

Please download P1020 WLAN Software Bundle from QorIQ P1 WLAN Appliance Solutions|Freescale .


Have a great day,
Yiping

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

848 Views
kevincheng
Contributor III

Hi Yiping,

By the re-building ltib(P1020 WLAN Software Bundle), and choice "nand" option on u-boot. We use the same way copy to flash, but it is not work again!

There've some concern, when loading ltib kernel image from tftp server. In dmesg, it just have NOR flash be load from ee000000 address, but no infomation about NAND flash. So, we try to add nand flash address "0xd0000000" mapping to p1020wlan.dts, but still no nand partition in the system. is my address error or something lose ?  Thanks!!

Regards,

Kevin

0 Kudos

848 Views
yipingwang
NXP TechSupport
NXP TechSupport

Hello Kevin Cheng,

Please check u-boot header file in include/configs.

Would you please provide u-boot header file and your modified dts file?


Have a great day,
Yiping

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

848 Views
kevincheng
Contributor III

Hi Yiping,

We try to modify the nand address to 0xff800000, and nand flash have be found.

But we dd the u-boot-nand.bin image to that partition, and change J6 witch. The result is the same.

Follow is my u-boot head file and linux kernel dts ,

u-boot head file

P1_P2_RDB.h - Google Drive

https://drive.google.com/file/d/0B6wokCK_hdHTMElZdlN0NW1jLVU/view?usp=sharing

linux kernel dts file

p1020wlan.dts - Google Drive

https://drive.google.com/file/d/0B6wokCK_hdHTS2N4dmhvSmhQT3M/view?usp=sharing

--

Regards,

Kevin

0 Kudos

848 Views
yipingwang
NXP TechSupport
NXP TechSupport

Hello Kevin,

I installed the ISO ltib-p1020wlan-20110816, and found that u-boot source doesn't include NAND device support, the ltib build configuration is not correct, you need to do the porting based on P1_P2_RDB configuration.

Please get u-boot source code with the command "./ltib -m prep -p u-boot" in rpm/BUILD/u-boot-2009.11.

Please refer to the Makefile, actually only NOR u-boot is defined as "P1020SKU_config".

In the file include/configs/P1020_SKU.h, NAND Flash (internal sram) is not defined in the memory map, Local bus OR and BR configuration is also not defined, please refer to include/configs/P1_P2_RDB.h.

In the folder board/freescale/p1020_sku, you also need to add NAND support in tlb and law configuration.

Also add NAND u-boot make configure in config.mk.

A lot of work needs to be done to make NAND u-boot.


Have a great day,
Yiping

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

848 Views
kevincheng
Contributor III

Hi Yiping,

We try to modify p1020sku dependency file, and make it. When finish building process, u-boot-nand.bin have been general. And write u-boot to the nand flash.  and change J6 to "1-2" ,"3-4". But still fail. We upload the file about my setting. Please help to check that have any problem?  Thanks!!

p1020wlan.tar.gz - Google Drive

https://drive.google.com/file/d/0B6wokCK_hdHTR1BtRV9iN0hLamc/view?usp=sharing

Regards,

Kevin

0 Kudos

848 Views
yipingwang
NXP TechSupport
NXP TechSupport

Hello Kevin,

NAND flash on P1020WLAN is different with P1020RDB, you need to refine the configuration CONFIG_NAND_BR_PRELIM and CONFIG_NAND_OR_PRELIM based on your target, you could refer to P1020 Reference Manual for configuring these registers.


Have a great day,
Yiping

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