summaryrefslogtreecommitdiffstats
path: root/arch/powerpc
diff options
context:
space:
mode:
authorTony Breeds2011-11-30 22:39:22 +0100
committerJosh Boyer2011-12-09 13:49:50 +0100
commit075bcf5879225d0c2a119c23d8046b890e051e81 (patch)
treef6b3bb02bd859cd1ff7d8603296079e011ed5033 /arch/powerpc
parentpowerpc/boot: Add extended precision shifts to the boot wrapper. (diff)
downloadkernel-qcow2-linux-075bcf5879225d0c2a119c23d8046b890e051e81.tar.gz
kernel-qcow2-linux-075bcf5879225d0c2a119c23d8046b890e051e81.tar.xz
kernel-qcow2-linux-075bcf5879225d0c2a119c23d8046b890e051e81.zip
powerpc/boot: Add mfdcrx
Needed for currituck support. Signed-off-by: Tony Breeds <tony@bakeyournoodle.com> Signed-off-by: Josh Boyer <jwboyer@gmail.com>
Diffstat (limited to 'arch/powerpc')
-rw-r--r--arch/powerpc/boot/dcr.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/arch/powerpc/boot/dcr.h b/arch/powerpc/boot/dcr.h
index 645a7c964e5f..cc73f7a95e26 100644
--- a/arch/powerpc/boot/dcr.h
+++ b/arch/powerpc/boot/dcr.h
@@ -9,6 +9,12 @@
})
#define mtdcr(rn, val) \
asm volatile("mtdcr %0,%1" : : "i"(rn), "r"(val))
+#define mfdcrx(rn) \
+ ({ \
+ unsigned long rval; \
+ asm volatile("mfdcrx %0,%1" : "=r"(rval) : "r"(rn)); \
+ rval; \
+ })
/* 440GP/440GX SDRAM controller DCRs */
#define DCRN_SDRAM0_CFGADDR 0x010