summaryrefslogtreecommitdiff
path: root/packages/zaurus-updater/akita/updater.sh
diff options
context:
space:
mode:
authorMarcin Juszkiewicz <hrw@openembedded.org>2007-11-22 13:14:40 +0000
committerMarcin Juszkiewicz <hrw@openembedded.org>2007-11-22 13:14:40 +0000
commita4c96d20b0945e1bcab47041c919334ca49947b7 (patch)
treeb02b94a90cf25eacb2bbcfc781dc14e8213307cf /packages/zaurus-updater/akita/updater.sh
parentad1a7590b31c75651e20d8f8d74bd58f7ea2e542 (diff)
zaurus-updater: dropped spitz one as unified works on spitz (tested by Rolf Leggewie)
Diffstat (limited to 'packages/zaurus-updater/akita/updater.sh')
-rw-r--r--packages/zaurus-updater/akita/updater.sh84
1 files changed, 42 insertions, 42 deletions
diff --git a/packages/zaurus-updater/akita/updater.sh b/packages/zaurus-updater/akita/updater.sh
index 5399e5254e..ad2c27b012 100644
--- a/packages/zaurus-updater/akita/updater.sh
+++ b/packages/zaurus-updater/akita/updater.sh
@@ -181,53 +181,53 @@ do
/sbin/verchg -v $VTMPNAME $TMPHEAD $MODULEID $MODULESIZE > /dev/null 2>&1
/sbin/verchg -m $MTMPNAME $TMPHEAD $MODULEID $MODULESIZE > /dev/null 2>&1
- if [ "$MODEL" = "SL-C1000" ] && [ $TARGETTYPE = Kernel ]; then
- echo $TARGETFILE':'$DATASIZE'bytes'
- echo ' ' > /tmp/data
- /sbin/nandlogical $LOGOCAL_MTD WRITE 0x60100 16 /tmp/data > /dev/null 2>&1
- /sbin/nandlogical $LOGOCAL_MTD WRITE 0xe0000 $DATASIZE $TARGETFILE > /dev/null 2>&1
- /sbin/nandlogical $LOGOCAL_MTD WRITE 0x21bff0 16 /tmp/data > /dev/null 2>&1
- #loop
- else
- while [ $DATAPOS -lt $DATASIZE ]
- do
- #data create
- bcut -a $DATAPOS -s $ONESIZE -o $TMPDATA $TARGETFILE
- TMPSIZE=`wc -c $TMPDATA`
- TMPSIZE=`echo $TMPSIZE | cut -d' ' -f1`
- DATAPOS=`expr $DATAPOS + $TMPSIZE`
-
- #handle data file
- #echo 'ADDR='$ADDR
- #echo 'SIZE='$TMPSIZE
- #echo 'TMPDATA='$TMPDATA
- if [ $ISLOGICAL = 0 ]
- then
- next_addr=`/sbin/nandcp -a $ADDR $TMPDATA $TARGET_MTD 2>/dev/null | fgrep "mtd address" | cut -d- -f2 | cut -d\( -f1`
- if [ "$next_addr" = "" ]; then
- echo "ERROR:flash write"
- rm $TMPDATA > /dev/null 2>&1
- RESULT=3
- break;
+ if [ "$MODEL" = "SL-C1000" ] && [ $TARGETTYPE = Kernel ]; then
+ echo $TARGETFILE':'$DATASIZE'bytes'
+ echo ' ' > /tmp/data
+ /sbin/nandlogical $LOGOCAL_MTD WRITE 0x60100 16 /tmp/data > /dev/null 2>&1
+ /sbin/nandlogical $LOGOCAL_MTD WRITE 0xe0000 $DATASIZE $TARGETFILE > /dev/null 2>&1
+ /sbin/nandlogical $LOGOCAL_MTD WRITE 0x21bff0 16 /tmp/data > /dev/null 2>&1
+ #loop
+ else
+ while [ $DATAPOS -lt $DATASIZE ]
+ do
+ #data create
+ bcut -a $DATAPOS -s $ONESIZE -o $TMPDATA $TARGETFILE
+ TMPSIZE=`wc -c $TMPDATA`
+ TMPSIZE=`echo $TMPSIZE | cut -d' ' -f1`
+ DATAPOS=`expr $DATAPOS + $TMPSIZE`
+
+ #handle data file
+ #echo 'ADDR='$ADDR
+ #echo 'SIZE='$TMPSIZE
+ #echo 'TMPDATA='$TMPDATA
+ if [ $ISLOGICAL = 0 ]
+ then
+ next_addr=`/sbin/nandcp -a $ADDR $TMPDATA $TARGET_MTD 2>/dev/null | fgrep "mtd address" | cut -d- -f2 | cut -d\( -f1`
+ if [ "$next_addr" = "" ]; then
+ echo "ERROR:flash write"
+ rm $TMPDATA > /dev/null 2>&1
+ RESULT=3
+ break;
+ fi
+ ADDR=$next_addr
+ else
+ /sbin/nandlogical $LOGOCAL_MTD WRITE $ADDR $DATASIZE $TMPDATA > /dev/null 2>&1
+ ADDR=`expr $ADDR + $TMPSIZE`
fi
- ADDR=$next_addr
- else
- /sbin/nandlogical $LOGOCAL_MTD WRITE $ADDR $DATASIZE $TMPDATA > /dev/null 2>&1
- ADDR=`expr $ADDR + $TMPSIZE`
- fi
- rm $TMPDATA > /dev/null 2>&1
+ rm $TMPDATA > /dev/null 2>&1
- #progress
- SPNUM=0
- while [ $SPNUM -lt $PROGSTEP ]
- do
- echo -n '.'
- SPNUM=`expr $SPNUM + 1`
+ #progress
+ SPNUM=0
+ while [ $SPNUM -lt $PROGSTEP ]
+ do
+ echo -n '.'
+ SPNUM=`expr $SPNUM + 1`
+ done
done
- done
- fi
+ fi
echo ''