Quantcast
Channel: Linux Device Hacking - uBoot
Viewing all 900 articles
Browse latest View live

Pogoplug E02 Bad Block (5 replies)

$
0
0
My Pogoplug E02 have Bad Block. I followed instrution from this post http://forum.doozan.com/read.php?3,5728,5748#msg-5748 and got it to work/boot off a USB drive. However, I cannot get back into the stock OS. I can ping the ip but cannot ssh in. Also the mac address show on the router is incorrect. I did set the mac address in the environment. The mac address is correct when booted into ALARM. I mounted mtd2 and verified rcS "/etc/init.d/hbmgr.sh start" is not commented out. I would like to able to boot into orignal pogoplug if possible.

Appreciate any guidance :-)


Here is what i did

## Unknown uBoot detected on mtd0: 150f323cc589d1535d6e06c2038d0aa7
##
## The installer could not detect the version of your current uBoot
## This may happen if you have installed a different uBoot on
## /dev/mtd0 or if you have bad blocks on /dev/mtd0
##
## If you have bad blocks on mtd0, you should not try to install uBoot.
##
## If you have installed a diffirent uBoot on mtd0, and understand the
## risks, you can re-run the installer with the --no-uboot-check parameter
##
## Installation cancelled.

Pogoplug:/tmp$ /usr/sbin/flash_erase /dev/mtd0 0 5
Erase Total 5 Units
Performing Flash Erase of length 131072 at offset 0x40000
MTD Erase failure: Input/output error

Pogoplug:/tmp$ /usr/sbin/nandwrite /dev/mtd0 uboot.mtd0.kwb
Writing data to block 0 at offset 0x0
Writing data to block 1 at offset 0x20000
Writing data to block 2 at offset 0x40000
Bad block at 40000, 1 block(s) from 40000 will be skipped
Writing data to block 3 at offset 0x60000
Writing data to block 4 at offset 0x80000

Pogoplug:/tmp$ /usr/sbin/nanddump -nof /tmp/uBoot1.dump -l 0x40000 /dev/mtd0
Block size 131072, page size 2048, OOB size 64
Dumping data starting at 0x00000000 and ending at 0x00040000...

Pogoplug:/tmp$ /usr/sbin/nanddump -nof /tmp/uBoot2.dump -l 0x40000 -s 0x60000 /dev/mtd0
Block size 131072, page size 2048, OOB size 64
Dumping data starting at 0x00060000 and ending at 0x000a0000...

Pogoplug:/tmp$ cat uBoot1.dump uBoot2.dump > uBoot.dump

Pogoplug:/tmp$ diff -s uboot.mtd0.kwb uBoot.dump
Files uboot.mtd0.kwb and uBoot.dump are identical



# flash the uboot environment

wget -O /tmp/uboot.environment http://jeff.doozan.com/debian/uboot/files/environment/uboot.environment

Pogoplug:/tmp$ /usr/sbin/flash_erase /dev/mtd0 0xc0000 1
Erase Total 1 Units
Performing Flash Erase of length 131072 at offset 0xc0000 done
Pogoplug:/tmp$ /usr/sbin/nandwrite  -s 786432 /dev/mtd0 /tmp/uboot.environment
Writing data to block 6 at offset 0xc0000

Pogoplug:/tmp$ /usr/sbin/fw_printenv
/usr/sbin/fw_setenv ethaddr 00:25:31:xx:xx:xx




-Boot 2011.12 (Feb 20 2012 - 21:21:59)
Pogoplug E02
arm-none-linux-gnueabi-gcc (Sourcery G++ Lite 2009q3-67) 4.4.1
GNU ld (Sourcery G++ Lite 2009q3-67) 2.19.51.20090709
Hit any key to stop autoboot:     0 
(Re)start USB...
USB:   Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 4 USB Device(s) found
       scanning bus for storage devices... 0 Storage Device(s) found
** Block device usb 0 not supported

** Invalid boot device **
Creating 1 MTD partitions on "nand0":
0x000002500000-0x000008000000 : "mtd=3"
UBI: attaching mtd1 to ubi0
UBI: physical eraseblock size:   131072 bytes (128 KiB)
UBI: logical eraseblock size:    129024 bytes
UBI: smallest flash I/O unit:    2048
UBI: sub-page size:              512
UBI: VID header offset:          512 (aligned 512)
UBI: data offset:                2048
UBI: attached mtd1 to ubi0
UBI: MTD device name:            "mtd=3"
UBI: MTD device size:            91 MiB
UBI: number of good PEBs:        728
UBI: number of bad PEBs:         0
UBI: max. allowed volumes:       128
UBI: wear-leveling threshold:    4096
UBI: number of internal volumes: 1
UBI: number of user volumes:     0
UBI: available PEBs:             717
UBI: total number of reserved PEBs: 11
UBI: number of PEBs reserved for bad PEB handling: 7
UBI: max/mean erase counter: 1/1
UBIFS error (pid 0): ubifs_get_sb: cannot open "ubi:rootfs", error -19
Error reading superblock on volume 'ubi:rootfs'!
** Block device usb 0 not supported
** Block device usb 1 not supported
** Block device usb 2 not supported
** Block device usb 3 not supported
** Block device usb 0 not supported
** Block device usb 0 not supported
Wrong Image Format for bootm command
ERROR: can't get kernel image!
stopping USB..
### JFFS2 loading 'uboot-original-mtd0.kwb' to 0x800000
Scanning JFFS2 FS: ........ done.
### JFFS2 load complete: 524288 bytes loaded to 0x800000
## Starting application at 0x00800200 ...


U-Boot loading compressed uImage (7 replies)

$
0
0
What compression does u-boot 2013.11 support for uImage if any?, i tried lzma2 and it didn't boot.

