mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Paul Mackerras <paulus@samba.org>
To: Andrew Morton <akpm@osdl.org>
Cc: Jan Blunck <jblunck@suse.de>, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] fix vmstat per cpu usage
Date: Wed, 2 Aug 2006 08:44:38 +1000	[thread overview]
Message-ID: <17615.55638.314556.722153@cargo.ozlabs.ibm.com> (raw)
In-Reply-To: <20060801140707.a55a0513.akpm@osdl.org>

Andrew Morton writes:

> On Tue, 1 Aug 2006 19:36:21 +0200
> Jan Blunck <jblunck@suse.de> wrote:
> 
> > The per cpu variables are used incorrectly in vmstat.h.
[snip]
> > -	__get_cpu_var(vm_event_states.event[item])++;
> > +	__get_cpu_var(vm_event_states).event[item]++;
> >  }
> 
> How odd.  Are there any negative consequences to the existing code?

That sort of thing - i.e. using __get_cpu_var on something which isn't
just a simple variable name - works with the current per-cpu macro
definitions, because they are pretty simple, but one can imagine other
reasonable implementations of __get_cpu_var which need the argument to
be a simple variable name.  I struck this when I was experimenting
with using __thread variables for per-cpu data.

Paul.

  reply	other threads:[~2006-08-01 22:44 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-08-01 17:36 Jan Blunck
2006-08-01 21:07 ` Andrew Morton
2006-08-01 22:44   ` Paul Mackerras [this message]
2006-08-02  9:01   ` Jan Blunck
2006-08-02 13:30   ` Jan Blunck
2006-08-02 14:43     ` Andrew Morton
2006-08-07 12:42       ` Jan Blunck
2006-08-02 16:54 ` Steve Fox

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=17615.55638.314556.722153@cargo.ozlabs.ibm.com \
    --to=paulus@samba.org \
    --cc=akpm@osdl.org \
    --cc=jblunck@suse.de \
    --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 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®