powerpc/4xx: Extended DCR support v2
This adds supports to the "extended" DCR addressing via the indirect mfdcrx/mtdcrx instructions supported by some 4xx cores (440H6 and later). I enabled the feature for now only on AMCC 460 chips. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Acked-by: Josh Boyer <jwboyer@linux.vnet.ibm.com> Acked-by: Kumar Gala <galak@kernel.crashing.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
This commit is contained in:
committed by
Paul Mackerras
parent
fecba96268
commit
6d2170be45
@ -11,14 +11,20 @@
|
||||
|
||||
#include <asm/ppc_asm.h>
|
||||
#include <asm/processor.h>
|
||||
#include <asm/bug.h>
|
||||
|
||||
#define DCR_ACCESS_PROLOG(table) \
|
||||
cmpli cr0,r3,1024; \
|
||||
rlwinm r3,r3,4,18,27; \
|
||||
lis r5,table@h; \
|
||||
ori r5,r5,table@l; \
|
||||
add r3,r3,r5; \
|
||||
bge- 1f; \
|
||||
mtctr r3; \
|
||||
bctr
|
||||
bctr; \
|
||||
1: trap; \
|
||||
EMIT_BUG_ENTRY 1b,__FILE__,__LINE__,0; \
|
||||
blr
|
||||
|
||||
_GLOBAL(__mfdcr)
|
||||
DCR_ACCESS_PROLOG(__mfdcr_table)
|
||||
|
Reference in New Issue
Block a user