Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
20 years ago

Kernel continuously rebooting

I am running linux 2.6 on a Altera Cyclone II Nios II dev board. I have created a system, kernal and file system. Every thing compiled, no problems but the kernel keep on rebooting after ---

Linux version 2.6.11-uc0 (Administrator@xaibear) (gcc version 3.4.1 (Altera Nios

II 5.0 b73))# 3 Tue Aug 23 11:45:05 SAST 2005

uClinux/Nios II

Altera Nios II support © 2004 Microtronix Datacom Ltd.

setup_arch: No persistant network settings signature at 007F0000

Built 1 zonelists

Kernel command line: root=/dev/mtdblock0 ro

PID hash table entries: 256 (order: 8, 4096 bytes)

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

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

Memory available: 30592k/32768k RAM, 0k/0k ROM (1499k kernel code, 309k data)

Mount-cache hash table entries: 512 (order: 0, 4096 bytes)

NET: Registered protocol family 16

NIOS serial driver version 0.0

ttyS0 (irq = 4) is a builtin NIOS UART

Serial: JTAG UART driver $Revision: 1.4 $

ttyJ0 at MMIO 0x821208d0 (irq = 1) is a jtag_uart

io scheduler noop registered

io scheduler anticipatory registered

io scheduler deadline registered

io scheduler cfq registered

RAMDISK driver initialized: 16 RAM disks of 4096K size 1024 blocksize

smc_probe: 85000 Khz Nios

SMSC LAN91C111 Driver (v2.1), (Linux Kernel 2.6)

eth0: SMC91C11xFD(rev:1) at 0x82110300 IRQ:6 MEMSIZE:8192b NOWAIT:0 ADDR: 00:07:

ed:00:00:00

smc_probe: 85000 Khz Nios

Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2

ide: Assuming 50MHz system bus speed for PIO modes; override with idebus=xx

CF: ctl=8

Altera NDK flash (AMD): Found 1 x16 devices at 0x0 in 8-bit bank

Amd/Fujitsu Extended Query Table at 0x0040

Altera NDK flash (AMD): CFI does not contain boot bank location. Assuming top.

number of CFI chips: 1

cfi_cmdset_0002: Disabling erase-suspend-program due to code brokenness.

cmdlinepart partition parsing not available

RedBoot partition parsing not available

Using Altera NDK partition definition

Creating 4 MTD partitions on "Altera NDK flash (AMD)":

0x00200000-0x00800000 : "romfs/jffs2"

0x00000000-0x00200000 : "loader/kernel"

0x00800000-0x00c00000 : "User configuration"

0x00c00000-0x01000000 : "safe configuration"

NET: Registered protocol family 2

IP: routing cache hash table of 512 buckets, 4Kbytes

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)

NET: Registered protocol family 1

NET: Registered protocol family 17

At this point it keeps rebooting

What is the problem and what should actually happen next???

Thank for your help

