Nand Flash problem

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

Nand Flash problem

3,296 Views
PramodKumar
Contributor IV

Hello,

 

We are working with the Toshiba NAND  TH58NVG5S0FTA20(4GB, 2CE) .Nand Flash was detected in kernel and kernel image linux.sb  port using kobs-ng command.

When we boot the board in NAND mode it was not able to boot and  error code

0x80508002 Unable to find NCB was serial out.

NAND Flash Description :

Scanning for NAND Flash chips...

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

NAND Flash Device Information

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

Manufacturer      : Toshiba (0x98)

Device Code       : 0xd5

Cell Technology   : SLC

Chip Size         : 4 GiB

Pages per Block   : 64

Page Geometry     : 4096+128

ECC Strength      : 4 bits

ECC Size          : 512 B

Data Setup Time   : 12 ns

Data Hold Time    : 5 ns

Address Setup Time: 25 ns

GPMI Sample Delay : 6 ns

tREA              : 20 ns

tRLOH             : 5 ns

tRHOH             : 25 ns

Description       : TH58NVG5S0FTA20(4GB, 2CE)

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

NFC Geometry

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

ECC Algorithm          : BCH

ECC Strength           : 4

Page Size in Bytes     : 4224

Metadata Size in Bytes : 10

ECC Chunk Size in Bytes: 512

ECC Chunk Count        : 8

Payload Size in Bytes  : 4096

Auxiliary Size in Bytes: 20

Auxiliary Status Offset: 12

Block Mark Byte Offset : 0

Block Mark Bit Offset  : 0

NAND device: Manufacturer ID: 0x98, Chip ID: 0xd5 (Toshiba NAND 2GiB 3,3V 8-bit)

2 NAND chips detected

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

Boot ROM Geometry

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

Boot Area Count            : 2

Boot Area Size in Bytes    : 20971520 (0x1400000)

Stride Size in Pages       : 64

Search Area Stride Exponent: 2

Scanning for an NCB fingerprint...

 

Please find the attach file to see serial output.

 

Regards

Pramod Kumar

Original Attachment has been moved to: NandFlash_porting.txt.zip

Labels (6)
0 Kudos
13 Replies

1,499 Views
igorpadykov
NXP Employee
NXP Employee

Hi Pramod

to boot from the NAND, boot ROM code needs to find one set of BCBs (NCB, LDLB

and DBBT) intact. In the case, the error log reported that it was unable to find the NCB,

probably due to a defect memory, could you try other NAND ?

Best regards

igor

0 Kudos

1,499 Views
PramodKumar
Contributor IV

Hii

0 Kudos

1,499 Views
eugenevolkov
Contributor IV

Hi, Pramod Kumar!

Where did you get kobs-ng? I use Yocto relise, and  not find this utility.

Can you just give a link to a document that describes the utility, how to operate it.

0 Kudos

1,499 Views
PramodKumar
Contributor IV

Hii

Page size x8: 4,320 bytes (4,096 + 224 bytes)

– Block size: 128 pages (512K + 28K bytes)

– Plane size: 2 planes x 1,024 blocks per plane

– Device size: 8Gb: 2,048 blocks

...........................................................................

and 4 gb nand info plz check what is difference between in both nand

32 GBIT (4G × 8 BIT) CMOS NAND E PROM (Multi-Level-Cell)

DESCRIPTION

The TC58NVG5D2 is a single 3.3 V 32 Gbit (36,274,176,000 bits) NAND Electrically Erasable and Programmable

Read-Only Memory (NAND E2PROM) organized as (8192 + 448) bytes × 128 pages × 4100 blocks.

The device has two 8640-byte static registers which allow program and read data to be transferred between the

register and the memory cell array in 8640-byte increments. The Erase operation is implemented in a single block

unit (1 Mbytes + 56 Kbytes: 8640 bytes × 128 pages).

The TC58NVG5D2 is a serial-type memory device which utilizes the I/O pins for both address and data

input/output as well as for command inputs. The Erase and Program operations are automatically executed making

the device most suitable for applications such as solid-state file storage, voice recording, image file memory for still

cameras and other systems which require high-density non-volatile memory data storage.

FEATURES

Organization

Memory cell array

Register

Page size

Block size

TC58NVG5D2F

8640 × 512K × 8

8640 × 8

8640 bytes

(1M + 56 K) bytes

• Modes

   Read, Reset, Auto Page Program, Auto Block Erase, Status Read, Page Copy,

  Multi Page Program, Multi Block Erase, Multi Page Copy, Mullti Page Read

• Mode control

   Serial input/output

  Command control

• Number of valid blocks

   Min 3936 blocks

  Max 4100 blocks

• Power supply

   VCC = 2.7 V to 3.6 V

• Access time

   Cell array to register

  Serial Read Cycle

200 μs max

25 ns min

• Program/Erase time

   Auto Page Program

  Auto Block Erase

1600 μs/page typ.

4 ms/block typ.

• Operating current

   Read (25 ns cycle)

  Program (avg.)

Erase (avg.)

Standby

TBD ( 50 mA max.)

TBD ( 50 mA max.)

TBD ( 50 mA max.)

i think block size create this problem becouse pervious nand block less compare to this nand plz check and tell me what is can do ...

thanks &regards

pramod kumar

0 Kudos

1,499 Views
PramodKumar
Contributor IV

Hii

32 GBIT (4G × 8 BIT) CMOS NAND E PROM

DESCRIPTION

The TH58NVG5S0F is a single 3.3V 32 Gbit (36,305,895,424 bits) NAND Electrically Erasable and

