FAQ: [#6639] xip kernel unable to mount NFS root on 548/537(2011)

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

[#6639] xip kernel unable to mount NFS root on 548/537

Submitted By: Vivi Li

Open Date

2011-06-13 06:13:25     Close Date

2011-10-17 02:31:01

Priority:

Medium     Assignee:

steven miao

Status:

Closed     Fixed In Release:

N/A

Found In Release:

2011R1     Release:

Category:

N/A     Board:

N/A

Processor:

BF537     Silicon Revision:

Is this bug repeatable?:

Yes     Resolution:

Fixed

Uboot version or rev.:

    Toolchain version or rev.:

gcc4.3-2010_Dec_09

App binary format:

N/A     

Summary: xip kernel unable to mount NFS root on 548/537

Details:

 

On regression machine which test stamp537 write through mode, kernel xip failed with error of "No filesystem could mount root". This happened with both fdpic and shared-flat formats.

 

The last pass version:

--

kernel:    Linux release 2.6.36.2-ADI-2011R1-pre-svn9543, build #47 Fri Jan 7 12:24:41 CST 2011

toolchain: bfin-linux-uclibc-gcc release gcc version 4.3.5 (ADI-2010R1-RC4)

user-dist: release svn-10036, build #962 Fri Jan 7 12:31:31 CST 2011

--

 

Bellow is the error log:

--

U-Boot 2010.06 (ADI-2010R1-RC1) (Sep 29 2010 - 17:49:40)

 

CPU:   ADSP bf537-0.2 (Detected Rev: 0.2) (bypass boot)

Board: ADI BF537 stamp board

       Support: http://blackfin.uclinux.org/

Clock: VCO: 500 MHz, Core: 500 MHz, System: 125 MHz

RAM:   64 MiB

Flash: 4 MiB

In:    serial

Out:   serial

Err:   serial

KGDB:  [on serial] ready

Net:   bfin_mac

Hit any key to stop autoboot:  5 ^H^H^H 0

bfin> successful reset attemp

tftpboot 0x1000000 vmImage

Using bfin_mac device

TFTP from server 10.100.4.174; our IP address is 10.100.4.50

Filename 'vmImage'.

Load address: 0x1000000

Loading: *^H#################################################################

         #################################################################

         ################

done

Bytes transferred = 2139176 (20a428 hex)

bfin> protect off 20040000 203effff

........................................................... done

Un-Protected 59 sectors

bfin> erase 20040000 203effff

 

........................................................... done

Erased 59 sectors

bfin> cp.b 0x1000000 20040000 0x20a428

Copy to Flash... done

bfin> set bootargs root=/dev/nfs rw nfsroot=$(serverip):/tftpboot/romfs console=ttyBF0,57600

bfin> run addip

bfin> bootm 20040000

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

   Image Name:   bf537-0.2-2.6.39.1-ADI-2011R1-pr

   Created:      2011-06-10  15:49:52 UTC

   Image Type:   Blackfin Linux Kernel Image (uncompressed)

   Data Size:    2139112 Bytes = 2 MiB

   Load Address: 20040040

   Entry Point:  201a8734

   Verifying Checksum ... OK

   Loading Kernel Image ... OK

OK

Starting Kernel at = 201a8734

console [ttyBF0] enabled, bootconsole disabled

Calibrating delay loop... 983.04 BogoMIPS (lpj=1966080)

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 (34 KB free)

NET: Registered protocol family 16

Blackfin DMA Controller

stamp_init(): registering device resources

bio: create slab <bio-0> at 0

Switching to clocksource bfin_cs_cycles

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

RPC: Registered udp transport module.

RPC: Registered tcp transport module.

RPC: Registered tcp NFSv4.1 backchannel transport module.

debug-mmrs: setting up Blackfin MMR debugfs

msgmni has been set to 110

io scheduler noop registered (default)

bfin-uart: Blackfin serial driver

bfin-uart.0: ttyBF0 at MMIO 0xffc00400 (irq = 18) is a BFIN-UART

brd: module loaded

bfin_mii_bus: probed

bfin_mac: attached PHY driver [SMSC LAN83C185] (mii_bus:phy_addr=0:01, irq=-1, mdc_clk=2500000Hz(mdc_div=24)@sclk=125MHz)

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

TCP cubic registered

NET: Registered protocol family 17

IP-Config: Complete:

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

     host=bf537-stamp, domain=, nis-domain=(none),

     bootserver=10.100.4.174, rootserver=10.100.4.174, rootpath=

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

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

VFS: Unable to mount root fs via NFS, trying floppy.

List of all partitions:

No filesystem could mount root, tried:

Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)

Hardware Trace:

   0 Target : <0x201a102c> { _dump_stack + 0x0 }

     Source : <0x201a10da> { _panic + 0x6a } CALL (P2)

   1 Target : <0x201a10d2> { _panic + 0x62 }

     Source : <0x201a123e> { _printk + 0x1a } RTS

   2 Target : <0x201a123a> { _printk + 0x16 }

     Source : <0x2005256a> { _vprintk + 0x17e } RTS

   3 Target : <0x2005255e> { _vprintk + 0x172 }

     Source : <0xffa00da2> { __common_int_entry + 0xe6 } RTI

   4 Target : <0xffa00d40> { __common_int_entry + 0x84 }

     Source : <0xffa00b68> { _return_from_int + 0x58 } RTS

   5 Target : <0xffa00b68> { _return_from_int + 0x58 }

     Source : <0xffa00b3e> { _return_from_int + 0x2e } IF !CC JUMP pcrel

   6 Target : <0xffa00b10> { _return_from_int + 0x0 }

     Source : <0xffa00d3e> { __common_int_entry + 0x82 } CALL (P2)

   7 Target : <0xffa00d34> { __common_int_entry + 0x78 }

     Source : <0xffa003ca> { _asm_do_IRQ + 0x82 } RTS

   8 Target : <0xffa003c2> { _asm_do_IRQ + 0x7a }

     Source : <0x2005604c> { ___local_bh_enable + 0x38 } RTS

   9 Target : <0x20056014> { ___local_bh_enable + 0x0 }

     Source : <0x2005677c> { ___do_softirq + 0xd4 } JUMP (P2)

  10 Target : <0x20056768> { ___do_softirq + 0xc0 }

     Source : <0x2005674c> { ___do_softirq + 0xa4 } IF CC JUMP pcrel

  11 Target : <0x20056736> { ___do_softirq + 0x8e }

     Source : <0x2007b2e2> { _rcu_bh_qs + 0x1e } RTS

  12 Target : <0x2007b2da> { _rcu_bh_qs + 0x16 }

     Source : <0x2007b004> { _rcu_qsctr_help + 0x50 } RTS

  13 Target : <0x2007afee> { _rcu_qsctr_help + 0x3a }

     Source : <0x2007afc0> { _rcu_qsctr_help + 0xc } IF CC JUMP pcrel

  14 Target : <0x2007afb4> { _rcu_qsctr_help + 0x0 }

     Source : <0x2007b2d8> { _rcu_bh_qs + 0x14 } CALL (P2)

  15 Target : <0x2007b2c4> { _rcu_bh_qs + 0x0 }

     Source : <0x20056734> { ___do_softirq + 0x8c } CALL (P1)

Stack info:

SP: [0x0201beec] <0x0201beec> /* kernel dynamic memory (maybe user-space) */

FP: (0x0201bfb0)

Memory from 0x0201bee0 to 0201c000

0201bee0: 20101da4  0201beec  0000cb3c [201e4f78]<201a10dc> 2010508c  201e4f78  000063cb

0201bf00: 000063cb  000063cb  0201bf34  0002845c <201a1f50> 02076000  02076000  201a1224

0201bf20: 0201bf40  20101da4  201e4ec8  0000cb3c  00000004  0201bf40  0201bf40  0002c8a8

0201bf40: 6e6b6e75  2d6e776f  636f6c62  2c32286b  02002930 <2009c0ce> 00001068  00006180

0201bf60: 00001068 <201a206c> 00001068  000157b4  00028414  00200000  00000000  00000000

0201bf80: 00000000  201e4c44  000724a0  00000001  0002c7a8  0002c7a8  0002c3a4 <201a2194>

0201bfa0: 00028418  ffa01990  00000000  02039820 (00000000)<201a14b8> 2009d088  20040040

0201bfc0: 0002d5c0 <201a14d2> 2009d088  20040040  0002d7c8  00000000  00000000  00000000

0201bfe0: 00000000 <2004062e> 00000000  00000000  00000000  00000000  ffffffff  00000006

Return addresses in stack:

    address : <0x201a10dc> { _panic + 0x6c }

    address : <0x201a1f50> { _mount_block_root + 0x184 }

    address : <0x2009c0ce> { _sys_mknod + 0x22 }

    address : <0x201a206c> { _mount_root + 0xa0 }

    address : <0x201a2194> { _prepare_namespace + 0xec }

   frame  1 : <0x201a14b8> { _kernel_init + 0x124 }

    address : <0x201a14d2> { _kernel_init + 0x13e }

    address : <0x2004062e> { _kernel_thread_helper + 0x6 }

--

 

Follow-ups

 

--- steven miao                                              2011-06-21 05:18:11

xip can boot from nfs, it seems your rootfs corrupt

 

bfin> printenv

addip=set bootargs $(bootargs)

ip=$(ipaddr):$(serverip):$(gatewayip):$(netmask):$(hostname):eth0:off

autoload=no

baudrate=57600

bootargs=root=/dev/mtdblock0 rw clkin_hz=25000000

earlyprintk=serial,uart0,57600 console=ttyBF0,57600

bootcmd=run ramboot

bootdelay=2

dnsip=10.99.27.40

ethact=bfin_mac

ethaddr=30:00:02:03:04:05

flashboot=bootm 0x20100000

gatewayip=10.99.22.1

hostname=bf537-stamp

ipaddr=10.100.4.50

loadaddr=0x1000000

loads_echo=1

nc=set ncip ${serverip};set stdin nc;set stdout nc

netmask=255.255.255.0

nfsargs=set bootargs root=/dev/nfs rw

nfsroot=$(serverip):$(rootpath),tcp,nfsvers=3

nfsboot=tftp $(loadaddr) $(nfsfile);run nfsargs;run addip;bootm

nfsfile=vmImage

ramargs=set bootargs root=/dev/mtdblock0 rw clkin_hz=25000000

earlyprintk=serial,uart0,57600 console=ttyBF0,57600

ramboot=tftp $(loadaddr) $(ramfile);run ramargs;run addip;bootm

ramfile=uImage

rootpath=/romfs

serverip=10.100.4.174

stderr=serial

stdin=serial

stdout=serial

ubootfile=u-boot.bin

update=tftp $(loadaddr) $(ubootfile);protect off 0x20000000 +$(filesize);erase

0x20000000 +$(filesize);cp.b $(loadaddr) 0x20000000 $(filesize)

 

Environment size: 1176/8188 bytes

bfin> dhcp

Random delay: 991 ms...

BOOTP broadcast 1

DHCP client bound to address 10.99.22.101

bfin> set serverip 10.99.22.119

bfin> tftpboot 0x1000000 vmImage

Using bfin_mac device

TFTP from server 10.99.22.119; our IP address is 10.99.22.101

Filename 'vmImage'.

Load address: 0x1000000

Loading: #################################################################

     #################################################################

     ################

done

Bytes transferred = 2140740 (20aa44 hex)

bfin> protect off 20040000 203effff

........................................................... done

Un-Protected 59 sectors

bfin> erase 20040000 203effff

 

........................................................... done

Erased 59 sectors

bfin> cp.b 0x1000000 20040000 $(filesize)

Copy to Flash... done

bfin> set rootpath /tftpboot/romfs

bfin> run nfsargs

bfin> run addip

bfin> bootm 20040000

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

   Image Name:   bf537-0.2-2.6.39.1-ADI-2011R1-pr

   Created:      2011-06-21   9:04:49 UTC

   Image Type:   Blackfin Linux Kernel Image (uncompressed)

   Data Size:    2140676 Bytes = 2 MiB

   Load Address: 20040040

   Entry Point:  201a8d38

   Verifying Checksum ... OK

   Loading Kernel Image ... OK

OK

Starting Kernel at = 201a8d38

console [ttyBF0] enabled, bootconsole disabled

Calibrating delay loop... 983.04 BogoMIPS (lpj=1966080)

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 (34 KB free)

NET: Registered protocol family 16

Blackfin DMA Controller

stamp_init(): registering device resources

bio: create slab <bio-0> at 0

Switching to clocksource bfin_cs_cycles

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

RPC: Registered udp transport module.

RPC: Registered tcp transport module.

RPC: Registered tcp NFSv4.1 backchannel transport module.

debug-mmrs: setting up Blackfin MMR debugfs

msgmni has been set to 110

io scheduler noop registered (default)

bfin-uart: Blackfin serial driver

bfin-uart.0: ttyBF0 at MMIO 0xffc00400 (irq = 18) is a BFIN-UART

brd: module loaded

bfin_mii_bus: probed

bfin_mac: attached PHY driver [SMSC LAN83C185] (mii_bus:phy_addr=0:01, irq=-1,

mdc_clk=2500000Hz(mdc_div=24)@sclk=125MHz)

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

TCP cubic registered

NET: Registered protocol family 17

IP-Config: Complete:

     device=eth0, addr=10.99.22.101, mask=255.255.255.0, gw=10.99.22.1,

     host=bf537-stamp, domain=, nis-domain=(none),

     bootserver=10.99.22.119, rootserver=10.99.22.119, rootpath=

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

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

VFS: Mounted root (nfs filesystem) on device 0:11.

                           _____________________________________

        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.uclinux.org/

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

 

Have a lot of fun...

 

 

BusyBox v1.16.2 (2010-11-12 10:31:22 CST) hush - the humble shell

 

root:/>

root:/>

 

--- Vivi Li                                                  2011-09-05 05:36:26

Now this bug happens on all bf548/bf537 in latest trunk, for both fdpic and

shared-flat.

 

--- steven miao                                              2011-09-06 01:24:30

it seems add a retry option in bootargs can mount nfs rootfs successful

 

root=/dev/nfs rw nfsroot=10.99.24.68:/tftpboot/romfs,tcp,nfsvers=3,retry=10

clkin_hz=25000000 earlyprintk=serial,uart1,57600 console=tty0

console=ttyBF1,57600

ip=10.99.24.79:10.99.24.68:10.99.24.1:255.255.255.0:bf548-ezkit:eth0:off

 

details for mount options

 

http://linux.die.net/man/5/nfs

 

retry=n

 

The number of minutes to retry an NFS mount operation in the foreground or

background before giving up. The default value for forground mounts is 2

minutes. The default value for background mounts is 10000 minutes, which is

roughly one week.

 

it is said the default value for forground mounts is 2 minutes, but on blackfin

it appears less than 2 minutes, maybe the time on blackfin is not precise.

 

--- Vivi Li                                                  2011-09-07 22:59:52

I set retry and timeo in bootargs, still can not boot up.

 

--- steven miao                                              2011-09-23 05:58:57

still nfs mount timeout when xip

 

--- steven miao                                              2011-10-14 04:32:59

I found add a bootdelay=1 bootarg can boot

 

--- Vivi Li                                                  2011-10-17 02:35:50

I think you mean add rootdelay=1 in bootargs.

It can work, so close it.

 

 

 

    Files

    Changes

    Commits

    Dependencies

    Duplicates

    Associations

    Tags

 

File Name     File Type     File Size     Posted By

config.linux.kernel_xip.fdpic    application/octet-stream    29134    Vivi Li

Outcomes