]> git.karo-electronics.de Git - karo-tx-linux.git/commit
gcov: fix null-pointer dereference for certain module types
authorPeter Oberparleiter <oberpar@linux.vnet.ibm.com>
Thu, 9 Sep 2010 23:37:35 +0000 (16:37 -0700)
committerPaul Gortmaker <paul.gortmaker@windriver.com>
Thu, 6 Jan 2011 23:07:46 +0000 (18:07 -0500)
commit34afb10be8f95bf482576b2b9d82810cd45aa21d
tree68e6352a9b5a38de6a292b04f4bb72a46bbff2bd
parent639e5434c802fd0e3106f0049d4fa1a7a908653f
gcov: fix null-pointer dereference for certain module types

commit 85a0fdfd0f967507f3903e8419bc7e408f5a59de upstream.

The gcov-kernel infrastructure expects that each object file is loaded
only once.  This may not be true, e.g.  when loading multiple kernel
modules which are linked to the same object file.  As a result, loading
such kernel modules will result in incorrect gcov results while unloading
will cause a null-pointer dereference.

This patch fixes these problems by changing the gcov-kernel infrastructure
so that multiple profiling data sets can be associated with one debugfs
entry.  It applies to 2.6.36-rc1.

Signed-off-by: Peter Oberparleiter <oberpar@linux.vnet.ibm.com>
Reported-by: Werner Spies <werner.spies@thalesgroup.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
kernel/gcov/fs.c