Not booting off of a WD 3TB drive (3 replies)

$
0
0
I've spent the last few hours, nights, days trying to figure out why my pogoplug will not boot off of a 4gb ext3 partition on a 3 TB wd element drive. I finally gave up and loaded everything on a flash drive and voila.See the netconsole output below. Without the drive attached it boots the pogoplug stuff and I can ssh to it but when booting as below it hangs. Anyone have any ideas? What am I missing?

U-Boot 2011.12 (Feb 20 2012 - 21:21:59)
Pogoplug E02
arm-none-linux-gnueabi-gcc (Sourcery G++ Lite 2009q3-67) 4.4.1
GNU ld (Sourcery G++ Lite 2009q3-67) 2.19.51.20090709
Hit any key to stop autoboot: 10 ??? 9 ??? 8 ??? 7 ??? 6 ??? 5 ??? 4 ??? 3 ??? 2 ??? 1 ??? 0
(Re)start USB...
USB: Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 3 USB Device(s) found
scanning bus for storage devices... EHCI timed out on TD - token=0x10008d80
EHCI timed out on TD - token=0x128d80
1 Storage Device(s) found
Loading file "/rescueme" from usb device 0:1 (usbda1)

no ssh sccess to pogoplug (E02) (1 reply)

$
0
0
I am not able to get SSH access on pogoplug E02. I set password on my.pogoplug.com for SSH, but on local IP i am not able to access the SSH using the password.

I keep getting the error as "Permission denied, please try again."

Below is log for command - " ssh -v root@192.168.15.140"

[root@ashish ashish]# ssh -v root@192.168.15.140
OpenSSH_4.3p2, OpenSSL 0.9.8e-fips-rhel5 01 Jul 2008
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Applying options for *
debug1: Connecting to 192.168.15.140 [192.168.15.140] port 22.
debug1: Connection established.
debug1: permanently_set_uid: 0/0
debug1: identity file /root/.ssh/identity type -1
debug1: identity file /root/.ssh/id_rsa type -1
debug1: identity file /root/.ssh/id_dsa type -1
debug1: loaded 3 keys
debug1: Remote protocol version 2.0, remote software version dropbear_2012.55
debug1: no match: dropbear_2012.55
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_4.3
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: sending SSH2_MSG_KEXDH_INIT
debug1: expecting SSH2_MSG_KEXDH_REPLY
debug1: Host '192.168.15.140' is known and matches the RSA host key.
debug1: Found key in /root/.ssh/known_hosts:3
debug1: ssh_rsa_verify: signature correct
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,password
debug1: Next authentication method: publickey
debug1: Trying private key: /root/.ssh/identity
debug1: Trying private key: /root/.ssh/id_rsa
debug1: Trying private key: /root/.ssh/id_dsa
debug1: Next authentication method: password
root@192.168.15.140's password:
debug1: Authentications that can continue: publickey,password
Permission denied, please try again.
root@192.168.15.140's password:
debug1: Authentications that can continue: publickey,password
Permission denied, please try again.
root@192.168.15.140's password:
debug1: Authentications that can continue: publickey,password
debug1: No more authentication methods to try.
Permission denied (publickey,password).

Boot from usb partition with name rootfs (3 replies)

$
0
0
I have a wheezy installation on an external hdd which I want to use on a pink pogoplug. I labeled the rootpartition rootfs, and now would like to boot from this partition even if the other usb hdd are attached. I don't think they contain bootable structures / files.

I followed

http://forum.doozan.com/read.php?3,12

but I get the following:

U-Boot 2011.12 (Feb 20 2012 - 21:21:59)
Pogoplug E02
arm-none-linux-gnueabi-gcc (Sourcery G++ Lite 2009q3-67) 4.4.1
GNU ld (Sourcery G++ Lite 2009q3-67) 2.19.51.20090709
Hit any key to stop autoboot:  0
(Re)start USB...
USB:   Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 5 USB Device(s) found
       scanning bus for storage devices... EHCI timed out on TD - token=0x800d8d80
EHCI timed out on TD - token=0x80008d80
3 Storage Device(s) found
Loading file "/rescueme" from usb device 0:1 (usbda1)
** File not found /rescueme
reading /rescueme.txt

** Unable to read "/rescueme.txt" from usb 0:1 **

and there it stops (or do I have to wait a few minutes?).

In contrast, when I switch off the power of the other external hdd (usb connected, power not), I get

-Boot 2011.12 (Feb 20 2012 - 21:21:59)
Pogoplug E02
arm-none-linux-gnueabi-gcc (Sourcery G++ Lite 2009q3-67) 4.4.1
GNU ld (Sourcery G++ Lite 2009q3-67) 2.19.51.20090709
Hit any key to stop autoboot:  0
(Re)start USB...
USB:   Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 3 USB Device(s) found
       scanning bus for storage devices... 1 Storage Device(s) found
Loading file "/rescueme" from usb device 0:1 (usbda1)
** File not found /rescueme
reading /rescueme.txt

** Unable to read "/rescueme.txt" from usb 0:1 **
Creating 1 MTD partitions on "nand0":
0x000002500000-0x000008000000 : "mtd=3"
UBI: attaching mtd1 to ubi0
UBI: physical eraseblock size:   131072 bytes (128 KiB)
UBI: logical eraseblock size:    129024 bytes
UBI: smallest flash I/O unit:    2048
UBI: sub-page size:              512
UBI: VID header offset:          512 (aligned 512)
UBI: data offset:                2048
UBI error: ubi_read_volume_table: the layout volume was not found
UBI error: ubi_init: cannot attach mtd1
UBI error: ubi_init: UBI error: cannot initialize UBI, error -22
UBI init error 22
(Re)start USB...
USB:   Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 3 USB Device(s) found
       scanning bus for storage devices... 1 Storage Device(s) found
