[ARM] 4292/1: ns9xxx: Make REGGET consistant with REGSET
authorUwe Kleine-König <ukleinek@informatik.uni-freiburg.de>
Wed, 28 Mar 2007 16:18:30 +0000 (17:18 +0100)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Sat, 21 Apr 2007 19:50:59 +0000 (20:50 +0100)
This implies that REGGET gets a new parameter "var" to allow to hold the actual
register value in a variable.

Moreover REGGET was broken because it used "field" instead of
"reg ## _ ## field" which proves that there are no callers to fix :-)

Signed-off-by: Uwe Kleine-König <ukleinek@informatik.uni-freiburg.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
include/asm-arm/arch-ns9xxx/hardware.h

index 6819da7c48d479cc79c8ea26bc632a6eab7f8205..25600554c4fe7df1d1d3b293a27133a5256ac185 100644 (file)
@@ -51,8 +51,9 @@
                       ~(__REGVAL(reg ## _ ## field, value))))          \
                  | (__REGVAL(reg ## _ ## field, value))))
 
-#  define REGGET(reg, field)                                           \
-       ((reg & (reg ## _ ## field)) / (field & (-field)))
+#  define REGGET(var, reg, field)                                      \
+       ((var & (reg ## _ ## field)) /                                  \
+        ((reg ## _ ## field) & (-(reg ## _ ## field))))
 
 #else