[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

question -- does this look right to you?



Hi Martin,

My SheevaPlug is showing something I think is strange, and I wondered if you knew what might make it do this:

When running Debian (Sid, in this case) and I do “fw_printenv” it gives an error message about a bad CRC and using default environment…

> rbthomas@sheeva:~$ sudo fw_printenv
> Warning: Bad CRC, using default environment
> bootargs=
> bootcmd=
> bootdelay=2
> baudrate=115200
> stdin=serial,cros-ec-keyb
> stdout=serial,lcd
> stderr=serial,lcd
> ethaddr=00:00:11:22:33:44
> eth1addr=00:00:11:22:33:45
> eth3addr=00:00:11:22:33:46
> eth5addr=00:00:11:22:33:47
> ipaddr=1.2.3.4
> host_boot=if host dev ${devnum}; then setenv devtype host; run scan_dev_for_boot_part; fi
> boot_prefixes=/ /boot/
> boot_scripts=boot.scr.uimg boot.scr
> boot_script_dhcp=boot.scr.uimg
> boot_targets=host1 host0 
> boot_extlinux=sysboot ${devtype} ${devnum}:${distro_bootpart} any ${scriptaddr} ${prefix}extlinux/extlinux.conf
> scan_dev_for_extlinux=if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}extlinux/extlinux.conf; then echo Found ${prefix}extlinux/extlinux.conf; run boot_extlinux; echo SCRIPT FAILED: continuing...; fi
> boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} ${prefix}${script}; source ${scriptaddr}
> scan_dev_for_scripts=for script in ${boot_scripts}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${script}; then echo Found U-Boot script ${prefix}${script}; run boot_a_script; echo SCRIPT FAILED: continuing...; fi; done
> scan_dev_for_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; for prefix in ${boot_prefixes}; do run scan_dev_for_extlinux; run scan_dev_for_scripts; done
> scan_dev_for_boot_part=part list ${devtype} ${devnum} -bootable devplist; env exists devplist || setenv devplist 1; for distro_bootpart in ${devplist}; do if fstype ${devtype} ${devnum}:${distro_bootpart} bootfstype; then run scan_dev_for_boot; fi; done
> bootcmd_host1=setenv devnum 1; run host_boot
> bootcmd_host0=setenv devnum 0; run host_boot
> distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
> bootm_size=0x10000000
> kernel_addr_r=0x1000000
> fdt_addr_r=0xc00000
> ramdisk_addr_r=0x2000000
> scriptaddr=0x1000
> pxefile_addr_r=0x2000
> rbthomas@sheeva:~$ 

This is definitely *not* the environment I see when running U-boot…

> Marvell>> printenv
> baudrate=115200
> bootargs=console=ttyS0,115200
> bootargs_console=console=ttyS0,115200
> bootcmd=setenv bootargs ${bootargs_console}; run bootcmd_mmc; bootm 0x00800000 0x01100000
> bootcmd_mmc=ext2load mmc 0:1 0x00800000 /uImage; ext2load mmc 0:1 0x01100000 /uInitrd
> bootcmd_new=setenv bootargs ${bootargs_console}; run bootcmd_mmc; bootm 0x00800000 0x01100000
> bootcmd_old=setenv bootargs ${bootargs_console}; run bootcmd_usb; bootm 0x00800000 0x01100000
> bootcmd_usb=usb start; ext2load usb 0:1 0x00800000 /uImage; ext2load usb 0:1 0x01100000 /uInitrd
> bootdelay=3
> ethact=egiga0
> ethaddr=f0:ad:4e:00:30:77
> stderr=serial
> stdin=serial
> stdout=serial
> x_bootargs=console=ttyS0,115200 mtdparts=mtdparts=orion_nand:512K(uboot),512K(env),1M(script),6M(kernel),12M(ramdisk),4M(spare),-(rootfs)x_bootcmd_kernel=nand read 0x6400000 0x100000 0x300000
> x_bootargs_root=root=/dev/mtdblock3 rw rootfstype=jffs2
> x_bootcmd_usb=usb start
> 
> Environment size: 945/131068 bytes
> Marvell>> 

Information that may bear on the question:

the /etc/fw_env.config is taken from /usr/share/doc/u-boot-tools/examples/sheevaplug.config

> rbthomas@sheeva:~$ cat /etc/fw_env.config 
> # Configuration file for fw_(printenv/saveenv) utility.
> # Up to two entries are valid, in this case the redundant
> # environment sector is assumed present.
> #
> # XXX this configuration might miss a fifth parameter for the "Number of
> # sectors"
> 
> # MTD device name   Device offset   Env. size   Flash sector size
> /dev/mtd0           0x60000         0x20000     0x20000
> rbthomas@sheeva:~$ 

When, in u-boot, I do a “saveenv” command I get…

> Marvell>> saveenv
> Saving Environment to NAND...
> Erasing NAND...
> ^MErasing at 0x60000 -- 100% complete.
> Writing to NAND... OK
> Marvell>>

So I presume the “Device offset” in /etc/fw_env.config is correct.  Or is there something I don’t know about going on?

The running u-boot version is…

> Marvell>> version
> 
> U-Boot 2014.10+dfsg1-5 (Apr 07 2015 - 21:57:04)
> Marvell-Sheevaplug
> gcc (Debian 4.9.2-10) 4.9.2
> GNU ld (GNU Binutils for Debian) 2.25
> Marvell>> 

The version of u-boot-tools installed is  2015.10+dfsg1-4

Thanks!

Rick



Reply to: