oom: make oom_reaper_list single linked

Entries are only added/removed from oom_reaper_list at head so we can
use a single linked list and hence save a word in task_struct.

Signed-off-by: Vladimir Davydov <vdavydov@virtuozzo.com>
Signed-off-by: Michal Hocko <mhocko@suse.com>
Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Cc: David Rientjes <rientjes@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
Vladimir Davydov
2016-03-25 14:20:39 -07:00
committed by Linus Torvalds
parent 855b018325
commit 29c696e1c6
2 changed files with 8 additions and 9 deletions

View File

@@ -1852,7 +1852,7 @@ struct task_struct {
#endif
int pagefault_disabled;
#ifdef CONFIG_MMU
struct list_head oom_reaper_list;
struct task_struct *oom_reaper_list;
#endif
/* CPU-specific state of this task */
struct thread_struct thread;