Messages in this thread | | | Subject | Re: [PATCH 0/2] jump label: 2.6.38 updates | From | Peter Zijlstra <> | Date | Mon, 14 Feb 2011 17:53:14 +0100 |
| |
On Mon, 2011-02-14 at 11:46 -0500, Steven Rostedt wrote: > On Mon, 2011-02-14 at 17:37 +0100, Peter Zijlstra wrote: > > > We could of course cheat implement our own version of atomic_read() in > > order to avoid the whole header mess, but that's not pretty at all > > Oh God please no! ;) > > atomic_read() is implemented per arch.
Ah, but it needn't be:
static inline int atomic_read(atomic_t *a) { return ACCESS_ONCE(a->counter); }
is basically it.
| |