2008-09-24 11:38:43     NAND flash on ez-kit bf548: read/dump is not reproducible

Document created by Aaronwu Employee on Sep 18, 2013
Version 1Show Document
  • View in full screen mode

2008-09-24 11:38:43     NAND flash on ez-kit bf548: read/dump is not reproducible

Rutger Hofman (NETHERLANDS)

Message: 62632   

 

I have an EZ-KIT BF548. I boot from NOR flash, built from svn Rev. 1327. (I loaded u-boot into the NOR from a UART u-boot, as per documentation.)

 

Now I see strange behaviour for the NAND flash.

 

If I instruct u-boot as follows:

 

bfin> nand dump 0

 

it gives me either:

 

= a page full of ff  ff ff ff ...

 

= or a page that starts as shown below (moved it down so it isn't in the text flow).

 

It is completely unpredictable which of the two happens. I'd say that the chances for an ff page or the page below are about equal. If I do nand read 0x01000000 0 0x800, the copy to memory shows the same behaviour: sometimes ff ff ff, sometimes page contents as below.

 

Might this be related to the OTP bug that I was mailed about by Analog.com? I didn't yet apply their patch -- not even sure if I have a faulty part or not.

 

Page 00000000 dump:

        ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff

        ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff (sometimes this last ff is 14)

        22 de f8 0d 7c d6 ce 17  46 fc c2 00 70 b3 46 07

        0a 02 20 25 a4 05 df 15  0e 51 10 23 18 81 e6 3a

        f2 a2 53 28 cc 19 5d 22  76 d2 71 15 c0 03 68 01

        3a 97 c2 3f 35 e4 52 2a  a5 f2 2a 04 15 a5 ec 2e

        60 a0 ef 25 7e 7c 00 04  2f dc a3 30 71 ba 1b 32

        e1 09 d9 12 51 bd 3b 06  e6 6b 57 33 d3 72 ae 0c

        bb 8a 5c 18 c3 41 da 33  ab 3f 81 0d b3 94 05 02

        7a fa 8f 37 c5 79 5d 0a  3f 58 e0 0c cb d9 56 02

        eb 83 2c 1b 62 a9 b2 1c  39 68 e5 29 a9 a5 3c 05

        19 c7 e5 0b f3 60 59 0b  4e 48 34 3c b7 c1 1f 34

        1c 71 29 09 44 f4 2c 32  b8 09 fd 3e aa b3 19 34

        7d ca e5 2a ed a6 af 19  5d a7 97 3a e5 90 3e 17

        b0 ec df 22 16 da a5 19  db 2c 41 17 91 47 75 22

        08 0c 1d 1b c2 db 12 3f  e4 32 91 09 0c ef 94 03

        6c dc 08 3c 1a 64 70 2d  55 b3 83 2f 92 88 23 25

        01 cf ec 2a 0d 12 53 36  00 8d b4 3e c9 0e e9 1d

        b6 b1 54 24 34 30 78 3f  10 a8 be 32 e9 07 65 13

        02 47 40 15 a8 8c 1f 2e  2d 0d 77 3f 50 81 d2 2b

        13 5f 8e 10 58 e2 e6 2c  fb de 69 1a 03 1e d2 0d

        bc 5b 10 34 21 24 1e 2c  75 12 47 01 0b 3e 8a 39

        59 99 90 2b 9d 7d 50 2e  5f 1c c8 20 4f 18 4c 17

        e3 27 73 12 be e3 10 32  94 c9 c9 0e 84 c1 b3 1e

        e7 07 7c 22 ae e4 71 3a  d7 81 ef 1c 4a 35 53 10

        1e 48 2a 09 48 5d 31 10  f8 0a cc 1d ac 51 a9 10

        b1 64 90 19 86 ab 5a 16  c7 bf 7b 1c d1 11 b5 3d

        99 ab 09 2b 09 91 f8 22  56 59 66 16 79 5a 2f 1c

        dd 93 9b 01 d4 e6 b8 36  07 60 23 16 33 6d d5 32

        41 09 b5 0a a0 c9 de 09  6f 64 75 36 26 bb b4 24

        24 a0 3c 08 ba 9d 2c 15  5c 96 2b 26 05 38 96 3f

        32 3e 2d 27 ee 7b 3f 0c  fc 20 23 01 43 3a 02 31

        ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff

        ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff

        ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff

        ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff

        ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff

 

QuoteReplyEditDelete

 

 

2008-09-24 16:06:56     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Mike Frysinger (UNITED STATES)

Message: 62650   

 

you're saying that every time you read/dump the same address/page in NAND, you get back a different result ?

 

what board rev do you have exactly ?  i dont think there's any switches to be set on the BF548-EZKIT ... the NAND should always be available ...

QuoteReplyEditDelete

 

 

2008-09-24 19:30:11     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Rutger Hofman (NETHERLANDS)

Message: 62663   

 

Exactly, different read results for identical read/dump, with no intermittent other actions.

 

Board rev.... uh... how do I find out? I have a 0.1 bf548, which is capable (in principle, I didn't test) of booting from x8 NAND flash.

 

Rutger

 

 

QuoteReplyEditDelete

 

 

2008-09-24 19:40:29     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Mike Frysinger (UNITED STATES)

Message: 62664   

 

look at the silkscreen on the board where it says the name/etc...

 

testing my rev 1.4 board with 0.1 silicon shows the nand is stable ... dumping page 0 of an empty flash shows all 0xff, and then copying the first 0x800 bytes from external memory to the first page shows things are ok ...

QuoteReplyEditDelete

 

 

2008-09-24 19:53:39     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Rutger Hofman (NETHERLANDS)

Message: 62665   

 

What happens to a page that contains other data than ff ff ff ... ? The faulty answer is ff ff ff ..., so if the actual data is also ff ff ff ..., there is no way to discern.

 

Did you also try multiple times? On my system, the chance of ff ff ff ... is about 1/2.

 

Rutger

QuoteReplyEditDelete

 

 

2008-09-24 19:57:28     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Mike Frysinger (UNITED STATES)

Message: 62666   

 

my NAND appears to be working correctly

 

to specifically answer your question, i dumped the same erased page multiple times and got back the same answer (all ff's).  after filling the page with data, dumping it would show the data i wrote to it (as expected).  repeating the procoess did not show any aberration.

QuoteReplyEditDelete

 

 

2008-09-24 20:04:34     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Rutger Hofman (NETHERLANDS)

Message: 62667   

 

I will check the board's revision tomorrow (it's late here in Amsterdam, I am at home, the board is in the office). Also, I will check if I have to apply Analog's OTP fix, and see if it makes a difference.

 

Else, I guess I may have got faulty hardware. Or do you suspect upgrading to bleeding-edge u-boot (and toolchain) might make a difference?

 

Thanks for the time already spent for me,

 

Rutger

 

 

QuoteReplyEditDelete

 

 

2008-09-24 20:15:52     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Mike Frysinger (UNITED STATES)

Message: 62669   

 

afaik, 2008R1.5 should work fine.  i happen to be using current trunk myself.

 

i dont know what OTP fix you refer to, but OTP shouldnt affect NAND ... afaik ...

 

you could also try booting up into Linux and see if the NAND is just as unreliable there

QuoteReplyEditDelete

 

 

2008-09-24 20:45:46     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Rutger Hofman (NETHERLANDS)

Message: 62670   

 

I am currently writing my own NAND flash driver for the eCos BF54x port.

 

I got to the point where I can correctly do a 'Read Electronic Signature' command which returns the correct answer for my NAND chip (0x20 0xda 0x80 0x1d), which seems to suggests that large portions of the code work. Then, when I want to progress to Read page, the problem I reported surfaces exactly in the same way in my own code as in unmodified u-boot (i.e. unpredictably alternating between ff ff ff ... and sensible data). My code is designed from scratch, so it is not related to u-boot's (except maybe in following Programming Examples in the BF54x  Peripheral Hardware Manual). So, this leads me to suspect that the problem might be more board/hardware than software.

 

BTW, I never get to see a NFC_IRQSTAT NBUSYIRQ status, which the NFC manual states should indicate a rising edge of nBUSY (#ND_RB signal). I need to check the Status Word to verify that my Read operation completed. I see that u-boot also checks IRQ_MASK *and* does a Read Status to check whether a NAND operation has completed. Is this failing NFC_IRQSTAT NBUSYIRQ behaviour also the case in u-boot, hence the check with Read Status?

 

The OTP fix: let me quote Analog's email, and yes, it doesn't refer to NAND:

 

Dear Customer,

It has come to our attention that the DSP device on the ADZS-BF548

EZ-KIT Lite (tm) you purchased from us recently may be 'non-standard'.

We are writing to inform you of how to check whether your ADZS-BF548

EZ-KIT Lite (tm) is affected and to advise you on how to obtain the

workaround if so.

These devices are classified as 'non-standard' because some of the

frequency limits were not fully tested during initial testing. The

problem we have discovered is that these devices are missing some

critical factory programming settings within the One Time Programmable

Memory (OTP) which include DDR, VREG, and USB trim information. Certain

areas of the One Time Programmable (OTP) Memory are programmed at the

time of manufacture to program the device with its specific settings.

The incomplete factory programming of OTP can lead to system

instability.

To identify if your board is 'non-standard', locate the DSP, which is

situated directly above the SPORT 2 connector. Affected DSPs are

labelled with 'ADSP-BF548BBCZ-5X' and have one of the following assembly

lot ID's (1336872.1, 1336874.1, 1336875.1). You should also notice an

ink dot to the right of the 'ADSP-BF548' lettering, which denotes that

the device is non-standard.

You can obtain the VisualDSP++ project that will program the appropriate

values into OTP from the following location on our ftp site:

ftp://ftp.analog.com/pub/tools/patches/Blackfin/OTP_Calibration_Value_Re

covery

Please consult the README file for the necessary steps required to run

this example. Note that this project should ONLY be used on EZ-Kits that

have the non-standard device.

Only EZ-Kits matching the identifying criteria listed above require a

workaround to update the OTP factory programming. All other Kits are

unaffected. The 'OTP Calibration Value Recovery' project must not be

applied to unaffected Kits that do not match this criteria.

 

Regards,

Processor Tools Support

 

QuoteReplyEditDelete

 

 

2008-09-24 21:07:08     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Rutger Hofman (NETHERLANDS)

Message: 62672   

 

Hmm... I try/demonstrate something else:

 

bfin> nand erase 0 0x800

 

NAND erase: device 0 offset 0x0, size 0x800

Erasing at 0x0 -- 6400% complete.

OK

bfin> nand dump 0

 

.... gives 'filled' data, e.g. line 3 is '22 de f8 0d 7c d6 ce 17  46 fc c2 00 70 b3 46 07'

 

bfin> nand dump 0

 

gives ff ff ff ...

 

and then, *exactly* alternating behaviour between the two responses.

 

Wouldn't one expect consistent nand dump 0 -> ff ff ff ... after a nand erase 0 0x800?

 

Rutger

 

 

 

QuoteReplyEditDelete

 

 

2008-09-24 21:23:44     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Mike Frysinger (UNITED STATES)

Message: 62673   

 

it depends.  u-boot will not touch pages it thinks are bad, so erase would have no effect on them.  you could try the scrub function.

QuoteReplyEditDelete

 

 

2008-09-24 21:25:27     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Mike Frysinger (UNITED STATES)

Message: 62674   

 

u-boot avoids using any IRQ related fields at all whenever possible and bit bangs everything

 

the reason i suggested Linux is that it would allow you test a more stable infrastructure and give you another point in the "it seems to be busted hardware"

QuoteReplyEditDelete

 

 

2008-09-25 10:43:43     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Rutger Hofman (NETHERLANDS)

Message: 62714   

 

My BF548 indeed had faulty OTP. I applied Analog's fix. Even though NFC was not listed with the affected parts, this has fixed my problem. I do a correct page 0 read, 10x in a row.

 

Thanks for the support here,

 

Rutger Hofman

 

VU Amsterdam

QuoteReplyEditDelete

 

 

2008-09-25 10:53:11     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Robin Getz (UNITED STATES)

Message: 62715   

 

Rutger:

 

What fix are you meaning?

 

-Robin

QuoteReplyEditDelete

 

 

2008-09-25 11:11:55     Re: NAND flash on ez-kit bf548: read/dump is not reproducible

Rutger Hofman (NETHERLANDS)

Message: 62716   

 

 

See my earlier post from last night:

 

http://blackfin.uclinux.org/gf/project/u-boot/forum/?action=ForumBrowse&_forum_action=MessageReply&message_id=62670

 

It contains Analog's full email message on the OTP bug/patch.

 

Rutger

Attachments

    Outcomes