All of lore.kernel.org
 help / color / mirror / Atom feed
From: Philippe Gerum <rpm@xenomai.org>
To: Steven Seeger <steve@domain.hid>
Cc: "xenomai@xenomai.org" <xenomai@xenomai.org>
Subject: Re: [Xenomai-help] atomic_t in userspace
Date: Wed, 15 Feb 2006 16:39:43 +0100	[thread overview]
Message-ID: <43F34B3F.6030103@domain.hid> (raw)
In-Reply-To: <C01886AB.23C1%steve@domain.hid>

Steven Seeger wrote:
> I just upgraded to the latest SVN after a few months of hiatus, and my
> userspace app that used atomic_t through nucleus/asm/atomic.h no longer
> works. It says it can't find atomic_t, and it seems that all the atomic
> operations have been put inside a kernel only #if. Is there another way to
> use atomics in my shadowed threads from userspace? Is there any equivalent?
> 

Atomic ops were formerly obtained by including linux/include/asm/atomic.h, and 
doing so from user-space context caused a number of troubles, notably to C++ 
users. Additionally, doing so was clearly bad practice since we would cause 
namespace pollution and all sort of conflicts with kernel-only symbols. For this 
reason, it has been decided to (re-)implement the very few atomic ops we need in 
the user-space section of xenomai/include/asm-*/atomic.h, instead of reading them 
from the kernel file(s). But since atomic counters are not needed (anymore) by 
Xenomai's user-space code, they have not been provided.

You should implement your local copy of the missing stuff, or directly include 
linux/include/asm/atomic.h from your own headers, but at your own risk.

> Steven
> 
> 
> _______________________________________________
> Xenomai-help mailing list
> Xenomai-help@domain.hid
> https://mail.gna.org/listinfo/xenomai-help
> 


-- 

Philippe.


      reply	other threads:[~2006-02-15 15:39 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-02-15 15:20 [Xenomai-help] atomic_t in userspace Steven Seeger
2006-02-15 15:39 ` Philippe Gerum [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=43F34B3F.6030103@domain.hid \
    --to=rpm@xenomai.org \
    --cc=steve@domain.hid \
    --cc=xenomai@xenomai.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.