Loading file "/boot/uImage" from usb device 0:1 (usbda1)
1608496 bytes read
Loading file "/boot/uImage" from usb device 0:1 (usbda1)
1608496 bytes read
Loading file "/boot/uInitrd" from usb device 0:1 (usbda1)
7087801 bytes read
## Booting kernel from Legacy Image at 00800000 ...
   Image Name:   kernel 3.2.0-4-kirkwood
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    1608432 Bytes = 1.5 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
   Image Name:   ramdisk 3.2.0-4-kirkwood
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    7087737 Bytes = 6.8 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...

and it works.

my fw_env looks as follow:

root@debian:~# fw_printenv
ethact=egiga0
bootdelay=3
baudrate=115200
mainlineLinux=yes
console=ttyS0,115200
led_init=green blinking
led_exit=green off
led_error=orange blinking
mtdparts=mtdparts=orion_nand:1M(u-boot),4M(uImage),32M(rootfs),-(data)
mtdids=nand0=orion_nand
partition=nand0,2
stdin=serial
stdout=serial
stderr=serial
rescue_set_bootargs=setenv bootargs console=$console ubi.mtd=2 root=ubi0:rootfs ro rootfstype=ubifs $mtdparts $rescue_custom_params
rescue_bootcmd=if test $rescue_installed -eq 1; then run rescue_set_bootargs; nand read.e 0x800000 0x100000 0x400000; bootm 0x800000; else run pogo_bootcmd; fi
pogo_bootcmd=if fsload uboot-original-mtd0.kwb; then go 0x800200; fi
force_rescue=0
force_rescue_bootcmd=if test $force_rescue -eq 1 || ext2load usb 0:1 0x1700000 /rescueme 1 || fatload usb 0:1 0x1700000 /rescueme.txt 1; then run rescue_bootcmd; fi
ubifs_mtd=3
ubifs_set_bootargs=setenv bootargs console=$console ubi.mtd=$ubifs_mtd root=ubi0:rootfs rootfstype=ubifs $mtdparts $ubifs_custom_params
ubifs_bootcmd=run ubifs_set_bootargs; if ubi part data && ubifsmount rootfs && ubifsload 0x800000 /boot/uImage && ubifsload 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; fi
usb_scan=usb_scan_done=0;for scan in $usb_scan_list; do run usb_scan_$scan; if test $usb_scan_done -eq 0 && ext2load usb $usb 0x800000 /boot/uImage 1; then usb_scan_done=1; echo "Found bootable drive on usb $usb"; setenv usb_device $usb; setenv usb_root /dev/$dev; fi; done
usb_scan_list=1 2 3 4
usb_scan_1=usb=0:1 dev=sda1
usb_scan_2=usb=1:1 dev=sdb1
usb_scan_3=usb=2:1 dev=sdc1
usb_scan_4=usb=3:1 dev=sdd1
usb_device=0:1
usb_root=/dev/sda1
usb_rootfstype=ext2
usb_rootdelay=10
usb_set_bootargs=setenv bootargs console=$console root=$usb_root rootdelay=$usb_rootdelay rootfstype=$usb_rootfstype $mtdparts $usb_custom_params
usb_bootcmd=run usb_init; run usb_set_bootargs; run usb_boot
usb_boot=mw 0x800000 0 1; ext2load usb $usb_device 0x800000 /boot/uImage; if ext2load usb $usb_device 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; else bootm 0x800000; fi
bootcmd=usb start; run force_rescue_bootcmd; run ubifs_bootcmd; run usb_bootcmd; usb stop; run rescue_bootcmd; run pogo_bootcmd; reset
ethaddr=00:25:31:00:49:4B
rescue_installed=1
arcNumber=3542
serverip=192.168.0.40
if_netconsole=ping $serverip
start_netconsole=setenv ncip $serverip; setenv bootdelay 10; setenv stdin nc; setenv stdout nc; setenv stderr nc; version;
preboot=run if_netconsole start_netconsole
ipaddr=192.168.0.102
usb_init=usb start; if ext2load usb 0:1 0x800000 /boot/uImage; then setenv usb_device 0:1; setenv usb_root /dev/sda1; elif ext2load usb 1:1 0x800000 /boot/uImage; then setenv usb_device 1:1; setenv usb_root /dev/sdb1; elif ext2load usb 2:1 0x800000 /boot/uImage; then setenv usb_device 2:1; setenv usb_root /dev/sdc1; elif ext2load usb 3:1 0x800000 /boot/uImage; then setenv usb_device 3:1;setenv usb_root /dev/sdd1;fi;
root@debian:~#


Is there any way to tell uBoot to boot from rootfs? I already changed the fstab to use LABEL=rootfs for / but I assume that comes in later?

Rainer

Dockstar: Should I update uBoot? (4 replies)

$
0
0
I have a 2.6 kernel and Debian Squeeze running fine on a USB 2GB stick. I want to install a fresh Wheezy on a different USB stick and switch back and forth while I get the new stick configured. Squeeze is my production home server and will be until I have Wheezy configured properly.

Do I need to upgrade my uBoot to install Wheezy?

Should I upgrade it? (what benefits does an upgrade uBoot provide?)

How do I find out what version of uBoot I have installed?

If I do upgrade it will I still be able to boot into my Wheezy install?

Jeff's uBoot, installed, can't mount /dev/mtdblock3? (no replies)

$
0
0
I just need a little help or clarification. I've got a Pogo-E02 that I've installed Jeff's uBoot successfully. Although I'm currently not boot and running an OS off a USB drive, I'd like to play with the pogoplug services and try to mount the /dev/mtdblock3 partition to install optware.

