diff mbox

[U-Boot,v2] intern: Add copy scripts and target specific helpers

Message ID 1422965980-3545-24-git-send-email-oe5hpm@oevsv.at
State Superseded
Delegated to: Tom Rini
Headers show

Commit Message

Hannes Schmelzer Feb. 3, 2015, 12:19 p.m. UTC
cpy

Comments

Hannes Schmelzer Feb. 3, 2015, 12:37 p.m. UTC | #1
Hi all,

please ignore this "internal" patch.
This is was an accident.

best regards,
Hannes
Heiko Schocher Feb. 3, 2015, 12:47 p.m. UTC | #2
Hello Hannes,

Am 03.02.2015 13:37, schrieb Hannes Petermaier:
> Hi all,
>
> please ignore this "internal" patch.
> This is was an accident.

Maybe it is worth to look into patman, see:
u-boot:/tools/patman/README ?

bye,
Heiko
>
> best regards,
> Hannes
>
> _______________________________________________
> U-Boot mailing list
> U-Boot@lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot
>
Hannes Schmelzer Feb. 4, 2015, 7:10 a.m. UTC | #3
Heiko,

what a great tool :-)
This makes the whole thing much easier and will produce (hopefully) less 
noise from me :-)

But i 've a further questions:

1st)
patman prints out some errors, looks like for me that something is wrong 
with the first line of my commit message - but no idea what.

"
Traceback (most recent call last):
  File "tools/patman/patman", line 149, in <module>
    options.add_maintainers)
  File "/home/petermaierh/work/u-boot/tools/patman/series.py", line 227, 
in MakeCcFile
    raise_on_error=raise_on_error)
  File "/home/petermaierh/work/u-boot/tools/patman/gitutil.py", line 321, 
in BuildEmailList
    raw += LookupEmail(item, alias, raise_on_error=raise_on_error)
  File "/home/petermaierh/work/u-boot/tools/patman/gitutil.py", line 490, 
in LookupEmail
    raise ValueError, msg
ValueError: Alias 'drivers/video/am335x-fb' not found
"
maybe you've or somebody else has an idea how to fix this ?

2nd)
How to achieve "not breaking threading" ? How the right "in-reply-to" is 
added to git-send-email ? from where comes this information.
I've seen at my last V2 that i don't have reached the goal.

many thanks and best regards,
Hannes

Heiko Schocher <hs@denx.de> schrieb am 03.02.2015 13:47:02:

> From: Heiko Schocher <hs@denx.de>
> To: Hannes Petermaier <Hannes.Petermaier@br-automation.com>
> Cc: Hannes Petermaier <oe5hpm@oevsv.at>, u-boot@lists.denx.de, U-Boot 
<u-boot-
> bounces@lists.denx.de>
> Date: 03.02.2015 13:47
> Subject: Re: [U-Boot] [PATCH v2] intern: Add copy scripts and target 
specific helpers
> 
> Hello Hannes,
> 
> Am 03.02.2015 13:37, schrieb Hannes Petermaier:
> > Hi all,
> >
> > please ignore this "internal" patch.
> > This is was an accident.
> 
> Maybe it is worth to look into patman, see:
> u-boot:/tools/patman/README ?
> 
> bye,
> Heiko
> >
> > best regards,
> > Hannes
> >
> > _______________________________________________
> > U-Boot mailing list
> > U-Boot@lists.denx.de
> > http://lists.denx.de/mailman/listinfo/u-boot
> >
> 
> -- 
> DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
> HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Heiko Schocher Feb. 4, 2015, 7:33 a.m. UTC | #4
Hello Hannes,

Am 04.02.2015 08:10, schrieb Hannes Petermaier:
> Heiko,
>
> what a great tool :-)

Yep, definitely... Thanks to Simon!

> This makes the whole thing much easier and will produce (hopefully) less
> noise from me :-)

;-)

> But i 've a further questions:
>
> 1st)
> patman prints out some errors, looks like for me that something is wrong
> with the first line of my commit message - but no idea what.
>
> "
> Traceback (most recent call last):
>    File "tools/patman/patman", line 149, in <module>
>      options.add_maintainers)
>    File "/home/petermaierh/work/u-boot/tools/patman/series.py", line 227,
> in MakeCcFile
>      raise_on_error=raise_on_error)
>    File "/home/petermaierh/work/u-boot/tools/patman/gitutil.py", line 321,
> in BuildEmailList
>      raw += LookupEmail(item, alias, raise_on_error=raise_on_error)
>    File "/home/petermaierh/work/u-boot/tools/patman/gitutil.py", line 490,
> in LookupEmail
>      raise ValueError, msg
> ValueError: Alias 'drivers/video/am335x-fb' not found
> "
> maybe you've or somebody else has an idea how to fix this ?

