Ramdisk : Linux 2.6 : U-boot :: RAMDISK: incomplete write (-28 != 32768) 52428800
Matias Sundman (AS/EAB)
matias.sundman at ericsson.com
Thu Mar 22 00:43:05 EST 2007
Hi Guys,
I just realized what I did wrong ;
When making the ramdisk ;
:
:
dd if=/dev/zero of=ramdisk bs=1k count=500000
:
:
I should use count 50000 instead of 500000.
:-))
Thx // M
> _____________________________________________
> From: Matias Sundman (AS/EAB)
> Sent: den 21 mars 2007 14:08
> To: 'linuxppc-embedded at ozlabs.org'
> Subject: Ramdisk : Linux 2.6 : U-boot :: RAMDISK: incomplete
> write (-28 != 32768) 52428800
>
> Hello,
> I am trying to get a U-boot multi-image to function properly for my
> custom board.
> I've had it working with the 2.4 kernel but having problems with 2.6.
>
> Here is what I get;
> ----------------------------------------------------------------------
> -------------------------------
> [U-boot] Platform Initialized ,
> handing over control to [Linux]
> Linux version 2.6.14.7 (matias at schizo) (gcc version 3.4.4 ) #11 Wed
> Mar 21 13:41:22 CET 2007
> Ericsson, MXB4 port
> Using IDMA1 for MPC8260 device erratum PCI 9 workaround
> SIUMCR is value = 5200000
> arch/ppc/syslib/m82xx_pci.c: The PCI bus is 50 Mhz.
> Waiting 0.5 seconds after deasserting RST...
> Built 1 zonelists
> Kernel command line: mem=0x0F000000 root=/dev/ram
> ip=$ipaddr:$serverip:$gatewayi
> p:$netmask:$hostname:eth0:off console=ttyCPM0,115200
> PID hash table entries: 1024 (order: 10, 16384 bytes)
> Warning: real time clock seems stuck!
> Console: colour dummy device 80x25
> Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
> Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
> Memory: 216576k available (1864k kernel code, 580k data, 108k init, 0k
> highmem)
> Security Framework v1.0.0 initialized
> Capability LSM initialized
> Mount-cache hash table entries: 512
> checking if image is initramfs...it isn't (no cpio magic); looks like
> an initrd
> softlockup thread 0 started up.
> Freeing initrd memory: 24153k freed
> NET: Registered protocol family 16
> PCI: Probing PCI hardware
> PCI: Cannot allocate resource region 0 of device 0000:00:00.0
> PCI: Cannot allocate resource region 1 of device 0000:00:00.0
> PCI: Cannot allocate resource region 0 of device 0000:00:0e.0
> PCI: Cannot allocate resource region 0 of device 0000:00:0f.0
> PCI: Cannot allocate resource region 0 of device 0000:00:10.0
> Registering GDB sysrq handler
> JFFS2 version 2.2. (NAND) (C) 2001-2003 Red Hat, Inc.
> Initializing Cryptographic API
> Serial: CPM driver $Revision: 0.01 $
> ttyCPM0 at MMIO map 0xf0011a00 mem 0x0 (irq = 40) is a CPM UART
> ttyCPM1 at MMIO map 0xf0011a20 mem 0x0 (irq = 41) is a CPM UART
> ttyCPM2 at MMIO map 0xf0011a40 mem 0x0 (irq = 42) is a CPM UART
> ttyCPM3 at MMIO map 0xf0011a60 mem 0x0 (irq = 43) is a CPM UART
> io scheduler noop registered
> io scheduler anticipatory registered
> io scheduler deadline registered
> io scheduler cfq registered
> RAMDISK driver initialized: 1 RAM disks of 51200K size 1024 blocksize
> loop: loaded (max 8 devices)
> physmap flash device: 2000000 at fe000000
> phys_mapped_flash: Found 1 x16 devices at 0x0 in 16-bit bank
> Amd/Fujitsu Extended Query Table at 0x0040
> phys_mapped_flash: 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
> mtd: Giving out device 0 to phys_mapped_flash
> i2c /dev entries driver
> eth0: FCC ENET Version 0.3, 00:01:ec:b4:07:e6
> eth0: Phy @ 0x0, type XXB-BCM (0x00406322)
> eth1: FCC ENET Version 0.3, 00:01:ec:f4:07:e6
> eth1: Phy @ 0x1, type XXB-BCM (0x00406322)
> eth2: FCC ENET Version 0.3, 00:01:ec:b4:07:e6
> eth2: Phy @ 0x2, type XXB-BCM (0x00406322)
> NET: Registered protocol family 2
> IP route cache hash table entries: 2048 (order: 1, 8192 bytes)
> TCP established hash table entries: 8192 (order: 3, 32768 bytes)
> TCP bind hash table entries: 8192 (order: 3, 32768 bytes)
> TCP: Hash tables configured (established 8192 bind 8192)
> TCP reno registered
> ip_tables: (C) 2000-2002 Netfilter core team
> TCP bic registered
> NET: Registered protocol family 1
> NET: Registered protocol family 17
> 802.1Q VLAN Support v1.8 Ben Greear <greearb at candelatech.com>
> All bugs added by David S. Miller <davem at redhat.com>
> eth0: config: auto-negotiation on, 100FDX, 100HDX, 10FDX, 10HDX.
> IP-Config: Unable to set interface netmask (-22).
> RAMDISK: Compressed image found at block 0
> RAMDISK: incomplete write (-28 != 32768) 52428800
> VFS: Mounted root (ext2 filesystem) readonly.
> Freeing unused kernel memory: 108k init
> attempt to access beyond end of device
> ram0: rw=0, want=622600, limit=102400
> EXT2-fs error (device ram0): ext2_get_inode: unable to read inode
> block - inode=
> 78129, block=311299
> Warning: unable to open an initial console.
> attempt to access beyond end of device
> ram0: rw=0, want=688136, limit=102400
> EXT2-fs error (device ram0): ext2_get_inode: unable to read inode
> block - inode=
> 86353, block=344067
> attempt to access beyond end of device
> ram0: rw=0, want=311304, limit=102400
> EXT2-fs error (device ram0): ext2_get_inode: unable to read inode
> block - inode=
> 39065, block=155651
> attempt to access beyond end of device
> ram0: rw=0, want=589832, limit=102400
> EXT2-fs error (device ram0): ext2_get_inode: unable to read inode
> block - inode=
> 74017, block=294915
> Kernel panic - not syncing: No init found. Try passing init= option
> to kernel.
> <0>Rebooting in 180 seconds..
> ----------------------------------------------------------------------
> -------------------------------
>
> This is the way I build the Multi-Image;
>
> #!/bin/bash
> clear
> echo 'Producing Multi Image File'
> echo 'You are root RIGHT?!'
> dd if=/dev/zero of=ramdisk bs=1k count=500000
> mke2fs -F -v -m0 ramdisk
> mount -o loop ramdisk /mnt/initrd2/
> cp -a /tftpboot/rootfs_mxb4_1/* /mnt/initrd2/
> umount /mnt/initrd2
> gzip -9 ramdisk
> echo 'Name of the MultiImage: '
> read name
> mkimage -n $name -A ppc -O linux -T multi -C gzip -d
> vmlinux.gz:ramdisk.gz $name
> echo 'Well, we are kinda done'
> ----------------------------------------------------------------------
> -------------------------------
>
> I configured the Kernel to have 1 ramdisk with the size of 50M ,
> however I tried various combinations
> of 16 Ramdisk and 4M and 8M .. nothing seems to work for me today ...
>
> Happy for any tips to point me in the right direction.
>
> Cheers // Matias
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://ozlabs.org/pipermail/linuxppc-embedded/attachments/20070321/57ed9cef/attachment.htm
More information about the Linuxppc-embedded
mailing list