I have done this successfully, but only with a stock un-altered Pogo-E02, following Aaron Randalls notes at this page.
http://aaronrandall.com/blog/customising-your-pogoplug/

I understand (I think) that Jeff's uBoot script does a backup of the original uBoot somewhere but I really don't care or need the original uBoot image.

Does anyone know if Jeff's script does something to the mtdblock3 partition or why I can't seem to use it have the uBoot install? Would I just need to completely revert back to stock? I don't see why I couldn't keep Jeff's uBoot image and just scrape the original one.

When I try to mount /dev/mtdblock3..

Pogoplug:/$ mount /dev/mtdblock3 /opt
mount: mounting /dev/mtdblock3 on /opt failed: Invalid argument

Any help or advice would be appreciated.

Here is some current stats of the Pogo-E02

Pogoplug:/usr/sbin$ cat /proc/partitions
major minor #blocks name

31 0 1024 mtdblock0
31 1 4096 mtdblock1
31 2 32768 mtdblock2
31 3 93184 mtdblock3

Pogoplug:/usr/sbin$ cat /proc/mtd
dev: size erasesize name
mtd0: 00100000 00020000 "u-boot"
mtd1: 00400000 00020000 "uImage"
mtd2: 02000000 00020000 "root"
mtd3: 05b00000 00020000 "data"

Pogoplug:/usr/sbin$ ./fw_printenv mtdparts
mtdparts=mtdparts=orion_nand:1M(u-boot),4M(uImage),32M(rootfs),-(data)

Simple way to boot SD card on PogoPlug Mobile? (1 reply)

$
0
0
Hi,