I am not really a python coder ... and I do not see such an error,
if I create a commit with changes in "drivers/video/am335x-fb.c"
I got not this error ... my first thought it was the
"drivers/video/am335x-fb:" in your subject line... but I used the same
subject for a test commit ... please try another subject line:
"drivers, video, am335x: ..." ?

How does your patman config file looks like?

> 2nd)
> How to achieve "not breaking threading" ? How the right "in-reply-to" is
> added to git-send-email ? from where comes this information.
> I've seen at my last V2 that i don't have reached the goal.

Hmm... I am not sure, maybe this is a ToDo? Simon? Could you
help here?

Thanks!

bye,
Heiko
>
> many thanks and best regards,
> Hannes
>
> Heiko Schocher <hs@denx.de> schrieb am 03.02.2015 13:47:02:
>
>> From: Heiko Schocher <hs@denx.de>
>> To: Hannes Petermaier <Hannes.Petermaier@br-automation.com>
>> Cc: Hannes Petermaier <oe5hpm@oevsv.at>, u-boot@lists.denx.de, U-Boot
> <u-boot-
>> bounces@lists.denx.de>
>> Date: 03.02.2015 13:47
>> Subject: Re: [U-Boot] [PATCH v2] intern: Add copy scripts and target
> specific helpers
>>
>> Hello Hannes,
>>
>> Am 03.02.2015 13:37, schrieb Hannes Petermaier:
>>> Hi all,
>>>
>>> please ignore this "internal" patch.
>>> This is was an accident.
>>
>> Maybe it is worth to look into patman, see:
>> u-boot:/tools/patman/README ?
>>
>> bye,
>> Heiko
>>>
>>> best regards,
>>> Hannes
>>>
>>> _______________________________________________
>>> U-Boot mailing list
>>> U-Boot@lists.denx.de
>>> http://lists.denx.de/mailman/listinfo/u-boot
>>>
>>
>> --
>> DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
>> HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
>
>
>
Hannes Schmelzer Feb. 4, 2015, 7:50 a.m. UTC | #5
On 2015-02-04 08:33, Heiko Schocher wrote:
> Hello Hannes,
>>
>> 1st)
>> patman prints out some errors, looks like for me that something is wrong
>> with the first line of my commit message - but no idea what.
>>
>> "
>> Traceback (most recent call last):
>>    File "tools/patman/patman", line 149, in <module>
>>      options.add_maintainers)
>>    File "/home/petermaierh/work/u-boot/tools/patman/series.py", line 
>> 227,
>> in MakeCcFile
>>      raise_on_error=raise_on_error)
>>    File "/home/petermaierh/work/u-boot/tools/patman/gitutil.py", line 
>> 321,
>> in BuildEmailList
>>      raw += LookupEmail(item, alias, raise_on_error=raise_on_error)
>>    File "/home/petermaierh/work/u-boot/tools/patman/gitutil.py", line 
>> 490,
>> in LookupEmail
>>      raise ValueError, msg
>> ValueError: Alias 'drivers/video/am335x-fb' not found
>> "
>> maybe you've or somebody else has an idea how to fix this ?
>
> I am not really a python coder ... and I do not see such an error,
> if I create a commit with changes in "drivers/video/am335x-fb.c"
> I got not this error ... my first thought it was the
> "drivers/video/am335x-fb:" in your subject line... but I used the same
> subject for a test commit ... please try another subject line:
> "drivers, video, am335x: ..." ?
>
> How does your patman config file looks like?
I've tried to add
--no-tags             Don't process subject tags as aliaes
to cmdline, this works ... so it is definitely a problem with the 
subject line of the commit.

>
>> 2nd)
>> How to achieve "not breaking threading" ? How the right "in-reply-to" is
>> added to git-send-email ? from where comes this information.
>> I've seen at my last V2 that i don't have reached the goal.
>
> Hmm... I am not sure, maybe this is a ToDo? Simon? Could you
> help here?
An idea is to use the
-r IN_REPLY_TO
in the commandline, the value may be taken from patchwork, here is a 
messageid like
<1422966166-3973-21-git-send-email-oe5hpm@oevsv.at> displayed.

>
> Thanks!
>
> bye,
> Heiko
best regards,
Hannes

