Removing atomic.h from Fedora kernel headers

Gilboa Davara gilboad at gmail.com
Sun Jun 24 11:17:50 UTC 2007


On Fri, 2007-06-22 at 16:41 -0400, Bill Nottingham wrote:
> Chuck Ebbert (cebbert at redhat.com) said: 
> > Why do we explicitly remove atomic.h from our kernel header package?
> 
> IIRC, the reasoning was because the operations weren't actually
> atomic when used from userspace; ergo, it was a bad idea to provide
> them.
> 
> Bill

... Unless you define CONFIG_SMP (which in turn, defines LOCK_PREFIX)
I assume that up-stream will shoot me for suggesting that... but why not
just add:

#ifndef __KERNEL__
#define LOCK_PREFIX "lock; "
#endif

... and make atomic_xxx safe for user-land?

- Gilboa




More information about the Fedora-kernel-list mailing list