* 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: perf: Fix task_struct reference leak perf: Fix task context scheduling perf: mmap 512 kiB by default perf: Rebase max unprivileged mlock threshold on top of page size perf tools: Fix NO_NEWT=1 python build error perf symbols: Properly align symbol_conf.priv_size perf tools: Emit clearer message for sys_perf_event_open ENOENT return perf tools: Fixup exit path when not able to open events perf symbols: Fix vsyscall symbol lookup oprofile, x86: Allow setting EDGE/INV/CMASK for counter events
Showing the changes to kernel (1 of 12 files). Show all
Unified · Split
| @@ -145,8 +145,8 @@ static struct srcu_struct pmus_srcu; · 144 unmodified lines | ||
| 145 | 145 | */ |
| 146 | 146 | int sysctl_perf_event_paranoid __read_mostly = 1; |
| 147 | 147 | |
| 148 | −/* Minimum for 128 pages + 1 for the user control page */ | |
| 149 | −int sysctl_perf_event_mlock __read_mostly = 516; /* 'free' kb per user */ | |
| 148 | +/* Minimum for 512 kiB + 1 user control page */ | |
| 149 | +int sysctl_perf_event_mlock __read_mostly = 512 + (PAGE_SIZE / 1024); /* 'free' kiB per user */ | |
| 150 | 150 | |
| 151 | 151 | /* |
| 152 | 152 | * max perf event sample rate |
| @@ -6531,6 +6531,11 @@ SYSCALL_DEFINE5(perf_event_open, · 6378 unmodified lines | ||
| 6531 | 6531 | goto err_alloc; |
| 6532 | 6532 | } |
| 6533 | 6533 | |
| 6534 | + if (task) { | |
| 6535 | + put_task_struct(task); | |
| 6536 | + task = NULL; | |
| 6537 | + } | |
| 6538 | + | |
| 6534 | 6539 | /* |
| 6535 | 6540 | * Look up the group leader (we will attach this event to it): |
| 6536 | 6541 | */ |