Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ae6b585e authored by Oleg Nesterov's avatar Oleg Nesterov
Browse files

exec: document acct_arg_size()



Add the comment to explain acct_arg_size().

Signed-off-by: default avatarOleg Nesterov <oleg@redhat.com>
Reviewed-by: default avatarKOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
parent 0e028465
Loading
Loading
Loading
Loading
+6 −1
Original line number Original line Diff line number Diff line
@@ -167,7 +167,12 @@ out:
}
}


#ifdef CONFIG_MMU
#ifdef CONFIG_MMU

/*
 * The nascent bprm->mm is not visible until exec_mmap() but it can
 * use a lot of memory, account these pages in current->mm temporary
 * for oom_badness()->get_mm_rss(). Once exec succeeds or fails, we
 * change the counter back via acct_arg_size(0).
 */
static void acct_arg_size(struct linux_binprm *bprm, unsigned long pages)
static void acct_arg_size(struct linux_binprm *bprm, unsigned long pages)
{
{
	struct mm_struct *mm = current->mm;
	struct mm_struct *mm = current->mm;