mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Frantisek Hrbata <fhrbata@redhat.com>
To: linux-kernel@vger.kernel.org
Cc: oleg@redhat.com, matt.fleming@linux.intel.com, hughd@google.com
Subject: [PATCH] exec: remove page_table_lock for mm counters in acct_arg_size()
Date: Thu, 14 Jul 2011 15:16:20 +0200	[thread overview]
Message-ID: <1310649380-13492-1-git-send-email-fhrbata@redhat.com> (raw)

Commit 172703b mm: delete non-atomic mm counter implementation
removed non-atomic mm counters implementation. I think there is no need to hold
page_table_lock for add_mm_counter() when the splitted page table locks are not
used. This patch removes the locking.

Signed-off-by: Frantisek Hrbata <fhrbata@redhat.com>
---
 fs/exec.c |    6 ------
 1 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/fs/exec.c b/fs/exec.c
index 6075a1e..e6fc5e1 100644
--- a/fs/exec.c
+++ b/fs/exec.c
@@ -182,13 +182,7 @@ static void acct_arg_size(struct linux_binprm *bprm, unsigned long pages)
 
 	bprm->vma_pages = pages;
 
-#ifdef SPLIT_RSS_COUNTING
 	add_mm_counter(mm, MM_ANONPAGES, diff);
-#else
-	spin_lock(&mm->page_table_lock);
-	add_mm_counter(mm, MM_ANONPAGES, diff);
-	spin_unlock(&mm->page_table_lock);
-#endif
 }
 
 static struct page *get_arg_page(struct linux_binprm *bprm, unsigned long pos,
-- 
1.7.4.4


             reply	other threads:[~2011-07-14 13:16 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-14 13:16 Frantisek Hrbata [this message]
2011-07-14 13:18 ` Oleg Nesterov
2011-07-14 13:23   ` Frantisek Hrbata

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1310649380-13492-1-git-send-email-fhrbata@redhat.com \
    --to=fhrbata@redhat.com \
    --cc=hughd@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matt.fleming@linux.intel.com \
    --cc=oleg@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®