FAQ: [#6615] flash erase on bf526-ezkit fails(2011)

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

[#6615] flash erase on bf526-ezkit fails

Submitted By: Mingquan Pan

Open Date

2011-05-27 04:36:47     Close Date

2011-06-02 01:20:33

Priority:

Medium     Assignee:

steven miao

Status:

Closed     Fixed In Release:

N/A

Found In Release:

2011R1     Release:

Category:

N/A     Board:

N/A

Processor:

ALL     Silicon Revision:

Is this bug repeatable?:

Yes     Resolution:

Fixed

Uboot version or rev.:

    Toolchain version or rev.:

5013

App binary format:

N/A     

Summary: flash erase on bf526-ezkit fails

Details:

 

flash erase on bf526-ezkit fails.

 

## Booting kernel from Legacy Image at 02000000 ...

   Image Name:   bf526-0.0-2.6.39-rc7-ADI-2011R1-

   Created:      2011-05-18  20:16:27 UTC

   Image Type:   Blackfin Linux Kernel Image (gzip compressed)

   Data Size:    4058006 Bytes = 3.9 MiB

   Load Address: 00001000

   Entry Point:  00216c64

   Verifying Checksum ... OK

   Uncompressing Kernel Image ... OK

Starting Kernel at = 00216c64

Linux version 2.6.39-rc7-ADI-2011R1-pre-svn9892 (test@uclinux81-bf526) (gcc version 4.3.5 (ADI-trunk/svn-5013) ) #588 Thu May 19 04:16:18 CST 2011

register early platform devices

bootconsole [early_shadow0] enabled

bootconsole [early_BFuart1] enabled

early printk enabled on early_BFuart1

Board Memory: 64MB

Kernel Managed Memory: 64MB

Memory map:

  fixedcode = 0x00000400-0x00000490

  text      = 0x00001000-0x0016aed8

  rodata    = 0x0016aed8-0x001e4ba0

  bss       = 0x001e5000-0x001f6bcc

  data      = 0x001f6bcc-0x0020e000

    stack   = 0x0020c000-0x0020e000

  init      = 0x0020e000-0x00773000

  available = 0x00773000-0x03f00000

  DMA Zone  = 0x03f00000-0x04000000

Hardware Trace active and enabled

Boot Mode: 1

Blackfin support (C) 2004-2010 Analog Devices, Inc.

Compiled for ADSP-BF526 Rev 0.0

Blackfin Linux support by http://blackfin.uclinux.org/

Processor Speed: 400 MHz core clock and 80 MHz System Clock

NOMPU: setting up cplb tables

Instruction Cache Enabled for CPU0

  External memory: cacheable in instruction cache

Data Cache Enabled for CPU0

  External memory: cacheable (write-back) in data cache

Built 1 zonelists in Zone order, mobility grouping off.  Total pages: 16002

Kernel command line: root=/dev/mtdblock0 rw ip=10.100.4.50 earlyprintk=serial,uart1,57600 console=ttyBF1,57600 ip=10.100.4.50:10.100.4.174:10.100.4.174:255.255.255.0:bf526-ezbrd:eth0:off

PID hash table entries: 256 (order: -2, 1024 bytes)

Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)

Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)

Memory available: 56276k/65536k RAM, (5524k init code, 1447k kernel code, 653k data, 1024k dma, 612k reserved)

NR_IRQS:159

Configuring Blackfin Priority Driven Interrupts

console [ttyBF1] enabled, bootconsole disabled

console [ttyBF1] enabled, bootconsole disabled

Calibrating delay loop... 792.57 BogoMIPS (lpj=1585152)

pid_max: default: 32768 minimum: 301

Mount-cache hash table entries: 512

Blackfin Scratchpad data SRAM: 4 KB

Blackfin L1 Data A SRAM: 16 KB (16 KB free)

Blackfin L1 Data B SRAM: 16 KB (16 KB free)

