]> code.ossystems Code Review - openembedded-core.git/commitdiff
scripts/poky-qemu: Add support for the nokia800-maemo machine
authorRichard Purdie <richard@openedhand.com>
Wed, 23 Apr 2008 09:58:18 +0000 (09:58 +0000)
committerRichard Purdie <richard@openedhand.com>
Wed, 23 Apr 2008 09:58:18 +0000 (09:58 +0000)
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@4315 311d38ba-8fff-0310-9ca6-ca027cbcb966

scripts/poky-qemu
scripts/poky-qemu-internal

index 96f4f6f9b75ae1a4ce67939ad8961eeeb991eea4..227df6ffe9bac73a84cd80f4f0d80044269a6bb9 100755 (executable)
@@ -48,6 +48,9 @@ else
     if [ "$MACHINE" = "nokia800" ]; then
         TYPE="jffs2"
     fi
+    if [ "$MACHINE" = "nokia800-maemo" ]; then
+        TYPE="jffs2"
+    fi
     HDIMAGE=$2
 fi
 
index 4ddb116130193e7755988bf4004cb8905402f5fa..ac2772d3f93c2a7f53b23b693d94c6113c3374c9 100755 (executable)
@@ -51,6 +51,7 @@ case "$MACHINE" in
        "akita") ;;
        "spitz") ;;
        "nokia800") ;;
+       "nokia800-maemo") ;;
        *)
                echo "Error: Unsupported machine type $MACHINE"
                return
@@ -136,18 +137,6 @@ if [ "$MACHINE" = "nokia800" ]; then
     if [ "$TYPE" = "jffs2" ]; then
         HDIMAGE=`readlink -f $HDIMAGE`
         if [ ! -e "$HDIMAGE.qemuflash" ]; then
-            #if [ ! -e "$HDIMAGE.initfs" ]; then
-            #    echo "Error, $HDIMAGE.initfs must exist!"
-            #    return
-            #fi
-            #if [ ! -e "$HDIMAGE.config" ]; then
-            #    echo "Error, $HDIMAGE.config must exist!"
-            #    return
-            #fi
-            #echo "'Flashing' config partition, please wait..."
-            #poky-nokia800-flashutil $HDIMAGE.config $HDIMAGE.qemuflash config
-            #echo "'Flashing' initfs, please wait..."
-            #poky-nokia800-flashutil $HDIMAGE.initfs $HDIMAGE.qemuflash initfs
             echo "'Flashing' rootfs, please wait..."
             poky-nokia800-flashutil $HDIMAGE $HDIMAGE.qemuflash 
         fi
@@ -156,6 +145,31 @@ if [ "$MACHINE" = "nokia800" ]; then
     fi
 fi
 
+if [ "$MACHINE" = "nokia800-maemo" ]; then
+    QEMU=qemu-system-arm
+    if [ "$TYPE" = "jffs2" ]; then
+        HDIMAGE=`readlink -f $HDIMAGE`
+        if [ ! -e "$HDIMAGE.qemuflash" ]; then
+            if [ ! -e "$HDIMAGE.initfs" ]; then
+                echo "Error, $HDIMAGE.initfs must exist!"
+                return
+            fi
+            if [ ! -e "$HDIMAGE.config" ]; then
+                echo "Error, $HDIMAGE.config must exist!"
+                echo "To generate it, take an n800 and cat /dev/mtdblock1 > $HDIMAGE.config"
+                return
+            fi
+            echo "'Flashing' config partition, please wait..."
+            poky-nokia800-flashutil $HDIMAGE.config $HDIMAGE.qemuflash config
+            echo "'Flashing' initfs, please wait..."
+            poky-nokia800-flashutil $HDIMAGE.initfs $HDIMAGE.qemuflash initfs
+            echo "'Flashing' rootfs, please wait..."
+            poky-nokia800-flashutil $HDIMAGE $HDIMAGE.qemuflash 
+        fi
+       KERNCMDLINE=""
+        QEMUOPTIONS="$QEMU_NETWORK_CMD -M n800 -mtdblock $HDIMAGE.qemuflash -serial vc -m 130 -serial vc -serial vc -serial vc"
+    fi
+fi
 
 if [ "x$QEMUOPTIONS" = "x" ]; then
     echo "Error: Unable to support this combination of options"