]> git.karo-electronics.de Git - karo-tx-linux.git/blob - arch/arm/tools/syscalltbl.sh
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm...
[karo-tx-linux.git] / arch / arm / tools / syscalltbl.sh
1 #!/bin/sh
2 in="$1"
3 out="$2"
4 my_abis=`echo "($3)" | tr ',' '|'`
5
6 grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
7     while read nr abi name entry compat; do
8         if [ "$abi" = "eabi" -a -n "$compat" ]; then
9             echo "$in: error: a compat entry for an EABI syscall ($name) makes no sense" >&2
10             exit 1
11         fi
12
13         if [ -n "$entry" ]; then
14             if [ -z "$compat" ]; then
15                 echo "NATIVE($nr, $entry)"
16             else
17                 echo "COMPAT($nr, $entry, $compat)"
18             fi
19         fi
20     done
21 ) > "$out"