Blackfin L1 Instruction SRAM: 48 KB (41 KB free)

NET: Registered protocol family 16

Blackfin DMA Controller

ezbrd_init(): registering device resources

bio: create slab <bio-0> at 0

SCSI subsystem initialized

bfin-spi bfin-spi.0: Blackfin on-chip SPI Controller Driver, Version 1.0, regs_base@ffc00500, dma channel@7

usbcore: registered new interface driver usbfs

usbcore: registered new interface driver hub

usbcore: registered new device driver usb

i2c-bfin-twi i2c-bfin-twi.0: Blackfin BF5xx on-chip I2C TWI Contoller, regs_base@ffc01400

musb-hdrc: version 6.0, musb-dma, host, debug=0

musb-hdrc musb-hdrc: MUSB HDRC host driver

musb-hdrc musb-hdrc: new USB bus registered, assigned bus number 1

hub 1-0:1.0: USB hub found

hub 1-0:1.0: 1 port detected

musb-hdrc musb-hdrc: USB Host mode controller at ffc03800 using DMA, IRQ 59

NET: Registered protocol family 2

IP route cache hash table entries: 1024 (order: 0, 4096 bytes)

TCP established hash table entries: 2048 (order: 2, 16384 bytes)

TCP bind hash table entries: 2048 (order: 1, 8192 bytes)

TCP: Hash tables configured (established 2048 bind 2048)

TCP reno registered

UDP hash table entries: 256 (order: 0, 4096 bytes)

UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)

NET: Registered protocol family 1

debug-mmrs: setting up Blackfin MMR debugfs

JFFS2 version 2.2. (NAND) © 2001-2006 Red Hat, Inc.

msgmni has been set to 109

io scheduler noop registered (default)

bfin-uart: Blackfin serial driver

bfin-uart.1: ttyBF1 at MMIO 0xffc02000 (irq = 31) is a BFIN-UART

bfin-otp: initialized

brd: module loaded

physmap platform flash device: 00400000 at 20000000

physmap-flash.0: Found 1 x16 devices at 0x0 in 16-bit bank. Manufacturer ID 0x000020 Chip ID 0x008815

Intel/Sharp Extended Query Table at 0x0039

Intel/Sharp Extended Query Table at 0x0039

Intel/Sharp Extended Query Table at 0x0039

Intel/Sharp Extended Query Table at 0x0039

Intel/Sharp Extended Query Table at 0x0039

cfi_cmdset_0001: Erase suspend on write enabled

cmdlinepart partition parsing not available

RedBoot partition parsing not available

Using physmap partition information

Creating 3 MTD partitions on "physmap-flash.0":

0x000000000000-0x000000040000 : "bootloader(nor)"

0x000000040000-0x000000200000 : "linux kernel(nor)"

0x000000200000-0x000000400000 : "file system(nor)"

m25p80 spi0.1: sst25wf040 (512 Kbytes)

Creating 2 MTD partitions on "m25p80":

0x000000000000-0x000000040000 : "bootloader(spi)"

0x000000040000-0x000000080000 : "linux kernel(spi)"

bfin_mii_bus: probed

bfin_mac: attached PHY driver [Generic PHY] (mii_bus:phy_addr=0:01, irq=-1, mdc_clk=2500000Hz(mdc_div=15)@sclk=80MHz)

bfin_mac bfin_mac.0: eth0: Blackfin on-chip Ethernet MAC driver, Version 1.1

Initializing USB Mass Storage driver...

usbcore: registered new interface driver usb-storage

USB Mass Storage support registered.

rtc-bfin rtc-bfin: rtc core: registered rtc-bfin as rtc0

bfin-wdt: initialized: timeout=20 sec (nowayout=0)

usbcore: registered new interface driver usbhid

usbhid: USB HID core driver

TCP cubic registered

NET: Registered protocol family 17

rtc-bfin rtc-bfin: setting system clock to 2004-05-31 02:57:01 UTC (1085972221)

