From: Arnd Bergmann <arnd@arndb.de>
To: Christoph Lameter <cl@linux-foundation.org>
Cc: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>,
Tejun Heo <tj@kernel.org>, Mike Frysinger <vapier.adi@gmail.com>,
linux-kernel@vger.kernel.org
Subject: Re: [RFC local_t removal V2 2/3] Remove local_t type from tree.
Date: Fri, 8 Jan 2010 09:55:07 +0100 [thread overview]
Message-ID: <201001080955.07231.arnd@arndb.de> (raw)
In-Reply-To: <20100107223548.270401090@quilx.com>
On Thursday 07 January 2010 23:35:26 Christoph Lameter wrote:
> -#define local_add_return(i, l) atomic_long_add_return((i), (&(l)->a))
> + local_irq_save(flags);
> + switch (size) {
> + case 1: r = (*((u8 *)ptr) += value);
> + break;
> + case 2: r = (*((u16 *)ptr) += value);
> + break;
> + case 4: r = (*((u32 *)ptr) += value);
> + break;
> + case 8: r = (*((u64 *)ptr) += value);
> + break;
> + }
> + local_irq_restore(flags);
> + return r;
> +}
This still misses 'volatile'.
Arnd
next prev parent reply other threads:[~2010-01-08 8:55 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-07 22:35 [RFC local_t removal V2 0/3] Remove local_t Christoph Lameter
2010-01-07 22:35 ` [RFC local_t removal V2 1/3] Remove unused local.h functions Christoph Lameter
2010-01-07 22:35 ` [RFC local_t removal V2 2/3] Remove local_t type from tree Christoph Lameter
2010-01-08 8:55 ` Arnd Bergmann [this message]
2010-01-07 22:35 ` [RFC local_t removal V2 3/3] Eliminate local_cmpxchg Christoph Lameter
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=201001080955.07231.arnd@arndb.de \
--to=arnd@arndb.de \
--cc=cl@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mathieu.desnoyers@polymtl.ca \
--cc=tj@kernel.org \
--cc=vapier.adi@gmail.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
Powered by JetHome