Posts

Showing posts from 2014

Checkpatch From Linux

Brief: checkpatch.pl is pearl script for detecting coding style errors in Linux source. Since Linux kernel is a huge source with approximately 3431 directories, 48619 files so you can imagine the amount of code in it. So to get the coding style correct (uniform) across the complete source of Linux chekpatch.pl script is used. Usage: A> With a valid patch (by valid patch i mean it is created git-format patch command) $ ./scripts/checkpatch.pl  < path to patch file> For Example: $ ./scripts/checkpatch.pl  *.patch Would run the script for all the patches in current directory. B> With file (By the name you might feel it only tests patches no you can also run this on files) $ ./scripts/checkpatch.pl --terse --file  <path to file> Options: --terse:  Specifies to report warining/error per line --file/ -f: Specifies regular source file. For Example: $ ./scripts/checkpatch.pl --terse --file  arch/arm/common/bL_switcher.c arch/arm...