# - DPDK_CHECKPATCH_PATH
# - DPDK_CHECKPATCH_LINE_LENGTH
. scripts/load-devel-config.sh
-if [ ! -x "$DPDK_CHECKPATCH_PATH" ] ; then
- echo 'Cannot execute DPDK_CHECKPATCH_PATH' >&2
- exit 1
-fi
length=${DPDK_CHECKPATCH_LINE_LENGTH:-80}
NEW_TYPEDEFS,COMPARISON_TO_NULL"
print_usage () {
- echo "usage: $(basename $0) [-q] [-v] [patch1 [patch2] ...]]"
+ cat <<- END_OF_HELP
+ usage: $(basename $0) [-q] [-v] [patch1 [patch2] ...]]
+
+ Run Linux kernel checkpatch.pl with DPDK options.
+ The environment variable DPDK_CHECKPATCH_PATH must be set.
+ END_OF_HELP
}
quiet=false
done
shift $(($OPTIND - 1))
+if [ ! -x "$DPDK_CHECKPATCH_PATH" ] ; then
+ print_usage >&2
+ echo
+ echo 'Cannot execute DPDK_CHECKPATCH_PATH' >&2
+ exit 1
+fi
+
status=0
for p in "$@" ; do
! $verbose || printf '\n### %s\n\n' "$p"