dma_alloc_init: dma_page @ 0x0275c000 - 256 pages at 0x03f00000

IP-Config: Complete:

     device=eth0, addr=10.100.4.50, mask=255.255.255.0, gw=10.100.4.174,

     host=bf526-ezbrd, domain=, nis-domain=(none),

     bootserver=10.100.4.174, rootserver=10.100.4.174, rootpath=

Freeing unused kernel memory: 5524k freed

                           _____________________________________

        a8888b.           / Welcome to the uClinux distribution \

       d888888b.         /       _     _                         \

       8P"YP"Y88        /       | |   |_|            __  __ (TM)  |

       8|o||o|88  _____/        | |    _ ____  _   _ \ \/ /       |

       8'    .88       \        | |   | |  _ \| | | | \  /        |

       8`._.' Y8.       \       | |__ | | | | | |_| | /  \        |

      d/      `8b.       \      \____||_|_| |_|\____|/_/\_\       |

     dP   .    Y8b.       \   For embedded processors including   |

    d8:'  "  `::88b        \    the Analog Devices Blackfin      /

   d8"         'Y88b        \___________________________________/

  :8P    '      :888

   8a.   :     _a88P         For further information, check out:

._/"Yaa_:   .| 88P|            - http://blackfin.uclinux.org/

\    YP"    `| 8P  `.          - http://docs.blackfin.uclinux.org/

/     \.___.d|    .'           - http://www.ucPinux.org/

`--..__)8888P`._.'  jgs/a:f    - http://www.analog.com/blackfin

 

Have a lot of fun...

HY: 0:01 - Link is Up - 100/Full

 

 

BusyBox v1.18.4 (2011-05-18 23:37:48 CST) hush - the humble shell

 

root:/> version

kernel:    Linux release 2.6.39-rc7-ADI-2011R1-pre-svn9892, build #588 Thu May 19 04:16:18 CST 2011

toolchain: bfin-uclinux-gcc release gcc version 4.3.5 (ADI-trunk/svn-5013)

user-dist: release svn-10167, build #7173 Thu May 19 04:15:15 CST 2011

root:/> successful boot attempt

************** STEP 3: MTD test

 

cat /proc/mtd

dev:    size   erasesize  name

mtd0: 00040000 00010000 "bootloader(nor)"

mtd1: 001c0000 00010000 "linux kernel(nor)"

mtd2: 00200000 00010000 "file system(nor)"

mtd3: 00040000 00001000 "bootloader(spi)"

mtd4: 00040000 00001000 "linux kernel(spi)"

root:/>

Case 1 ...PASS

 

Case 1 ...PASS

 

************** STEP 4: Erase MTD

 

flash_unlock /dev/mtd2

root:/> flash_erase -j /dev/mtd2 0 0

Erasing 64 Kibyte @ 0 --  0 % complete flash_erase:  Cleanmarker written at 0

Erasing 64 Kibyte @ 10000 --  3 % complete flash_erase:  Cleanmarker written at 10000

Erasing 64 Kibyte @ 20000 --  6 % complete flash_erase:  Cleanmarker written at 20000

Erasing 64 Kibyte @ 30000 --  9 % complete flash_erase:  Cleanmarker written at 30000

Erasing 64 Kibyte @ 40000 -- 12 % complete flash_erase:  Cleanmarker written at 40000

Erasing 64 Kibyte @ 50000 -- 15 % complete flash_erase:  Cleanmarker written at 50000

Erasing 64 Kibyte @ 60000 -- 18 % complete flash_erase:  Cleanmarker written at 60000

Erasing 64 Kibyte @ 70000 -- 21 % complete flash_erase:  Cleanmarker written at 70000

Erasing 64 Kibyte @ 80000 -- 25 % complete flash_erase:  Cleanmarker written at 80000

Erasing 64 Kibyte @ 90000 -- 28 % complete flash_erase:  Cleanmarker written at 90000