>>
>> many thanks and best regards,
>> Hannes
>>
>> Heiko Schocher <hs@denx.de> schrieb am 03.02.2015 13:47:02:
>>
>>> From: Heiko Schocher <hs@denx.de>
>>> To: Hannes Petermaier <Hannes.Petermaier@br-automation.com>
>>> Cc: Hannes Petermaier <oe5hpm@oevsv.at>, u-boot@lists.denx.de, U-Boot
>> <u-boot-
>>> bounces@lists.denx.de>
>>> Date: 03.02.2015 13:47
>>> Subject: Re: [U-Boot] [PATCH v2] intern: Add copy scripts and target
>> specific helpers
>>>
>>> Hello Hannes,
>>>
>>> Am 03.02.2015 13:37, schrieb Hannes Petermaier:
>>>> Hi all,
>>>>
>>>> please ignore this "internal" patch.
>>>> This is was an accident.
>>>
>>> Maybe it is worth to look into patman, see:
>>> u-boot:/tools/patman/README ?
>>>
>>> bye,
>>> Heiko
>>>>
>>>> best regards,
>>>> Hannes
>>>>
>>>> _______________________________________________
>>>> U-Boot mailing list
>>>> U-Boot@lists.denx.de
>>>> http://lists.denx.de/mailman/listinfo/u-boot
>>>>
>>>
>>> -- 
>>> DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
>>> HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
>>
>>
>>
>
diff mbox

Patch

===
copies relevant files to TFTP server and packs them into a ZIP which can be
checked in for series production in SAP.

bur/scripts
===========
target specific helper scripts

Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at>

---
Changes for V2: None
---
 bur-scripts/.gitignore                |    3 ++
 bur-scripts/kwb/addUSBfiles.sh        |    5 +++
 bur-scripts/kwb/dispScripts.sh        |    4 ++
 bur-scripts/kwb/setdisp_43kwb         |   32 +++++++++++++
 bur-scripts/kwb/updateUBOOTusb        |    7 +++
 bur-scripts/kwb/updateUBOOTusb.sh     |    2 +
 bur-scripts/netscript                 |    4 ++
 bur-scripts/netscript.sh              |    5 +++
 bur-scripts/netscript.txt             |    6 +++
 bur-scripts/tseries/addUSBfiles.sh    |    5 +++
 bur-scripts/tseries/updateUBOOTusb    |    4 ++
 bur-scripts/tseries/updateUBOOTusb.sh |    2 +
 cpy                                   |   79 +++++++++++++++++++++++++++++++++
 13 files changed, 158 insertions(+)
 create mode 100644 bur-scripts/.gitignore
 create mode 100755 bur-scripts/kwb/addUSBfiles.sh
 create mode 100755 bur-scripts/kwb/dispScripts.sh
 create mode 100644 bur-scripts/kwb/setdisp_43kwb
 create mode 100644 bur-scripts/kwb/updateUBOOTusb
 create mode 100755 bur-scripts/kwb/updateUBOOTusb.sh
 create mode 100644 bur-scripts/netscript
 create mode 100755 bur-scripts/netscript.sh
 create mode 100644 bur-scripts/netscript.txt
 create mode 100755 bur-scripts/tseries/addUSBfiles.sh
 create mode 100644 bur-scripts/tseries/updateUBOOTusb
 create mode 100755 bur-scripts/tseries/updateUBOOTusb.sh
 create mode 100755 cpy

