diff options
Diffstat (limited to 'kernel')
| -rw-r--r-- | kernel/futex.c | 1 | ||||
| -rw-r--r-- | kernel/pid.c | 7 | ||||
| -rw-r--r-- | kernel/power/user.c | 1 | ||||
| -rw-r--r-- | kernel/trace/blktrace.c | 1 | ||||
| -rw-r--r-- | kernel/trace/ftrace.c | 5 | ||||
| -rw-r--r-- | kernel/trace/trace.c | 1 |
6 files changed, 5 insertions, 11 deletions
diff --git a/kernel/futex.c b/kernel/futex.c index 794c862125fe..0672ff88f159 100644 --- a/kernel/futex.c +++ b/kernel/futex.c | |||
| @@ -247,6 +247,7 @@ again: | |||
| 247 | if (err < 0) | 247 | if (err < 0) |
| 248 | return err; | 248 | return err; |
| 249 | 249 | ||
| 250 | page = compound_head(page); | ||
| 250 | lock_page(page); | 251 | lock_page(page); |
| 251 | if (!page->mapping) { | 252 | if (!page->mapping) { |
| 252 | unlock_page(page); | 253 | unlock_page(page); |
diff --git a/kernel/pid.c b/kernel/pid.c index 5fa1db48d8b7..31310b5d3f50 100644 --- a/kernel/pid.c +++ b/kernel/pid.c | |||
| @@ -36,7 +36,6 @@ | |||
| 36 | #include <linux/pid_namespace.h> | 36 | #include <linux/pid_namespace.h> |
| 37 | #include <linux/init_task.h> | 37 | #include <linux/init_task.h> |
| 38 | #include <linux/syscalls.h> | 38 | #include <linux/syscalls.h> |
| 39 | #include <linux/kmemleak.h> | ||
| 40 | 39 | ||
| 41 | #define pid_hashfn(nr, ns) \ | 40 | #define pid_hashfn(nr, ns) \ |
| 42 | hash_long((unsigned long)nr + (unsigned long)ns, pidhash_shift) | 41 | hash_long((unsigned long)nr + (unsigned long)ns, pidhash_shift) |
| @@ -513,12 +512,6 @@ void __init pidhash_init(void) | |||
| 513 | pid_hash = alloc_bootmem(pidhash_size * sizeof(*(pid_hash))); | 512 | pid_hash = alloc_bootmem(pidhash_size * sizeof(*(pid_hash))); |
| 514 | if (!pid_hash) | 513 | if (!pid_hash) |
| 515 | panic("Could not alloc pidhash!\n"); | 514 | panic("Could not alloc pidhash!\n"); |
| 516 | /* | ||
| 517 | * pid_hash contains references to allocated struct pid objects and it | ||
| 518 | * must be scanned by kmemleak to avoid false positives. | ||
| 519 | */ | ||
| 520 | kmemleak_alloc(pid_hash, pidhash_size * sizeof(*(pid_hash)), 0, | ||
| 521 | GFP_KERNEL); | ||
| 522 | for (i = 0; i < pidhash_size; i++) | 515 | for (i = 0; i < pidhash_size; i++) |
| 523 | INIT_HLIST_HEAD(&pid_hash[i]); | 516 | INIT_HLIST_HEAD(&pid_hash[i]); |
| 524 | } | 517 | } |
diff --git a/kernel/power/user.c b/kernel/power/user.c index ed97375daae9..bf0014d6a5f0 100644 --- a/kernel/power/user.c +++ b/kernel/power/user.c | |||
| @@ -23,7 +23,6 @@ | |||
| 23 | #include <linux/console.h> | 23 | #include <linux/console.h> |
| 24 | #include <linux/cpu.h> | 24 | #include <linux/cpu.h> |
| 25 | #include <linux/freezer.h> | 25 | #include <linux/freezer.h> |
| 26 | #include <linux/smp_lock.h> | ||
| 27 | #include <scsi/scsi_scan.h> | 26 | #include <scsi/scsi_scan.h> |
| 28 | 27 | ||
| 29 | #include <asm/uaccess.h> | 28 | #include <asm/uaccess.h> |
diff --git a/kernel/trace/blktrace.c b/kernel/trace/blktrace.c index 39af8af6fc30..1090b0aed9ba 100644 --- a/kernel/trace/blktrace.c +++ b/kernel/trace/blktrace.c | |||
| @@ -22,6 +22,7 @@ | |||
| 22 | #include <linux/init.h> | 22 | #include <linux/init.h> |
| 23 | #include <linux/mutex.h> | 23 | #include <linux/mutex.h> |
| 24 | #include <linux/debugfs.h> | 24 | #include <linux/debugfs.h> |
| 25 | #include <linux/smp_lock.h> | ||
| 25 | #include <linux/time.h> | 26 | #include <linux/time.h> |
| 26 | #include <linux/uaccess.h> | 27 | #include <linux/uaccess.h> |
| 27 | 28 | ||
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c index bce9e01a29c8..4521c77d1a1a 100644 --- a/kernel/trace/ftrace.c +++ b/kernel/trace/ftrace.c | |||
| @@ -768,7 +768,7 @@ static struct tracer_stat function_stats __initdata = { | |||
| 768 | .stat_show = function_stat_show | 768 | .stat_show = function_stat_show |
| 769 | }; | 769 | }; |
| 770 | 770 | ||
| 771 | static void ftrace_profile_debugfs(struct dentry *d_tracer) | 771 | static __init void ftrace_profile_debugfs(struct dentry *d_tracer) |
| 772 | { | 772 | { |
| 773 | struct ftrace_profile_stat *stat; | 773 | struct ftrace_profile_stat *stat; |
| 774 | struct dentry *entry; | 774 | struct dentry *entry; |
| @@ -786,7 +786,6 @@ static void ftrace_profile_debugfs(struct dentry *d_tracer) | |||
| 786 | * The files created are permanent, if something happens | 786 | * The files created are permanent, if something happens |
| 787 | * we still do not free memory. | 787 | * we still do not free memory. |
| 788 | */ | 788 | */ |
| 789 | kfree(stat); | ||
| 790 | WARN(1, | 789 | WARN(1, |
| 791 | "Could not allocate stat file for cpu %d\n", | 790 | "Could not allocate stat file for cpu %d\n", |
| 792 | cpu); | 791 | cpu); |
| @@ -813,7 +812,7 @@ static void ftrace_profile_debugfs(struct dentry *d_tracer) | |||
| 813 | } | 812 | } |
| 814 | 813 | ||
| 815 | #else /* CONFIG_FUNCTION_PROFILER */ | 814 | #else /* CONFIG_FUNCTION_PROFILER */ |
| 816 | static void ftrace_profile_debugfs(struct dentry *d_tracer) | 815 | static __init void ftrace_profile_debugfs(struct dentry *d_tracer) |
| 817 | { | 816 | { |
| 818 | } | 817 | } |
| 819 | #endif /* CONFIG_FUNCTION_PROFILER */ | 818 | #endif /* CONFIG_FUNCTION_PROFILER */ |
diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c index 3aa0a0dfdfa8..8bc8d8afea6a 100644 --- a/kernel/trace/trace.c +++ b/kernel/trace/trace.c | |||
| @@ -17,6 +17,7 @@ | |||
| 17 | #include <linux/writeback.h> | 17 | #include <linux/writeback.h> |
| 18 | #include <linux/kallsyms.h> | 18 | #include <linux/kallsyms.h> |
| 19 | #include <linux/seq_file.h> | 19 | #include <linux/seq_file.h> |
| 20 | #include <linux/smp_lock.h> | ||
| 20 | #include <linux/notifier.h> | 21 | #include <linux/notifier.h> |
| 21 | #include <linux/irqflags.h> | 22 | #include <linux/irqflags.h> |
| 22 | #include <linux/debugfs.h> | 23 | #include <linux/debugfs.h> |