Erasing 64 Kibyte @ a0000 -- 31 % complete flash_erase:  Cleanmarker written at a0000

Erasing 64 Kibyte @ b0000 -- 34 % complete flash_erase:  Cleanmarker written at b0000

Erasing 64 Kibyte @ c0000 -- 37 % complete flash_erase:  Cleanmarker written at c0000

Erasing 64 Kibyte @ d0000 -- 40 % complete flash_erase:  Cleanmarker written at d0000

Erasing 64 Kibyte @ e0000 -- 43 % complete flash_erase:  Cleanmarker written at e0000

Erasing 64 Kibyte @ f0000 -- 46 % complete flash_erase:  Cleanmarker written at f0000

Erasing 64 Kibyte @ 100000 -- 50 % complete flash_erase:  Cleanmarker written at 100000

Erasing 64 Kibyte @ 110000 -- 53 % complete flash_erase:  Cleanmarker written at 110000

Erasing 64 Kibyte @ 120000 -- 56 % complete flash_erase:  Cleanmarker written at 120000

Erasing 64 Kibyte @ 130000 -- 59 % complete flash_erase:  Cleanmarker written at 130000

Erasing 64 Kibyte @ 140000 -- 62 % complete flash_erase:  Cleanmarker written at 140000

Erasing 64 Kibyte @ 150000 -- 65 % complete flash_erase:  Cleanmarker written at 150000

Erasing 64 Kibyte @ 160000 -- 68 % complete flash_erase:  Cleanmarker written at 160000

Erasing 64 Kibyte @ 170000 -- 71 % complete flash_erase:  Cleanmarker written at 170000

Erasing 64 Kibyte @ 180000 -- 75 % complete flash_erase:  Cleanmarker written at 180000

Erasing 64 Kibyte @ 190000 -- 78 % complete flash_erase:  Cleanmarker written at 190000

Erasing 64 Kibyte @ 1a0000 -- 81 % complete flash_erase:  Cleanmarker written at 1a0000

Erasing 64 Kibyte @ 1b0000 -- 84 % complete flash_erase:  Cleanmarker written at 1b0000

Erasing 64 Kibyte @ 1c0000 -- 87 % complete flash_erase:  Cleanmarker written at 1c0000

Erasing 64 Kibyte @ 1d0000 -- 90 % complete flash_erase:  Cleanmarker written at 1d0000

Erasing 64 Kibyte @ 1e0000 -- 93 % complete flash_erase:  Cleanmarker written at 1e0000

Erasing 64 Kibyte @ 1f0000 -- 96 % complete libmtd: error!: MEMERASE64 ioctl failed for eraseblock 31 (mtd2)

        error 30 (Read-only file system)

flash_erase: error!: /dev/mtd2: MTD Erase failure

             error 30 (Read-only file system)

Erasing 64 Kibyte @ 200000 -- 100 % complete

root:/>

Last passed time: 2010_Sep_28_13_58, ucdist ver: 9833, kernel ver: 9171

 

Case 2 ...FAIL

 

 

Follow-ups

 

--- Mike Frysinger                                           2011-05-28 17:14:34

probably the same as bug #4884

 

--- Mingquan Pan                                             2011-05-29 22:40:32

This should be a different one, since when #4884 is filed, this bug isn't

occouring and this case is good.

 

--- Mike Frysinger                                           2011-05-29 22:46:19

i imagine that's merely by accident

 

--- steven miao                                              2011-05-30 04:04:24

it's mtd-utils's issue, flash_unlock miss unlocking the last erase block of mtd

partion.

 

--- Mingquan Pan                                             2011-06-02 01:24:50

Yes, it can flash erase to the end now.

 

Close.

 

 

 

    Files

    Changes

    Commits

    Dependencies

    Duplicates

    Associations

    Tags

 

File Name     File Type     File Size     Posted By

No Files Were Found

Attachments

    Outcomes