Thread (10 messages) 10 messages, 5 authors, 2011-12-05

Re: Re: [PATCHv5] atomic: add *_dec_not_zero

From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Date: 2011-12-04 22:41:55
Also in: batman, linux-alpha, linux-arch, linux-arm-kernel, linux-mips, linux-um

On Sun, 2011-12-04 at 22:18 +0000, Russell King - ARM Linux wrote:

 .../...
And really, I believe it would be a good cleanup if all the standard
definitions for atomic64 ops (like atomic64_add_negative) were also
defined in include/linux/atomic.h rather than individually in every
atomic*.h header throughout the kernel source, except where an arch
wants to explicitly override it.  Yet again, virtually all architectures
define these in exactly the same way.

We have more than enough code in arch/ for any architecture to worry
about, we don't need schemes to add more when there's simple and
practical solutions to avoiding doing so if the right design were
chosen (preferably from the outset.)

So, I'm not going to offer my ack for a change which I don't believe
is the correct approach.
I agree with Russell, his approach is a lot easier to maintain long run,
we should even consider converting existing definitions.

Cheers,
Ben.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help