diff --git a/bur-scripts/.gitignore b/bur-scripts/.gitignore
new file mode 100644
index 0000000..ca70038
--- /dev/null
+++ b/bur-scripts/.gitignore
@@ -0,0 +1,3 @@ 
+addon/*
+*.img
+
diff --git a/bur-scripts/kwb/addUSBfiles.sh b/bur-scripts/kwb/addUSBfiles.sh
new file mode 100755
index 0000000..7555420
--- /dev/null
+++ b/bur-scripts/kwb/addUSBfiles.sh
@@ -0,0 +1,5 @@ 
+#!/bin/sh
+echo "copy MLO -> bur/scripts/addon/kwb/MLO.update"
+cp ../../MLO ../addon/kwb/MLO.update
+echo "copy u-boot.img -> bur/scripts/addon/kwb/u-boot.img"
+cp ../../u-boot.img ../addon/kwb/u-boot.img.update
diff --git a/bur-scripts/kwb/dispScripts.sh b/bur-scripts/kwb/dispScripts.sh
new file mode 100755
index 0000000..55cc1d4
--- /dev/null
+++ b/bur-scripts/kwb/dispScripts.sh
@@ -0,0 +1,4 @@ 
+#!/bin/sh
+mkimage -A ARM -T script -C none -d setdisp_43kwb setdisp_43kwb.img
+cp setdisp*.img /tftpboot/tseries
+
diff --git a/bur-scripts/kwb/setdisp_43kwb b/bur-scripts/kwb/setdisp_43kwb
new file mode 100644
index 0000000..210f0a8
--- /dev/null
+++ b/bur-scripts/kwb/setdisp_43kwb
@@ -0,0 +1,32 @@ 
+setenv ds1_hactive 480
+setenv ds1_vactive 272
+setenv ds1_bpp 32
+setenv ds1_hfp 8
+setenv ds1_hbp 43
+setenv ds1_hsw 2
+setenv ds1_vfp 4
+setenv ds1_vbp 2
+setenv ds1_vsw 10
+setenv ds1_pxlclkdiv 21
+setenv ds1_pol 0x2300000
+setenv ds1_pupdelay 10
+setenv ds1_tondelay 10
+setenv ds1_pwr 0x00000045
+setenv ds1_bright_drv 0
+setenv ds1_bright 50
+
+setenv br_blversion V2.0
+setenv br_orderno "not programmed"
+setenv br_serial "not programmed"
+setenv br_mac1
+setenv br_mac2
+
+setenv dnsip
+setenv gatewayip
+setenv ipaddr
+setenv serverip
+setenv fileaddr
+setenv filesize
+setenv bootfile
+
+saveenv
diff --git a/bur-scripts/kwb/updateUBOOTusb b/bur-scripts/kwb/updateUBOOTusb
new file mode 100644
index 0000000..9edaa26
--- /dev/null
+++ b/bur-scripts/kwb/updateUBOOTusb
@@ -0,0 +1,7 @@ 
+fatload usb 0 0x80100000 bur-ppt-ts30.dtb
+fatload usb 0 0x80200000 zImage
+fatload usb 0 0x80A00000 rootfs.cpio.uboot
+setenv bootargs "consoleblank=0 quiet lpj=1191936 panic=2 console=ttyO0,115200n8 burbootmode=pme"
+setenv bootcmd "env default -a; setenv bootcmd run netboot; saveenv; reset"
+saveenv
+bootz 0x80200000 0x80A00000 0x80100000;
diff --git a/bur-scripts/kwb/updateUBOOTusb.sh b/bur-scripts/kwb/updateUBOOTusb.sh
new file mode 100755
index 0000000..1fe3b64
--- /dev/null
+++ b/bur-scripts/kwb/updateUBOOTusb.sh
@@ -0,0 +1,2 @@ 
+#!/bin/sh
+mkimage -A ARM -T script -C none -n "ubootUpdateUSB" -d updateUBOOTusb updateUBOOTusb.img
diff --git a/bur-scripts/netscript b/bur-scripts/netscript
new file mode 100644
index 0000000..7bfa8dd
--- /dev/null
+++ b/bur-scripts/netscript
@@ -0,0 +1,4 @@ 
+tftp 0x80000000 setdisp_43kwb.img && source 0x80000000
+reset
+
+
diff --git a/bur-scripts/netscript.sh b/bur-scripts/netscript.sh
new file mode 100755
index 0000000..33cbc18
--- /dev/null
+++ b/bur-scripts/netscript.sh
@@ -0,0 +1,5 @@ 
+#!/bin/sh
+mkimage -A ARM -T script -C none -d setdisp_common -d netscript.txt netscript.img
+cp netscript.img /tftpboot/tseries/
+
+
diff --git a/bur-scripts/netscript.txt b/bur-scripts/netscript.txt
new file mode 100644
index 0000000..537f4e2
--- /dev/null
+++ b/bur-scripts/netscript.txt
@@ -0,0 +1,6 @@ 
+tftp 0x80100000 MLO && mmc write 0x80100000 100 100
+tftp 0x80100000 u-boot.img && mmc write 0x80100000 300 400
+setenv bootcmd "run netboot"
+saveenv
+reset
+
diff --git a/bur-scripts/tseries/addUSBfiles.sh b/bur-scripts/tseries/addUSBfiles.sh
new file mode 100755
index 0000000..ec13b7e
--- /dev/null
+++ b/bur-scripts/tseries/addUSBfiles.sh
@@ -0,0 +1,5 @@ 
+#!/bin/sh
+echo "copy MLO -> bur/scripts/addon/tseries/MLO.update"
+cp ../../MLO ../addon/tseries/MLO.update
+echo "copy u-boot.img -> bur/scripts/addon/tseries/u-boot.img"
+cp ../../u-boot.img ../addon/tseries/u-boot.img.update
diff --git a/bur-scripts/tseries/updateUBOOTusb b/bur-scripts/tseries/updateUBOOTusb
new file mode 100644
index 0000000..17364ce
--- /dev/null
+++ b/bur-scripts/tseries/updateUBOOTusb
@@ -0,0 +1,4 @@ 
+fatload usb 0 ${dtbaddr} bur-ppt-ts30.dtb
+fatload usb 0 ${loadaddr} zImage
+fatload usb 0 ${ramaddr} rootfs.cpio.uboot
+run mmcroot0; bootz ${loadaddr} ${ramaddr} ${dtbaddr};
diff --git a/bur-scripts/tseries/updateUBOOTusb.sh b/bur-scripts/tseries/updateUBOOTusb.sh
new file mode 100755
index 0000000..1fe3b64
--- /dev/null
+++ b/bur-scripts/tseries/updateUBOOTusb.sh
@@ -0,0 +1,2 @@ 
+#!/bin/sh
+mkimage -A ARM -T script -C none -n "ubootUpdateUSB" -d updateUBOOTusb updateUBOOTusb.img
diff --git a/cpy b/cpy
new file mode 100755
index 0000000..735e6cc
--- /dev/null
+++ b/cpy
@@ -0,0 +1,79 @@ 
+#!/bin/bash
+SRCDIR=.
+DESTDIR=~/work/exchange/u-boot-current/
+TFTPDIR=/tftpboot/tseries/
+
+COMMITID=`git describe --dirty | cut -d "-" -f 4-`
+if [ "$COMMITID" == "" ]; then
+	COMMITID=`git describe --dirty | cut -d "-" -f 3-`
+fi
+
+BRANCH=`git branch | grep "*" | cut -d " " -f 2`
+DATUM=`date +%Y%m%d`
+
+if [ -z $1 ]; then
+  echo "require target argument!"
+  exit 1
+fi
+
+if [ -d ./bur-scripts/$1 ]; then
+	pushd ./bur-scripts/$1 >/dev/null
+	echo "generating BuR U-Boot ($1) scripts ..."
+	for i in `ls *.sh`; do
+	    echo "running $i .."
+	    ./$i 2>&1 >/dev/null
+	done
+	popd >/dev/null
+else
+	echo "no target specific scripts ($1)"
+fi
+
+FLIST='MLO.byteswap MLO u-boot.img spl/u-boot-spl.bin bur-scripts/*.img bur-scripts/*.bin'
+FLIST=`echo $FLIST " bur-scripts/addon/"$1"/*"`
+
+addScriptFiles() {
+	SCRIPTS=`ls bur-scripts/$1/*.img  bur-scripts/$1/*.bin 2>/dev/null`
+	for i in $SCRIPTS; do
+		FLIST="$FLIST $i"
+	done
+}
+
+procFile() {
+	if [ -f $SRCDIR/$1 ]; then
+		cp $SRCDIR/$1 $DST
+	elif [ -f $DST/$1 ]; then
+		rm $DST/$1
+	fi
+}
+
+addScriptFiles $1
+
+# Files in Ausgabeordner synchronisieren
+DST=$DESTDIR
+for i in $FLIST; do
+	procFile $i
+done
+
+# Files in Ausgabeordner synchronisieren
+DST=$TFTPDIR
+for i in $FLIST; do
+	procFile $i
+done
+
+# ZIP zur Verteilung in Ausgabeordner erstellen
+[ -f $DESTDIR/u-boot-$1.zip ] && rm $DESTDIR/u-boot-$1.zip
+echo "U-Boot Version: $COMMITID" > readme-uboot-$1.txt
+zip -j -D $DESTDIR/u-boot-$1.zip $FLIST readme-uboot-$1.txt
+rm readme-uboot-$1.txt
+
+if [ "$1" == "tseries" ]; then
+	ZIPNAME="6PPT30_UBOOT_V0000"_"$DATUM.zip"
+	echo "creating $ZIPNAME for SAP-Checkin ..."
+	[ -r $DESTDIR/$ZIPNAME ] && rm $DESTDIR/$ZIPNAME
+	zip -j -D -q $DESTDIR/$ZIPNAME $DESTDIR/u-boot-$1.zip
+elif [ "$1" == "kwb" ]; then
+	ZIPNAME="KWB_UBOOT_V0000"_"$DATUM.zip"
+	echo "creating $ZIPNAME for SAP-Checkin ..."
+	[ -r $DESTDIR/$ZIPNAME ] && rm $DESTDIR/$ZIPNAME
+	zip -j -D -q $DESTDIR/$ZIPNAME $DESTDIR/u-boot-$1.zip
+fi