1
0
Fork 0

exec: document acct_arg_size()

Add the comment to explain acct_arg_size().

Signed-off-by: Oleg Nesterov <oleg@redhat.com>
Reviewed-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
hifive-unleashed-5.1
Oleg Nesterov 2011-03-06 18:03:11 +01:00
parent 0e028465d1
commit ae6b585eeb
1 changed files with 6 additions and 1 deletions

View File

@ -167,7 +167,12 @@ out:
}
#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)
{
struct mm_struct *mm = current->mm;