After going around in loops many times trying to find u-boot images I can test via tftp (since picocom doesn't ever download anything), I'd like to ask for help. Neither of these will work on a PogoPlug Mobile using tftp:

uboot.nandpogoV4-MMC-mtdparts-noSATA.kwb
uboot.uartpogoMobile-MMC-mtdparts-NoUSB.kwb

I'm not going to write anything to flash until I see something that works, particularly since the most common thread about SD booting says, in bold, " Don't use on a Pogoplug Mobile".

ALARM from Arch doesn't boot from SD, either, so that was a dead end.

Does anyone know where I can get a u-boot image that definitely works with the PogoPlug Mobile and can boot off of SD?

Thanks,
John Klos

Cold Boot works but reboot does not - Try this (no replies)

$
0
0
I want to promote this potential solution from RomanG:

Quote

So I again reduced bootdelay variable from 10 sec to 2 sec and now it boots consistently from either cold reboot or warm reboot.

from this post:
http://forum.doozan.com/read.php?3,14158,14359#msg-14359

The solution was for HDD, and I think it should solve most if not all HDD booting timed out problem. But it might work for SD card booting too. So please try if you have problem with either HDD or SD card reboot (when cold boot works).

Goflex Home Semi Bricked (no replies)

$
0
0
Hello

I´m new in the forum i´m from portugal so sorry for my poor english

I have a goflex home 1tb and i try to put archlinux on but someting wrong, dont boot the green light blink and dont boot, i make a rescue usb but only boot if i remove the sata drive, so how to make new partitions to install debian or archlinux or to put originall

Tanks for the help

Kirkwood U-boot - Getting all supported Kirkwoods on-board (3 replies)

$
0
0
@bohdi @davygravy

Gents,

Shall we work on getting all known and linux supported Kirkwood based boards into one tree, especially those that we don't have an existing consolidated codebase? Get these working, and into a consolidated tree, so that we can get them all to modern versions of u-boot that will support GPT, FDT, et al without us all having to hunt around?

Examples of troublesome:
- V4 SATA vs SD being seperate
- NSA320, 325, 310 (anyone have a 310?)

Conditionally boot with PogoPlug original U-boot? (no replies)

$
0
0
Hi,

I've figured out that if I write my NetBSD kernel into the 8 meg to 16 meg section of a PogoPlug Mobile's flash (the area referred to as "failsafe"), the PogoPlug's GNU/Linux can still boot just fine. So I'm wondering if anyone has recommendations for how I might selectively boot based on some external thing - absence or presence of a USB device, perhaps, but using just the original U-boot. I'd only want to select between:
bootcmd 'nand read.e 0x800000 0x800000 0x800000; bootm 0x800000'
and
bootcmd 'run boot_nand'
Since NetBSD doesn't have a working NAND driver yet, this would make it possible to boot into GNU/Linux for the purpose of writing NAND without needing a serial cable.

Suggestions?

reverse brick? (no replies)

$
0
0
Hi,

I have a pogo E02 that I can only boot with a USB stick. If I remove the usb stick and wifi dongle and plug in the ethernet cable the LED never lights up. I cannot boot into the rescue system.

I changed the arcNumber to 3542 to make the LED blink orange when there is USB stick activity. I have since changed it back to 2998 but I still can't boot into the rescue system. The LED still blinks orange when there is disk activity.

I hope someone can tell me what to do. Thanks.

#uname -a

Linux pogoplug 3.12.6-2-ARCH #1 PREEMPT Tue Dec 24 21:09:18 MST 2013 armv5tel GNU/Linux

#fw_printenv

ethact=egiga0
bootdelay=3
baudrate=115200
mainlineLinux=yes
console=ttyS0,115200
led_init=green blinking
led_exit=green off
led_error=orange blinking
mtdparts=mtdparts=orion_nand:1M(u-boot),4M(uImage),32M(rootfs),-(data)
mtdids=nand0=orion_nand
partition=nand0,2
stdin=serial
stdout=serial
stderr=serial
rescue_set_bootargs=setenv bootargs console=$console ubi.mtd=2 root=ubi0:rootfs ro rootfstype=ubifs $mtdparts $rescue_custom_params
rescue_bootcmd=if test $rescue_installed -eq 1; then run rescue_set_bootargs; nand read.e 0x800000 0x100000 0x400000; bootm 0x800000; else run pogo_bootcmd; fi
pogo_bootcmd=if fsload uboot-original-mtd0.kwb; then go 0x800200; fi
force_rescue=0
force_rescue_bootcmd=if test $force_rescue -eq 1 || ext2load usb 0:1 0x1700000 /rescueme 1 || fatload usb 0:1 0x1700000 /rescueme.txt 1; then run rescue_bootcmd; fi
ubifs_mtd=3
ubifs_set_bootargs=setenv bootargs console=$console ubi.mtd=$ubifs_mtd root=ubi0:rootfs rootfstype=ubifs $mtdparts $ubifs_custom_params
ubifs_bootcmd=run ubifs_set_bootargs; if ubi part data && ubifsmount rootfs && ubifsload 0x800000 /boot/uImage && ubifsload 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; fi
usb_scan=usb_scan_done=0;for scan in $usb_scan_list; do run usb_scan_$scan; if test $usb_scan_done -eq 0 && ext2load usb $usb 0x800000 /boot/uImage 1; then usb_scan_done=1; echo "Found bootable drive on usb $usb"; setenv usb_device $usb; setenv usb_root /dev/$dev; fi; done
usb_scan_list=1 2 3 4
usb_scan_1=usb=0:1 dev=sda1
usb_scan_2=usb=1:1 dev=sdb1
usb_scan_3=usb=2:1 dev=sdc1
usb_scan_4=usb=3:1 dev=sdd1
usb_init=run usb_scan
usb_device=0:1
usb_root=/dev/sda1
usb_rootdelay=10
usb_set_bootargs=setenv bootargs console=$console root=$usb_root rootdelay=$usb_rootdelay rootfstype=$usb_rootfstype $mtdparts $usb_custom_params
usb_bootcmd=run usb_init; run usb_set_bootargs; run usb_boot
usb_boot=mw 0x800000 0 1; ext2load usb $usb_device 0x800000 /boot/uImage; if ext2load usb $usb_device 0x1100000 /boot/uInitrd; then bootm 0x800000 0x1100000; else bootm 0x800000; fi
bootcmd=usb start; run force_rescue_bootcmd; run ubifs_bootcmd; run usb_bootcmd; usb stop; run rescue_bootcmd; run pogo_bootcmd; reset
ethaddr=00:25:31:00:1E:11
usb_rootfstype=ext3
machid=dd6
rescue_installed=1
arcNumber=2998

PogoV4-A3-01 troubles (2 replies)

$
0
0
I need some ideas. It's very late. I'm probably missing something trivial and its driving me crazy.

I got this Pogo just a little while ago so it's my newest toy. Over the weekend I got it booting Debian off USB using the Arch ALARM uboot. I had ran a revert to play around with using my.pogoplug.com to backup over the Internet. For giggles. I was curious about throughput. Today I fix the bootcmd and now it refuses to boot off USB. I connect back up via serial and the error I get is that the ALARM uboot isn't recognizing the ext3 partition. The stick boots fine in a Dockstar and in an NSA320. The error is below along with usb part output.

** Invalid partition type "X�c" (expect "U-Boot")

ALARM>> usb part
print_part of 0

Partition Map for USB device 0  --   Partition Type: DOS

Partition     Start Sector     Num Sectors     Type
    1                    0         2023424      f8

print_part of 1
## Unknown partition table

print_part of 2
## Unknown partition table

print_part of 3
## Unknown partition table

print_part of 4
## Unknown partition table

I restore a near virgin backup copy of bohdi's kirkwood 3.12.0 rootfs to it. (Near virgin. I added a few utils to it before making the image backup -- mtdutils, usbutils, pciutils, sudo, I forget what else but a few other things.) It won't boot and I get the same error that the partition is unrecognized. I again validate it boots in the Dockstar. I get Debian running using tftp to load uImage and uInitrd and bootm with the rootfs on the stick with no problem. (root=LABEL=ROOTFS)

I restore the image to a different stick. I make sure it boots it on the Dockstar. It won't boot on the PogoV4. Same error. I again tftp boot using the stick as rootfs and its fine.

Finally I recall that I used a really old 128M stick for the revert. I find it. It's FAT. I place both uImage and uInitrd on it and manually fatload them. There's no problem with that. I swap sticks with the original and bootm and it comes up.

I can't figure out why uboot doesn't like the partition on the other sticks. I only run Linux at home. My backup was from a stick that I formatted fresh with mkfs and then untar'ed the rootfs onto. It's really late now. I can't think anymore. I'm going to totally reformat a stick tomorrow and untar the rootfs onto it instead of dd restoring the image backup.

If anyone has any ideas, please shout them out. This is driving me crazy. The box is running but its annoying. I've been trying to get a single stick image that'll work on all my devices. This should be it (excluding my Stora) if I could get it to boot!

Conditional boot with DLINK DNS325 original U-boot (2 replies)

$
0
0
Hello.

I am trying to do conditional booting (USB -> HDD -> NAND) using *only* original U-boot.
I tried this:

setenv uImageAddr 0xa00000;
setenv uInitramfsAddr '0xf00000'
# from USB
setenv usb_root 'LABEL=rootusb'
setenv usb_opts 'usb-storage.delay_use=0 rootdelay=10'
setenv usb_load_uImage 'ext2load usb 0:1 ${uImageAddr} /boot/uImage'
setenv usb_load_uInitramfs 'ext2load usb 0:1 ${uInitramfsAddr} /boot/uInitramfs'
setenv usb_setbootargs 'setenv bootargs console=ttyS0,115200 root=${usb_root} ${usb_opts} ${mtdparts} ${bootargs_end} ${bootopts}'
setenv boot_from_usb 'usb reset; run usb_load_uImage; run usb_load_uInitramfs; run usb_setbootargs; bootm ${uImageAddr} ${uInitramfsAddr}'
# from HDD
setenv hdd_root 'LABEL=roothdd'
setenv hdd_opts ''
setenv hdd_load_uImage 'ext2load ide 0:1 ${uImageAddr} /uImage'
setenv hdd_load_uInitramfs 'ext2load ide 0:1 ${uInitramfsAddr} /uInitramfs'
setenv hdd_setbootargs 'setenv bootargs console=ttyS0,115200 root=${hdd_root} ${hdd_opts} ${mtdparts} ${bootargs_end} ${bootopts}'
setenv boot_from_hdd 'ide reset; run hdd_load_uImage; run hdd_load_uInitramfs; run hdd_setbootargs; bootm ${uImageAddr} ${uInitramfsAddr}'
# NAND
setenv nand_setbootargs 'setenv bootargs root=/dev/ram console=ttyS0,115200 :::DB88FXX81:egiga0:none'
setenv boot_from_nand 'run nand_setbootargs; nand read.e 0xa00000 0x100000 0x300000;nand read.e 0xf00000 0x600000 0x300000;bootm 0xa00000 0xf00000'

# BOOTCMD
setenv bootcmd 'run boot_from_usb; run boot_from_hdd; run boot_from_nand'

Single commands (boot_from_usb or boot_from_hdd or boot_from_nand) just work.
Problem is that if it cannot find the 1st device (eg USB), it does not go to the following, instead it is trying some sort of "builtin" bootcmd, which I cannot understand where is coming from.


This is serial output, without 1st device (usb) attached
it gives bad partition (expected), but then it reads from nand ... why? shouldn't it try to execute next command?

Hit any key to stop autoboot:  0
(Re)start USB...
USB:   scanning bus for devices... 1 USB Device(s) found
       scanning bus for storage devices... 0 Storage Device(s) found
** Bad partition 1 **
** Bad partition 1 **
## Booting image at 00a00000 ...
Bad Magic Number

NAND read: device 0 offset 0x7100800, size 0x500000
load addr ....  =a00000

 5242880 bytes read: OK
## Booting image at 00a00000 ...
   Image Name:   Linux-2.6.22.18
   Created:      2011-05-25   7:23:15 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2214860 Bytes =  2.1 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
OK
## Loading Ramdisk Image at 00d00000 ...
   Image Name:   Ramdisk
   Created:      2011-07-11   5:47:12 UTC
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    1566183 Bytes =  1.5 MB
   Load Address: 00e00000
   Entry Point:  00e00000
   Verifying Checksum ... OK


Any help is appreciated ^_^
Thx!

bad crc and ro serial console unbrick? (5 replies)

$
0
0
I tried to restore uboot to facotry and ended up with bad checksum. I messed up the pad by the rx pin so i cant write from serial console. here is what happens on boot:
U-Boot 1.1.4  Cloud Engines 1.1.2 (3.4.22) SATA PHYADDR=0

U-Boot code: 00600000 -> 0067FFF0  BSS: -> 00691750

Soc: 88F6281 A1 (DDR2)
CPU running @ 1200Mhz L2 running @ 400Mhz
SysClock = 400Mhz , TClock = 200Mhz

DRAM CAS Latency = 5 tRP = 5 tRAS = 18 tRCD=6
DRAM CS[0] base 0x00000000   size 128MB
DRAM Total size 128MB  16bit width
Addresses 8M - 0M are saved for the U-Boot usage.
Mem malloc Initialization (8M - 7M): Done
NAND:256 MB
Flash:  0 kB

CPU : Marvell Feroceon (Rev 1)
CLOUD ENGINES BOARD (GUESSED): DISCOVERY:0.1

Streaming disabled
Write allocate disabled


USB 0: host mode
PEX 0: interface detected no Link.
Net:   egiga0 [PRIME]
Hit any key to stop autoboot:  0

NAND read: device 0 offset 0x100000, size 0x300000

Reading data from 0x3ff800 -- 100% complete.
 3145728 bytes read: OK
## Booting image at 00800000 ...
   Image Name:   Linux-2.6.32.18-dockstar
   Created:      2011-02-17   8:10:10 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    3236180 Bytes =  3.1 MB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... Bad Data CRC
CE>>

Is there any way to unbrick?

Is there a newer u-boot for Netgear Stora (RD-88F6281A LE) (no replies)

$
0
0
Dear all,

hello everyone. I'm wondering if there is any possibility for upgrading a u-boot in my old Netgear Stora?
Right now it's running on U-Boot 1.1.4 (Sep 4 2009 - 09:36:11) Marvell version: 3.4.14 with original kernel.

I want to install Debian Wheezy Grip on a USB and if I'm correct aa need to have a newer u-boot.

A've already tried few u-boots and no luck.
Some of them hangs my stora

Firstly I tftp kbw file to my nand and for testing it...
Marvell>> go 0x800200
## Starting application at 0x00800200 ...


some of them just restart my Stora
Marvell>> go 0x800000
## Starting application at 0x00800000 ...
data abort
pc : [<00800008>]	   lr : [<0062f700>]
sp : 005ff0d4  ip : 005fec64	 fp : 005ff0f0
r10: 00000000  r9 : 00000000	 r8 : 005fffcc
r7 : 005ff513  r6 : 00000002	 r5 : 005ffd0c  r4 : 00800000
r3 : 00000000  r2 : f1012000	 r1 : 005ffd0c  r0 : 00000001
Flags: nZCv  IRQs off  FIQs off  Mode SVC_32
Resetting CPU ...

Kind regards.

Boot hangs at "booting the kernel." (6 replies)

$
0
0
I have a GoFlex Home that I have been trying to get working with Debian. I have the "kirkwood-debian_rootfs.img" (from davygravy: http://dl.dropbox.com/u/1015928/Kirkwood/rootfs_images/NSA320quickstart.tar.gz) on a USB flash drive. It Loads /boot/uImage and /boot/uInitrd the says its booting kernel and loading init Ramdisk but then hangs after that. Here is the bootlog:
U-Boot 2010.09 (Feb 16 2011 - 18:44:23)
UBIT v0.6 by Jeff Doozan and Peter Carmichael

SoC: Kirkwood 88F6281_A0
DRAM: 128 MiB
NAND: 256 MiB
In: serial
Out: serial
Err: serial
Net: egiga0
88E1116 Initialized on egiga0
Creating 1 MTD partitions on "nand0":
0x000000700000-0x000010000000 : "mtd=2"
UBI: attaching mtd1 to ubi0
UBI: physical eraseblock size: 131072 bytes (128 KiB)
UBI: logical eraseblock size: 129024 bytes
UBI: smallest flash I/O unit: 2048
UBI: sub-page size: 512
UBI: VID header offset: 512 (aligned 512)
UBI: data offset: 2048
UBI error: validate_ec_hdr: bad VID header offset 2048, expected 512
UBI error: validate_ec_hdr: bad EC header
UBI error: ubi_io_read_ec_hdr: validation failed for PEB 0
UBI error: ubi_init: cannot attach mtd1
UBI error: ubi_init: UBI error: cannot initialize UBI, error -22
UBI init error -22
UBIFS error (pid 0): ubifs_get_sb: cannot open "ubi:silent", error -19
Error reading superblock on volume 'ubi:silent'!
UBIFS not mounted, use ubifs mount to mount volume first!
Using egiga0 device
ping failed; host 10.10.10.5 is not alive
(Re)start USB...
USB: Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 2 USB Device(s) found
scanning bus for storage devices... 1 Storage Device(s) found
Hit any key to stop autoboot: 0
UBIFS error (pid 0): ubifs_get_sb: cannot open "ubi:fast", error -19
Error reading superblock on volume 'ubi:fast'!
UBIFS not mounted, use ubifs mount to mount volume first!
Loading file "/boot/uImage" from usb device 0:1 (usbda1)
2279256 bytes read
Loading file "/uInitrd" from usb device 0:1 (usbda1)
** File not found /uInitrd
Loading file "/boot/uInitrd" from usb device 0:1 (usbda1)
7004538 bytes read
## Booting kernel from Legacy Image at 00680000 ...
Image Name: Linux-3.3.2
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 2279192 Bytes = 2.2 MiB
Load Address: 00008000
Entry Point: 00008000
Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
Image Name: initramfs-3.3.2-kirkwood-dg
Image Type: ARM Linux RAMDisk Image (gzip compressed)
Data Size: 7004474 Bytes = 6.7 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum ... OK
Loading Kernel Image ... OK
OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.


And this is my printenv:
bootcmd=run fast_boot; run usb_boot; run hd_boot; run ubi_boot
bootdelay=3
baudrate=115200
ide_start=ide reset
ubi_start=ubi part root
usb_start=usb start
nc_test=ping $ncip
nc_start=setenv stdin nc; setenv stdout nc; setenv stderr nc; version
silent_boot=run silent_rd ubi_args ubi_fallback
fast_boot=run fast_rd ubi_args ubi_fallback
usb_boot=for scan in 0 1 2 3; do run usb_args_$scan ext2_kern ext2_boot; run ext2_rd ubi_fallback; run fat_kern fat_boot; run fat_rd ubi_fallback;done
usb_args_0=boot_dev='usb 0:1'; dev_args='root=/dev/sda1 rootdelay=10'
usb_args_1=boot_dev='usb 1:1'; dev_args='root=/dev/sdb1 rootdelay=10'
usb_args_2=boot_dev='usb 2:1'; dev_args='root=/dev/sdc1 rootdelay=10'
usb_args_3=boot_dev='usb 3:1'; dev_args='root=/dev/sdd1 rootdelay=10'
hd_boot=run ide_start; for scan in 0 1; do run hd_args_$scan ext2_kern ext2_boot; run ext2_rd ubi_fallback; run fat_kern fat_boot; run fat_rd ubi_fallback; done
hd_args_0=boot_dev='ide 0:1'; dev_args='root=/dev/sda1'
hd_args_1=boot_dev='ide 1:1'; dev_args='root=/dev/sdb1'
ubi_boot=run ubi_rd ubi_args ubi_fallback
ubi_args=dev_args='ubi.mtd=root'
rescue=dev_args='ubi.mtd=root rootfstype=preboot'; boot_dev='usb 0:1'; run ext2_kern ext2_auto boot_rd; boot_dev='ide 0:1'; run ide_start ext2_kern ext2_auto boot_rd; run silent_rd ubi_fallback; run fast_rd ubi_fallback; run ubi_rd ubi_fallback
chain=nand read.e 0x800000 0x480000 0x80000; go 0x800200
ethact=egiga0
console=ttyS0,115200
mtdids=nand0=orion_nand
set_bootargs=setenv bootargs console=$console $mtdparts $dev_args $rd_args netconsole=@$ipaddr/eth0,@$ncipk/
ext2_kern=ext2load $boot_dev $addr_kern /boot/uImage
ext2_auto=ext2load $boot_dev $addr_rd /boot/uInitrd
ext2_rd=ext2load $boot_dev $addr_rd /uInitrd
ext2_boot=run ext2_rd boot_rd; run ext2_auto boot_auto; run boot_kern
fat_kern=fatload $boot_dev $addr_kern /boot/uImage
fat_rd=fatload $boot_dev $addr_rd /uInitrd
fat_boot=run fat_rd boot_rd
ubi_kern=ubifsmount boot; ubifsload $addr_kern /boot/uImage
ubi_rd=ubifsmount ramdisk; ubifsload $addr_rd /uInitrd
ubi_fallback=run ubi_kern boot_rd
silent_rd=ubifsmount silent; ubifsload $addr_rd /uInitrd
fast_rd=ubifsmount fast; ubifsload $addr_rd /uInitrd
boot_kern=run set_bootargs; bootm $addr_kern
boot_rd=run set_bootargs; bootm $addr_kern $addr_rd
boot_auto=rd_args='rootfstype=auto'; run boot_rd
addr_kern=0x680000
addr_rd=0x1100000
ncip=10.10.10.5
ncipk=10.10.10.4
led_init=green blinking
led_exit=green off
led_error=orange blinking
ethaddr=xx:xx:xx:xx:xx:xx
preboot=run ubi_start silent_boot; run nc_test nc_start; run usb_start
mtdparts=mtdparts=orion_nand:1M(u-boot),6M(uImage),-(root)
gatewayip=192.168.1.1
ipaddr=192.168.1.254
arch_number=0x00000831
usb_rootfstype=ext2
serverip=192.168.1.150
stdin=serial
stdout=serial
stderr=serial
partition=nand0,0
mtddevnum=0
mtddevname=u-boot

Environment size: 2825/131068 bytes

Any thoughts on what needs to be done to complete the boot?

Thanks in advance for any help!

Yet Another ARM! (no replies)

$
0
0
Greetings,

Love the forum, I have two plugs (E02 and v4). Seems like I wound up here on more than one occasion during their setup. Well as fate would have it, I got my ultimate wish, sorta... A third arm! All joking aside. I have a Netgear Stora to add to my arsenal. Having been lucky enough to pull off two plugs, one would think this should be a piece of cake. Well, I have a strange feeling something could get a little borked with this one. With the plugs I was able to boot from my.pogoplug.com, then SSH in, kill pogo, and then it was Off to the Races! Not sure where to start with this one. I have not done much research, but my intent is to boot from USB, install Arch, setup MDADM and use the two SATA drives as a RAID 1. If I pull that off, I would then like to install Webmin, Samba, MiniDLNA, Shairport and my.pogoplug.com. Any feedback or advice would be appreciated. This looks like a fun project, if all the pieces go together.

Cheers!
Robert

New U-Boot option for Pogoplug Series 4/V4 (1 reply)

$
0
0
After a couple of years of prevarication, I have finally got around to producing a U-Boot for the Pogo V4 that I'm vaguely happy with.

It is similar to the ALARM version, in that it is based on the stock 1.1.4 sources, but it goes a little further.

Background and Philosophy

What I want is a U-Boot that will reliably load Debian and support the SATA interface in that environment. This mandated using the Pogoplug "open source" U-Boot, and lead me to the conclusion that (for my prejudices and preconceptions) that I need to load the kernel and the initramfs from the on-board flash.

If, for whatever reason, the load fails, I don't want the U-Boot side to do anything special. In those cases, I reckon I want to be involved with fixing the problem (i.e. no automatic loading of any other images). And, because only one of my two devices has the serial port header attached, that means I need netconsole to poke around if things go wrong.

This U-Boot does that: it supports netconsole, USB and IDE/SATA, as well as (obviously) pulling the images from NAND.

Using It
There is a compressed tar file at Box.net / uboot.pogoV4-USB-SATA-Net.tzf. Download that, and untar it (tar xvzf ...) and look at the installer.

Because this is based on the stock U-Boot, it requires blparam to set/get environment variables, not fw_printenv. Basically, the installer tends to assume it's running on the standard Pogoplug OS, but will work in other environments as long as it can find a blparam, a flash_erase and a nandwrite.

Netconsole
The Netconsole setup is similar to that of later U-Boot versions, in that you enable it by setting the variable ncip to the IP address of the console machine, and change the variables stdin, stderr, and stdout.

HOWEVER, the network interface takes a little too long to come up, so the usual trick of putting a ping test in the preboot doesn't work: the interface isn't up, the ping fails, and nothing works. Fortunately, the usb start commands take long enough to execute that the network is usable when it finishes, so the following set of variables works like a charm:
consoleip=198.19.81.98
do_netconsole=run if_netconsole start_netconsole
if_netconsole=ping $consoleip
start_netconsole=setenv ncip $consoleip; setenv bootdelay 10; setenv stdin nc; setenv stdout nc; setenv stderr nc; version
preboot=usb start; run do_netconsole

(Note that I don't use the serverip variable for this address, because I want to have a separate console from a tftp server; the address I show -- 198.19.81.98 -- is technically reserved for network testing, so should never be used in production. Since I only want the console occasionally, I just add the address to whatever convenient Linux box that may be to hand, using the ifconfig eth0:0 198.19.81.98 syntax).

Building It

At this link Box.net / uboot-pogo-114.patch there is a patch file that should patch against the Pogoplug source at Pogoplug / Opensource / pogomv-u-boot.tar.bz2.

I built it on a Linux Mint (= Ubuntu, = Debian) PC host, following the instructions Here to get an emdebian cross-compiler.

Once compiled, you will have a uboot.bin (which you can tftp and run with the go command) and a couple of files that are suitable for booting (from flash and serial). These are named someting like u-boot-pogomv_200rd_nand.bin and u-boot-pogomv_200rd_uart.bin. The ..._nand.bin file is padded to a multiple of 128KB by:
dd if=u-boot-pogomv_200rd_nand.bin bs=128k conv=sync of=u-boot-pogoV4-USB-SATA-Net.kwb
Viewing all 900 articles
Browse latest View live