7 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi all

    I read all the other topics and threads, followed the guides. The exception address is in ddr sdram. I have tried negating the compact flash and the lan91c111 individually and all together. Nothing works.

    I'd appretiate any help?

    Thanks
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hey Rual,

    I've been encountering the same issue as yourself, and I posted it in an earlier thread, as a continuation to an earlier problem. I suppose it would've made more sense to start a new one up. I'll repost here, where it belongs. The only difference between you and I is that I'm using the Altera Stratix II DSP board, which there isn't a supplied Microtronix uClinux example for. Therefore, I have to generate the romfs from command line instead of using the developer, a known issue.

    repost

    I&#39;m still getting a continual reboot. It doesn&#39;t seem to matter if I use <base addy of flash> as from my core design or from the flash programmer for the command line genromfs execute. And yes, I clear flash before trying one or the other to ensure it&#39;s not a previous burn. However, one run went farther than any other and reported an error near the beginning and at the end that perhaps someone else is familiar with. Here&#39;s my boot sequence.

    uClinux/Nios II

    Altera Nios II support © 2004 Microtronix Datacom Ltd.

    setup_arch: No persistant network settings signature at 00FF0000

    Built 1 zonelists

    Kernel command line: root=/dev/mtdblock0 ro

    PID hash table entries: 128 (order: 7, 2048 bytes)

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

    Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)

    Memory available: 14472k/16384k RAM, 0k/0k ROM (1422k kernel code, 296k data)

    Mount-cache hash table entries: 512 (order: 0, 4096 bytes)

    NET: Registered protocol family 16

    Serial: JTAG UART driver $Revision: 1.4 $

    ttyJ0 at MMIO 0x82120940 (irq = 1) is a jtag_uart

    io scheduler noop registered

    io scheduler anticipatory registered

    io scheduler deadline registered

    io scheduler cfq registered

    RAMDISK driver initialized: 16 RAM disks of 4096K size 1024 blocksize

    smc_probe: 50000 Khz Nios

    Altera NDK flash (AMD): Found 1 x16 devices at 0x0 in 8-bit bank

    Amd/Fujitsu Extended Query Table at 0x0040

    Altera NDK flash (AMD): CFI does not contain boot bank location. Assuming top.

    number of CFI chips: 1

    cfi_cmdset_0002: Disabling erase-suspend-program due to code brokenness.

    cmdlinepart partition parsing not available

    RedBoot partition parsing not available

    Using Altera NDK partition definition

    Creating 4 MTD partitions on "Altera NDK flash (AMD)":

    0x00200000-0x00800000 : "romfs/jffs2"

    0x00000000-0x00200000 : "loader/kernel"

    0x00800000-0x00c00000 : "User configuration"

    0x00c00000-0x01000000 : "safe configuration"

    microtronix[mtd]: RAM probe address=0x200000 size=0x0

    Creating 1 MTD partitions on "RAM":

    0x00000000-0x00000000 : "ROMfs"

    mtd: partition "ROMfs" is out of reach -- disabled

    microtronix[mtd]: set ROMfs to be root filesystem

    NET: Registered protocol family 2

    IP: routing cache hash table of 512 buckets, 4Kbytes

    TCP established hash table entries: 1024 (order: 1, 8192 bytes)

    TCP bind hash table entries: 1024 (order: 0, 4096 bytes)

    TCP: Hash tables configured (established 1024 bind 1024)

    NET: Registered protocol family 1

    NET: Registered protocol family 17

    Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(31,0)
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Keplin,

    I&#39;m not sure your problems are the same. Looks like your problem lies with the file system you are creating.

    >>> microtronix[mtd]: RAM probe address=0x200000 size=0x0

    >>> Creating 1 MTD partitions on "RAM":

    >>> 0x00000000-0x00000000 : "ROMfs"

    >>> mtd: partition "ROMfs" is out of reach -- disabled

    The size is 0, and its address conficts with you flash ROMfs

    Doug
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Wait a minute, so the Kernel still thinks my romfs is located in 0x200000 on flash? I generated the filesystem under the command line and placed it at location 0x500000 instead. This is due to the fact that the DSP board has a different config and addresses factory at 0x200000, with that declared in the PTF. Could the Kernel be looking in the PTF and seeing that there&#39;s a config already located at 0x200000, therefore thinking there&#39;s a size of 0x0 (being 0x200000 to 0x200000)?

    How do I then point the Kernel to the right location to find the filesystem?

    Thanks for any help,

    Matt
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Matt,

    Update your altera.c file located in:

    /***/com.microtronix.nios2linux.kernel_1.4.0/linux-2.6.x/drivers/mtd/maps/altera.c

    Should probably copy it first to something like altera.c.orig (keep the original). Then update altera.c with what you want.

    Doug
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Keplin & Matt

    Thanks for your help

    I found some inconsistencies in the size of the flash allocated by uClinux for my system. I also found that the address lines for the flash chip has an offset in SOPC builder. The SOPC builder component&#39;s address[0] should be assigned to D15.A1, address[1] to A0 ......

    My system is now running OK

    Thanks again http://forum.niosforum.com/work2/style_emoticons/<#EMO_DIR#>/biggrin.gif