Programmable Read-Only Memory (NAND E2PROM) organized as (4096 + 232) bytes × 64 pages × 16384 blocks.

The device has two 4328-byte static registers which allow program and read data to be transferred between the

register and the memory cell array in 4328-byte increments. The Erase operation is implemented in a single block

unit (256 Kbytes + 14.5 Kbytes: 4328 bytes × 64 pages).

The TH58NVG5S0F is a serial-type memory device which utilizes the I/O pins for both address and data

input/output as well as for command inputs. The Erase and Program operations are automatically executed making

the device most suitable for applications such as solid-state file storage, voice recording, image file memory for still

cameras and other systems which require high-density non-volatile memory data storage.

FEATURES

Organization

Memory cell array

Register

Page size

Block size

x8

4328 × 256K × 8 × 4

4328 × 8

4328 bytes

(256K + 14.5K) bytes

• Modes

   Read, Reset, Auto Page Program, Auto Block Erase, Status Read, Page Copy,

  Multi Page Program, Multi Block Erase, Multi Page Copy, Multi Page Read

• Mode control

   Serial input/output

  Command control

• Number of valid blocks

   Min 16064 blocks

  Max 16384 blocks

• Power supply

   VCC = 2.7V to 3.6V

• Access time

   Cell array to register 30 μs max

   Serial Read Cycle

  25 ns min (CL=100pF)

• Program/Erase time

   Auto Page Program

  Auto Block Erase

300 μs/page typ.

3 ms/block typ.

• Operating current

   Read (25 ns cycle)

  Program (avg.)

Erase (avg.)

Standby

30 mA max.

30 mA max

30 mA max

200 μA max

• Package

   TSOP I 48-P-1220-0.50C

• 4bit ECC for each 512Byte is required.

0 Kudos

1,499 Views
igorpadykov
NXP Employee
NXP Employee

Hi Pramod

if you are using ltib, then one can try to

change block erase size in ltib settings

~igor

0 Kudos

1,499 Views
PramodKumar
Contributor IV

hii igorpadykov

but how to change block erasesize in ltib setting plz tell me path or which file

0 Kudos

1,499 Views
PramodKumar
Contributor IV

hii igorpadykov

plz tell me how can i change block erasesize ....

0 Kudos

1,499 Views
PramodKumar
Contributor IV

hii igorpadykov

i am using the Target image: (ext2.gz ramdisk) so i could not change the block erasesize ..becouse block size is defined only jffs2 and ubifs ..image

0 Kudos

1,499 Views
igorpadykov
NXP Employee
NXP Employee

Hi Pramod

in general creating ubifs image is well described on that forum,

for example how to create ubifs for one CS NAND part

1. create ubifs image

mkfs.ubifs -v -r [Path_to_ROOTFS] -o rootfs.ubifs -m 4096 -e 253952 -c 4095

2. create a ubinize.cfg file

cat > ubinize.cfg << EOF

[rootfs0]

mode=ubi

image=./rootfs.ubifs

vol_id=0

vol_size=450MiB

vol_type=dynamic

vol_name=rootfs0

EOF

3. create ubi image

ubinize -o rootfs.ubi -m 2048 -p 256KiB -s 2048 ubinize.cfg

4. for a new flash need specify the erase block size in and max erase blocks size

in mkfs.ubifs

you can get this when ubiattach the device

for imx233 evk 1.1:

run: ubiattach /dev/ubi_ctrl -m 1

UBI: physical eraseblock size:   262144 bytes (256 KiB)

UBI: logical eraseblock size:    258048 bytes

UBI: smallest flash I/O unit:    2048

so the command is

mkfs.ubifs -v -r [Path_to_ROOTFS] -o rootfs.ubifs -m 2048 -e 258048 -c 4095

ubinize -o rootfs.ubi -m 2048 -p 256KiB -s 2048 ubinize.cfg

5. flash to nand

ubiformat -f rootfs.ubi /dev/mtd2

Note: mkfs.ubifs is not included in the development package.

copy mkfs.ubifs to /sbin

run 'sudo apt-get install liblzo2-dev mtd-utils' to install the mtd utilities and lzo which is needed by the mkfs.ubifs.

Do not use the Windows editor to create the ubinize.cfg.

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

4GB Nand

$ cat ubinize.cfg

[rootfs-volume-0]

mode=ubi

image=./rootfs.ubifs

vol_id=0

vol_size=300MiB

vol_type=dynamic

vol_name=rootfs0

[rootfs-volume-1]

mode=ubi

image=./rootfs.ubifs

vol_id=1

vol_size=300MiB

vol_type=dynamic

vol_name=rootfs1

[data-volume-2]

mode=ubi

vol_id=2

vol_size=300MiB

vol_type=dynamic

vol_name=data

vol_flag=autoresize

$ mkfs.ubifs -v -r ${IMAGE_ROOTFS} - 0 rootfs.ubifs -m 4096 -e 516096 -c 8191

$ ubinize -o rootfs.ubi -m 4096 -p 512KiB ubinize.cfg

~igor

0 Kudos

1,499 Views
PramodKumar
Contributor IV

hi

we are currently working on ltib linux 2.6.35-imx ..and my board is imx233 ...

0 Kudos

1,499 Views
igorpadykov
NXP Employee
NXP Employee

Hi Pramod

one can look for example at below guide

http://www.mxic.com.tw/Lists/MoreSoftware/Attachments/52/imx28evk_nand_flash_build.pdf

Best regards

igor

0 Kudos