perf_counter: per user mlock gift
Instead of a per-process mlock gift for perf-counters, use a per-user gift so that there is less of a DoS potential. [ Impact: allow less worst-case unprivileged memory consumption ] Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Paul Mackerras <paulus@samba.org> Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> LKML-Reference: <20090515132018.496182835@chello.nl> Signed-off-by: Ingo Molnar <mingo@elte.hu>
This commit is contained in:

committed by
Ingo Molnar

parent
548e1ddf25
commit
789f90fcf6
@@ -674,6 +674,10 @@ struct user_struct {
|
||||
struct work_struct work;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_PERF_COUNTERS
|
||||
atomic_long_t locked_vm;
|
||||
#endif
|
||||
};
|
||||
|
||||
extern int uids_sysfs_init(void);
|
||||
|
Reference in New Issue
Block a user