mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Stefan Richter <stefanr@s5r6.in-berlin.de>
To: "Robert P. J. Day" <rpjday@mindspring.com>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: why is it called "asm-generic/atomic.h"?
Date: Thu, 07 Jun 2007 17:31:18 +0200	[thread overview]
Message-ID: <466824C6.60100@s5r6.in-berlin.de> (raw)
In-Reply-To: <Pine.LNX.4.64.0706070822590.17588@localhost.localdomain>

Robert P. J. Day wrote:
>   i'm just curious -- why does that particular header file have that
> name?  its opening comment reads:
> 
>  * Allows to provide arch independent atomic definitions without the need to
>  * edit all arch specific atomic.h files.
> 
> but that's *not* what that header file does.

The file name is correct, and the comment is correct too.  It indeed
_allows_ to define architecture-independent operations on atomic types,
and it currently does so for atomic_long_t.  There is no need to do so
for atomic_t, because all architectures already had their own set of
atomic_t operations when asm-generic/atomic.h was added.  (And I presume
they varied too much to justify an additional generic implementation
plus #ifndef HAVE_ARCH_SOMETHING games.)

PS:  The atomic_long_t operations currently don't need to be protected
by #ifndef HAVE_ARCH_SOMETHING and won't need to be in foreseeable
future, therefore they don't have this protection.
-- 
Stefan Richter
-=====-=-=== -==- --===
http://arcgraph.de/sr/

      reply	other threads:[~2007-06-07 15:31 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-07 12:28 Robert P. J. Day
2007-06-07 15:31 ` Stefan Richter [this message]

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=466824C6.60100@s5r6.in-berlin.de \
    --to=stefanr@s5r6.in-berlin.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rpjday@mindspring.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®