aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-06-12 22:18:49 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2014-06-12 22:18:49 -0400
commit3737a12761636ebde0f09ef49daebb8eed18cc8a (patch)
tree965057f4bccd97049f8c0140f8670c5d4278ca3e /fs
parentc29deef32e3699e40da3e9e82267610de04e6b54 (diff)
parent82b897782d10fcc4930c9d4a15b175348fdd2871 (diff)
Merge branch 'perf-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull more perf updates from Ingo Molnar: "A second round of perf updates: - wide reaching kprobes sanitization and robustization, with the hope of fixing all 'probe this function crashes the kernel' bugs, by Masami Hiramatsu. - uprobes updates from Oleg Nesterov: tmpfs support, corner case fixes and robustization work. - perf tooling updates and fixes from Jiri Olsa, Namhyung Ki, Arnaldo et al: * Add support to accumulate hist periods (Namhyung Kim) * various fixes, refactorings and enhancements" * 'perf-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (101 commits) perf: Differentiate exec() and non-exec() comm events perf: Fix perf_event_comm() vs. exec() assumption uprobes/x86: Rename arch_uprobe->def to ->defparam, minor comment updates perf/documentation: Add description for conditional branch filter perf/x86: Add conditional branch filtering support perf/tool: Add conditional branch filter 'cond' to perf record perf: Add new conditional branch filter 'PERF_SAMPLE_BRANCH_COND' uprobes: Teach copy_insn() to support tmpfs uprobes: Shift ->readpage check from __copy_insn() to uprobe_register() perf/x86: Use common PMU interrupt disabled code perf/ARM: Use common PMU interrupt disabled code perf: Disable sampled events if no PMU interrupt perf: Fix use after free in perf_remove_from_context() perf tools: Fix 'make help' message error perf record: Fix poll return value propagation perf tools: Move elide bool into perf_hpp_fmt struct perf tools: Remove elide setup for SORT_MODE__MEMORY mode perf tools: Fix "==" into "=" in ui_browser__warning assignment perf tools: Allow overriding sysfs and proc finding with env var perf tools: Consider header files outside perf directory in tags target ...
Diffstat (limited to 'fs')
-rw-r--r--fs/exec.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/fs/exec.c b/fs/exec.c
index 238b7aa26f68..a3d33fe592d6 100644
--- a/fs/exec.c
+++ b/fs/exec.c
@@ -1046,13 +1046,13 @@ EXPORT_SYMBOL_GPL(get_task_comm);
1046 * so that a new one can be started 1046 * so that a new one can be started
1047 */ 1047 */
1048 1048
1049void set_task_comm(struct task_struct *tsk, const char *buf) 1049void __set_task_comm(struct task_struct *tsk, const char *buf, bool exec)
1050{ 1050{
1051 task_lock(tsk); 1051 task_lock(tsk);
1052 trace_task_rename(tsk, buf); 1052 trace_task_rename(tsk, buf);
1053 strlcpy(tsk->comm, buf, sizeof(tsk->comm)); 1053 strlcpy(tsk->comm, buf, sizeof(tsk->comm));
1054 task_unlock(tsk); 1054 task_unlock(tsk);
1055 perf_event_comm(tsk); 1055 perf_event_comm(tsk, exec);
1056} 1056}
1057 1057
1058int flush_old_exec(struct linux_binprm * bprm) 1058int flush_old_exec(struct linux_binprm * bprm)
@@ -1110,7 +1110,8 @@ void setup_new_exec(struct linux_binprm * bprm)
1110 else 1110 else
1111 set_dumpable(current->mm, suid_dumpable); 1111 set_dumpable(current->mm, suid_dumpable);
1112 1112
1113 set_task_comm(current, kbasename(bprm->filename)); 1113 perf_event_exec();
1114 __set_task_comm(current, kbasename(bprm->filename), true);
1114 1115
1115 /* Set the new mm task size. We have to do that late because it may 1116 /* Set the new mm task size. We have to do that late because it may
1116 * depend on TIF_32BIT which is only updated in flush_thread() on 1117 * depend on TIF_32BIT which is only updated in flush_thread() on