lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Wed,  5 Feb 2014 10:01:51 -0500
From:	Prarit Bhargava <prarit@...hat.com>
To:	linux-kernel@...r.kernel.org
Cc:	Prarit Bhargava <prarit@...hat.com>, Michal Marek <mmarek@...e.cz>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Kirill Tkhai <tkhai@...dex.ru>,
	Michael Opdenacker <michael.opdenacker@...e-electrons.com>,
	Rusty Russell <rusty@...tcorp.com.au>,
	linux-kbuild@...r.kernel.org
Subject: [PATCH] Makefile, CONFIG_MODVERSIONS, ignore *.mod.c files

CONFIG_MODVERSIONS=y results in a .mod.c for every compiled file in the kernel.
Issuing a 'make cscope' on a compiled kernel tree results in the cscope files
containing *.mod.c files.

[prarit@...rit linux]# make cscope
[prarit@...rit linux]# cat cscope.files | grep mod.c | wc -l
4807

These files are not useful for cscope and should be ignored.  For example,

   #   line  filename / context / line
   1    105  arch/x86/kvm/kvm-intel.mod.c <<GLOBAL>>
             { 0x618911fc, __VMLINUX_SYMBOL_STR(numa_node) },
   2    508  drivers/block/mtip32xx/mtip32xx.h <<GLOBAL>>
             int numa_node;
   3     55  drivers/block/mtip32xx/mtip32xx.mod.c <<GLOBAL>>
             { 0x618911fc, __VMLINUX_SYMBOL_STR(numa_node) },
   4     37  drivers/cpufreq/acpi-cpufreq.mod.c <<GLOBAL>>
             { 0x618911fc, __VMLINUX_SYMBOL_STR(numa_node) },
   <snip>

Add *.mod.c to the RCS_FIND_IGNORE in the top-level Makefile and to the ignore
list in scripts/tags.sh.

Signed-off-by: Prarit Bhargava <prarit@...hat.com>
Cc: Michal Marek <mmarek@...e.cz>
Cc: Andrew Morton <akpm@...ux-foundation.org>
Cc: Kirill Tkhai <tkhai@...dex.ru>
Cc: Michael Opdenacker <michael.opdenacker@...e-electrons.com>
Cc: Rusty Russell <rusty@...tcorp.com.au>
Cc: linux-kbuild@...r.kernel.org
---
 Makefile        |    3 ++-
 scripts/tags.sh |    2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile
index 606ef7c..4e1b87a 100644
--- a/Makefile
+++ b/Makefile
@@ -415,7 +415,8 @@ export MODVERDIR := $(if $(KBUILD_EXTMOD),$(firstword $(KBUILD_EXTMOD))/).tmp_ve
 # Files to ignore in find ... statements
 
 RCS_FIND_IGNORE := \( -name SCCS -o -name BitKeeper -o -name .svn -o -name CVS \
-		   -o -name .pc -o -name .hg -o -name .git \) -prune -o
+		   -o -name .pc -o -name .hg -o -name .git -o -name *.mod.c\) \
+		   -prune -o
 export RCS_TAR_IGNORE := --exclude SCCS --exclude BitKeeper --exclude .svn \
 			 --exclude CVS --exclude .pc --exclude .hg --exclude .git
 
diff --git a/scripts/tags.sh b/scripts/tags.sh
index 58c4559..6229d6b 100755
--- a/scripts/tags.sh
+++ b/scripts/tags.sh
@@ -14,7 +14,7 @@ fi
 # This is a duplicate of RCS_FIND_IGNORE without escaped '()'
 ignore="( -name SCCS -o -name BitKeeper -o -name .svn -o \
           -name CVS  -o -name .pc       -o -name .hg  -o \
-          -name .git )                                   \
+          -name .git -o -name *.mod.c )                  \
           -prune -o"
 
 # Do not use full path if we do not use O=.. builds
-- 
1.7.9.3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