Messages in this thread Patch in this message | | | Date | Sat, 18 Oct 2008 00:54:31 -0400 | From | "J.R. Mauro" <> | Subject | Re: Lindent and __user, etc. |
| |
Here's a patch that outlines the basic idea. Obviously more types should be added to catch more things that Lindent currently misses if this change seems beneficial.
Make Lindent aware of sparse annotations and integer declarations
Signed-off by: J.R. Mauro <jrm8005@gmail.com> --
--- Lindent 2008-10-17 18:16:56.000000000 -0400 +++ Lindent-mod 2008-10-18 00:37:49.000000000 -0400 @@ -1,5 +1,7 @@ #!/bin/sh PARAM="-npro -kr -i8 -ts8 -sob -l80 -ss -ncs -cp1" +CHECK="-T __user -T __kernel -T __safe -T __force -T __nocast -T __iomem" +TYPES="-T s8 -T u8 -T s16 -T u16 -T s32 -T u32 -T s64 -T u64" RES=`indent --version` V1=`echo $RES | cut -d' ' -f3 | cut -d'.' -f1` V2=`echo $RES | cut -d' ' -f3 | cut -d'.' -f2` @@ -15,4 +17,4 @@ elif [ $V1 -eq 2 ]; then fi fi fi -indent $PARAM "$@" +indent $PARAM $CHECK $TYPES "$@"
| |