Forum Discussion
Altera_Forum
Honored Contributor
19 years ago<div class='quotetop'>QUOTE </div>
--- Quote Start --- You should do it in two steps. First, with normal initramfs, and no kernel command line. Edit drivers/mtd/maps/altera.c , to the offset and size of your cfi flash. Remove unused mtd parts. Rebuild zImage, and check if mtd is detected correctly. If mtdblock0 is correct, then try mount it as jffs2, copy the rootfs. And then reboot again, to verify if all the data is correct. If all work without problems, then do the step2, rootfs to your mtd.[/b] --- Quote End --- hi hippo i have modified the driver in /mtd/maps/altera.c and canceled some options in the kernel munuconfig, then has removed some apps in ~/rootfs/bin dir and rebuilt kernel finally..... my booting info as following : uClinux/Nios II Altera Nios II support © 2004 Microtronix Datacom Ltd. Built 1 zonelists Kernel command line: PID hash table entries: 64 (order: 6, 1024 bytes) Dentry cache hash table entries: 2048 (order: 1, 8192 bytes) Inode-cache hash table entries: 1024 (order: 0, 4096 bytes) Memory available: 6444k/8192k RAM, 0k/0k ROM (1184k kernel code, 467k data) Mount-cache hash table entries: 512 SCSI subsystem initialized usbcore: registered new driver usbfs usbcore: registered new driver hub JFFS2 version 2.2. (NAND) © 2001-2003 Red Hat, Inc. io scheduler noop registered io scheduler deadline registered (default) Serial: JTAG UART driver $Revision: 1.4 $ ttyJ0 at MMIO 0x80c81120 (irq = 1) is a jtag_uart Altera NDK flash (AMD): Found 1 x16 devices at 0x0 in 8-bit bank Amd/Fujitsu Extended Query Table at 0x0040 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 1 MTD partitions on "Altera NDK flash (AMD)": 0x00800000-0x00c00000 : "romfs/jffs2" mtd: partition "romfs/jffs2" is out of reach -- disabled http://forum.niosforum.com/work2/style_emoticons/<#EMO_DIR#>/sad.gif usbmon: debugfs is not available driver isp1362-hcd, 2005-04-04 isp1362-hcd isp1362-hcd: ISP1362 Host Controller isp1362_hc_reset: isp1362-hcd isp1362-hcd: new USB bus registered, assigned bus number 1 isp1362-hcd isp1362-hcd: irq 4, io mem 0x80c810d0 isp1362_hc_start: isp1362-hcd isp1362-hcd: ISP1362 Memory usage: isp1362-hcd isp1362-hcd: ISTL: 2 * 256: 512 @ $0000:$0100 isp1362-hcd isp1362-hcd: INTL: 16 * ( 64+8): 1152 @ $0200 isp1362-hcd isp1362-hcd: ATL : 32 * ( 64+8): 2304 @ $0680 isp1362-hcd isp1362-hcd: USED/FREE: 3968 128 usb usb1: configuration# 1 chosen from 1 choice hub 1-0:1.0: USB hub found hub 1-0:1.0: 2 ports detected ISP1362 Host Controller, irq 4 Initializing USB Mass Storage driver... usbcore: registered new driver usb-storage USB Mass Storage support registered. Freeing unused kernel memory: 368k freed (0x138000 - 0x193000) init started: BusyBox v1.1.1-pre0 (2006.04.20-12:52+0000) multi-call binary usb 1-2: new full speed USB device using isp1362-hcd and address 2 BusyBox v1.1.1-pre0 (2006.04.20-12:52+0000) Built-in shell (musb 1-2: configurat ion# 1 chosen from 1 choice sh) Enter 'help' for a list of built-in commands. # scsi0 : SCSI emulation for USB Mass Storage devices Vendor: eUSB Model: Compact Flash Rev: 5.07 Type: Direct-Access ANSI SCSI revision: 02 SCSI device sda: 250880 512-byte hdwr sectors (128 MB) sda: Write Protect is off sda: assuming drive cache: write through SCSI device sda: 250880 512-byte hdwr sectors (128 MB) sda: Write Protect is off sda: assuming drive cache: write through sda: sda1 sd 0:0:0:0: Attached scsi removable disk sda # ls bin etc init mnt proc sbin tmp var dev home lib opt root sys usr# free total used free shared buffers Mem: 6812 5904 908 0 0 why the partition "romfs/jffs2" is out of reach ? How should I go to solve these problems ? thanks in advance !