From 7d867d4d2021b3b7c9368f77e952e39d4ff9d0d5 Mon Sep 17 00:00:00 2001 From: Andrew Morton Date: Thu, 26 Aug 2004 20:37:13 -0700 Subject: [PATCH] [PATCH] sane mlock_limit As David M-T points out, the default per-user mlock limit should be at least a single page. Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- include/linux/resource.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/resource.h b/include/linux/resource.h index b930c9cb77271..21a86cb6acdb6 100644 --- a/include/linux/resource.h +++ b/include/linux/resource.h @@ -59,7 +59,7 @@ struct rlimit { * GPG wants 32kB of mlocked memory, to make sure pass phrases * and other sensitive information are never written to disk. */ -#define MLOCK_LIMIT (32*1024) +#define MLOCK_LIMIT (8 * PAGE_SIZE) /* * Due to binary compatibility, the actual resource numbers -- 2.53.0