Permalink
Browse files

Memory Test and u-boot updates

u-boot changed over to use our official machine id
memory tests now
	- use our kernel, x-loader and u-boot
	- do nand in user space
	- press the user key to write test failure info to user sd
Start of new PIM test routines
  • Loading branch information...
1 parent 5868867 commit 56ca272896812e5f37c18f07d148fc85af91b076 mgrundy committed Dec 10, 2010
View
@@ -0,0 +1,73 @@
+echo ============================================================
+echo Running initial setup
+echo ============================================================
+echo running mmcinit
+mmc init
+
+echo setting nand ecc hw
+nandecc hw
+
+echo erasing 0x0 0x80000
+nand erase 0x0 0x80000
+
+echo reading x-loader (x-load.bin.ift)
+fatload mmc 0:1 0x82000000 x-load.bin.ift
+
+echo writing x-loader to nand
+nand write 0x82000000 0x0 0x80000
+
+echo setting nand ecc sw
+nandecc sw
+
+echo erasing 0x80000 0x160000
+nand erase 0x80000 0x160000
+
+echo reading u-boot (pu-boot.bin)
+fatload mmc 0:1 0x82000000 pu-boot.bin
+
+echo writing u-boot to nand
+nand write 0x82000000 0x80000 0x160000
+
+echo setting boot sequence and args
+setenv mmcargs 'setenv bootargs smsc95xx.mac=${ethaddr} console=${console} root=/dev/mmcblk0p1 rw rootwait rootdelay=1 kgdboc=${console} usbcore.autosuspend=-1'
+setenv mmcboot 'mmc init;ext2load mmc 0:1 0x80000000 /boot/uImage;run mmcargs;bootm 0x80000000'
+setenv bootargs 'console=ttyS2,115200n8 root=/dev/mmcblk0p1 rw rootwait rootdelay=1 kgdboc=ttyS2,115200n8 usbcore.autosuspend=-1 8250.nr_uarts=6 printk.time=1'
+setenv shutdown 'i2c mw 4b 46 41 1'
+setenv bootcmd 'run mmcboot; run confcmd; run shutdown'
+setenv confcmd 'mmc init; mw.b 0x81600000 0xff 0x100; fatload mmc 0:1 0x81600000 config.img; source 0x81600000;'
+setenv bootdelay '3'
+setenv console 'ttyS2,115200n8'
+setenv preboot ''
+setenv stderr 'serial'
+setenv stdin 'serial'
+setenv stdout 'serial'
+setenv loadaddr
+setenv usbtty
+setenv vram
+setenv dvimode
+setenv defaultdisplay
+setenv mmcroot
+setenv mmcrootfstype
+setenv nandroot
+setenv nandrootfstype
+setenv nandargs
+setenv loadbootscript
+setenv bootscript
+setenv loaduimage
+setenv nandboot
+setenv bootkernel
+setenv bootkernel_1
+setenv machid c10
+echo Saving Normal Configuration
+saveenv
+echo ============================================================
+echo Running initial setup
+echo ============================================================
+#echo running mmcinit
+#mmc init
+#setenv machid c10
+setenv bootargs 'console=ttyS2,115200n8 ramdisk_size=10240 root=/dev/ram0 rw rootwait rootdelay=1 kgdboc=ttyS2,115200n8 usbcore.autosuspend=-1 8250.nr_uarts=6 printk.time=1'
+fatload mmc 0:1 0x80000000 uImage
+fatload mmc 0:1 0x81600000 ramdisk.ui
+
+bootm 0x80000000 0x81600000
View
Binary file not shown.
View
Binary file not shown.
View
Binary file not shown.
View
@@ -1,33 +0,0 @@
-echo ============================================================
-echo Running the Ram and Nand tests
-echo ============================================================
-setenv red 'imw 4A EE 11 1'
-setenv grn 'imw 4A EE 22 1'
-setenv off 'imw 4A EE 00 1'
-run grn
-if diagnose memory nand; then
- if diag memory RAMtest; then
- echo loading test kernel
- fatload mmc 0:1 0x80000000 uImage
- echo loading initrd
- fatload mmc 0:1 0x81600000 ramdisk.gz
- # Now booting correctly with ramdisk and initrd:
- setenv bootargs 'console=ttyS2,115200n8 ramdisk_size=10240 mem=256M root=/dev/ram0 rw rootfstype=ext2 initrd=0x81600000,4M rw rootwait rootdelay=1 kgdboc=ttyS2,115200n8 usbcore.autosuspend=-1 8250.nr_uarts=6 printk.time=1'
-
- echo booting test kernel
- bootm 0x80000000
- # Ram Test Failed
- else
- while echo; do
- run off
- sleep 1
- run red
- sleep 1
- done
- fi
-#Nand test Failed
-else
- run off
- run red
-fi
-
View
Binary file not shown.
View
Binary file not shown.
View
Binary file not shown.
View
@@ -0,0 +1,11 @@
+echo ============================================================
+echo Running initial setup
+echo ============================================================
+echo running mmcinit
+mmc init
+setenv machid c10
+setenv bootargs 'console=ttyS2,115200n8 ramdisk_size=10240 root=/dev/ram0 rw rootwait rootdelay=1 kgdboc=ttyS2,115200n8 usbcore.autosuspend=-1 8250.nr_uarts=6 printk.time=1'
+fatload mmc 0:1 0x80000000 uImage
+fatload mmc 0:1 0x81600000 ramdisk.ui
+
+bootm 0x80000000 0x81600000
View
Binary file not shown.
View
Binary file not shown.
View
Binary file not shown.
View
Binary file not shown.
View
21 sdbuild
@@ -30,10 +30,18 @@ x-loader () {
}
mtest-build () {
- cp ./u-boot/u-boot.gold-bin $1/u-boot.bin
- cp ./uImage/uImage $1
- cp ./memtest/ramdisk.gz $1
- cp ./memtest/__setenv.img $1
+ cp ./u-boot/u-boot-force-env $1/u-boot.bin
+ cp ./memtest/uImage $1
+ cp ./memtest/ramdisk.ui $1
+ cp ./memtest/config.img $1
+ cp ./u-boot/pu-boot.bin $1
+}
+
+ptest-build () {
+ cp ./u-boot/u-boot-force-env $1/u-boot.bin
+ cp ./pimtest/uImage $1
+ cp ./pimtest/ramdisk.ui $1
+ cp ./pimtest/config.img $1
}
fcc-build () {
@@ -184,6 +192,9 @@ while [ $# -gt 0 ]; do
# -v Create verification test
elif [ "$1" == "-v" ]; then
buildtype=vtest
+ # -v Create verification test
+ elif [ "$1" == "-p" ]; then
+ buildtype=ptest
# Create a better informed user
elif [ "$1" == "--help" ]; then
help
@@ -221,6 +232,8 @@ if [ "$buildtype" == "vtest" ]; then
exit
fi
volid=TESTRIG${fixid}
+elif [ "$buildtype" == "ptest" ]; then
+ volid=PIMTEST
elif [ "$buildtype" == "mtest" ]; then
volid=MEMTEST
elif [ "$buildtype" == "flash" ]; then
View
Binary file not shown.
View
Binary file not shown.
View
Binary file not shown.

0 comments on commit 56ca272

Please sign in to comment.