On Thu, 2013-10-24 at 07:23 +0200, Michael Opdenacker wrote:
> This is the first version of a script to look for
> Kconfig parameters which are still defined but no longer
> used in the kernel source code.
[]
> diff --git a/scripts/checkkconfig.py b/scripts/checkkconfig.py
[]
> +def count_param(param):
> +
> + global source_file, bad_params_in_file
> +
> + if os.path.isdir('.git'):
> + # Use git grep when available
> + count = subprocess.check_output('git grep ' + param + '| grep -v
> defconfig | wc -l', shell=True)
> + else:
> + # Fallback to regular grep
> + count = subprocess.check_output('grep -R ' + param + ' . | grep -v
> defconfig | wc -l', shell=True)
Doesn't the grep need -w?
Also, the regular grep could probably use something like
'grep -R -w --max-count=2 --include="*.[chS]"'
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/