]> git.baikalelectronics.ru Git - kernel.git/commit
[PATCH] AVR32: Fix oversize immediates in atomic.h
authorHaavard Skinnemoen <hskinnemoen@atmel.com>
Tue, 24 Oct 2006 08:12:42 +0000 (10:12 +0200)
committerLinus Torvalds <torvalds@g5.osdl.org>
Thu, 26 Oct 2006 03:26:33 +0000 (20:26 -0700)
commit6d7648b6680605ad573f979e903aa8c74b74303d
treec4ddfb52859c9c304404ad010d927ed76a46f9a0
parentda3ac83d3fecb96d498bd2e43bb6ee5231b0483e
[PATCH] AVR32: Fix oversize immediates in atomic.h

When calling e.g. atomic_sub_return with a large constant, the
compiler may output an immediate that is too large for the sub
instruction in the middle of the loop.

Fix this by explicitly specifying the number of bits allowed in the
constraint. Also stop atomic_add_return() and friends from falling
back to their respective "sub" variants if the constant is too large
to fit in an immediate.

Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
include/asm-avr32/atomic.h