summaryrefslogtreecommitdiffstats
path: root/hdata/test/dtdiff_wrap.sh
blob: 75c18bafc807fa14bd920af67a4bf427a7fb077a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/bash

# Takes /dev/stdin as dtb, saves to file, does dtdiff
# Also runs parameter through a dts->dtb->dts conversion
# in order to work around dtc bugs.

T=$(mktemp)
cp /dev/stdin $T.dtb
dtc -I dts -O dtb $1 > $T.orig.dtb
dtdiff $T.orig.dtb $T.dtb
R=$?
if [ $R == 0 ]; then rm -f $T.dtb; fi
exit $R
OpenPOWER on IntegriCloud