All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rasmus Andersen <rasmus@jaquet.dk>
To: Roberto Fichera <kernel@tekno-soft.it>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] mm->rss is modified without page_table_lock held
Date: Sat, 9 Dec 2000 13:43:27 +0100	[thread overview]
Message-ID: <20001209134327.C599@jaquet.dk> (raw)
In-Reply-To: <20001208212910.E599@jaquet.dk> <4.3.2.7.2.20001209111347.00c829f0@mail.tekno-soft.it>
In-Reply-To: <4.3.2.7.2.20001209111347.00c829f0@mail.tekno-soft.it>; from kernel@tekno-soft.it on Sat, Dec 09, 2000 at 11:25:09AM +0100

On Sat, Dec 09, 2000 at 11:25:09AM +0100, Roberto Fichera wrote:
[...]
> >+       spin_lock(&mm->page_table_lock);
> >         mm->rss++;
> >+       spin_unlock(&mm->page_table_lock);
> >
> 
> [...snip...]
> 
> Why we couldn't use atomic_inc(&mm->rss) here and below, avoiding to wrap
> the inc with a spin_lock()/spin_unlock() ?
> 

AFAIR, because for some architectures we can't rely on mm->rss fitting in
an atomic_t. See davem's (somewhat short) post in this thread. Otherwise
search the archives for the original thread treating this problem.
-- 
        Rasmus(rasmus@jaquet.dk)

Television is called a medium because it is neither rare nor well-done. 
  -- Anonymous
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

  parent reply	other threads:[~2000-12-09 12:14 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-12-08 20:29 [PATCH] mm->rss is modified without page_table_lock held Rasmus Andersen
2000-12-08 20:36 ` Mark Hahn
2000-12-08 20:58   ` David S. Miller
2000-12-09 10:25 ` Roberto Fichera
2000-12-09 12:32   ` David S. Miller
2000-12-09 12:43   ` Rasmus Andersen [this message]
2000-12-09 14:48   ` Roberto Fichera
2000-12-09 14:42     ` David S. Miller
2000-12-09 22:38       ` Albert D. Cahalan
2000-12-09 15:07     ` Roberto Fichera
2000-12-09 15:00       ` David S. Miller
2000-12-09 18:11       ` Roberto Fichera

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=20001209134327.C599@jaquet.dk \
    --to=rasmus@jaquet.dk \
    --cc=kernel@tekno-soft.it \
    --cc=linux-kernel@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.