diff options
Diffstat (limited to '')
7 files changed, 114 insertions, 39 deletions
diff --git a/c/src/exec/score/cpu/powerpc/Makefile.am b/c/src/exec/score/cpu/powerpc/Makefile.am index db1cf0888a..cbddc2bca7 100644 --- a/c/src/exec/score/cpu/powerpc/Makefile.am +++ b/c/src/exec/score/cpu/powerpc/Makefile.am @@ -1,6 +1,6 @@ -## +## ## $Id$ -## +## AUTOMAKE_OPTIONS = foreign 1.4 ACLOCAL_AMFLAGS = -I $(RTEMS_TOPdir)/aclocal diff --git a/c/src/exec/score/cpu/powerpc/new_exception_processing/Makefile.am b/c/src/exec/score/cpu/powerpc/new_exception_processing/Makefile.am index c3195b159d..1f4affe8f4 100644 --- a/c/src/exec/score/cpu/powerpc/new_exception_processing/Makefile.am +++ b/c/src/exec/score/cpu/powerpc/new_exception_processing/Makefile.am @@ -9,7 +9,7 @@ C_O_FILES = $(C_FILES:%.c=${ARCH}/%.o) ROOT_H_FILES = RTEMS_SCORE_H_FILES = cpu.h c_isr.inl -noinst_HEADERS = $(ROOT_H_FILES) $(RTEMS_SCORE_H_FILES) +noinst_HEADERS = $(ROOT_H_FILES) $(RTEMS_SCORE_H_FILES) S_FILES = cpu_asm.S S_O_FILES = $(S_FILES:%.S=${ARCH}/%.o) @@ -21,11 +21,9 @@ include $(top_srcdir)/../../../../../../automake/lib.am # (OPTIONAL) Add local stuff here using += # -PREINSTALL_FILES = \ -$(PROJECT_INCLUDE) \ -$(PROJECT_INCLUDE)/rtems/score \ -$(ROOT_H_FILES:%=$(PROJECT_INCLUDE)/%) \ -$(RTEMS_SCORE_H_FILES:%=$(PROJECT_INCLUDE)/rtems/score/%) +PREINSTALL_FILES += $(PROJECT_INCLUDE) $(PROJECT_INCLUDE)/rtems/score \ + $(ROOT_H_FILES:%=$(PROJECT_INCLUDE)/%) \ + $(RTEMS_SCORE_H_FILES:%=$(PROJECT_INCLUDE)/rtems/score/%) ##TMPINSTALL_FILES += \ ##$(PROJECT_RELEASE)/lib/rtems$(LIB_VARIANT).o @@ -55,10 +53,8 @@ all-local: $(ARCH) $(PREINSTALL_FILES) $(REL) ## all-local: $(ARCH)/rtems.o all-local: $(TMPINSTALL_FILES) -clean-local: - $(RM) -r ../o-optimize ../o-debug ../o-profile +CLEANDIRS = ../o-optimize ../o-debug ../o-profile -EXTRA_DIST = \ -$(C_FILES) $(S_FILES) +EXTRA_DIST = $(C_FILES) $(S_FILES) include $(top_srcdir)/../../../../../../automake/local.am diff --git a/c/src/exec/score/cpu/powerpc/old_exception_processing/Makefile.am b/c/src/exec/score/cpu/powerpc/old_exception_processing/Makefile.am index afd66502eb..9629808140 100644 --- a/c/src/exec/score/cpu/powerpc/old_exception_processing/Makefile.am +++ b/c/src/exec/score/cpu/powerpc/old_exception_processing/Makefile.am @@ -19,14 +19,11 @@ S_O_FILES = $(S_FILES:%.S=${ARCH}/%.o) include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg include $(top_srcdir)/../../../../../../automake/lib.am -PREINSTALL_FILES = \ -$(PROJECT_INCLUDE) \ -$(PROJECT_INCLUDE)/rtems/score \ -$(ROOT_H_FILES:%=$(PROJECT_INCLUDE)/%) \ -$(RTEMS_SCORE_H_FILES:%=$(PROJECT_INCLUDE)/rtems/score/%) +PREINSTALL_FILES += $(PROJECT_INCLUDE) $(PROJECT_INCLUDE)/rtems/score \ + $(ROOT_H_FILES:%=$(PROJECT_INCLUDE)/%) \ + $(RTEMS_SCORE_H_FILES:%=$(PROJECT_INCLUDE)/rtems/score/%) -TMPINSTALL_FILES += \ -$(PROJECT_RELEASE)/lib/rtems$(LIB_VARIANT).o +TMPINSTALL_FILES += $(PROJECT_RELEASE)/lib/rtems$(LIB_VARIANT).o $(PROJECT_RELEASE)/lib/rtems$(LIB_VARIANT).o: $(ARCH)/rtems.o $(INSTALL_DATA) $< $@ @@ -49,18 +46,12 @@ $(REL): $(C_O_FILES) $(S_O_FILES) test -d ../$(ARCH) || mkdir ../$(ARCH) $(make-rel) -all-local: $(ARCH) $(PREINSTALL_FILES) $(REL) -all-local: $(ARCH)/rtems.o -all-local: $(TMPINSTALL_FILES) +all-local: $(ARCH) $(PREINSTALL_FILES) $(REL) $(ARCH)/rtems.o $(TMPINSTALL_FILES) -clean-local: - $(RM) -r ../o-optimize ../o-debug ../o-profile +CLEANDIRS = ../o-optimize ../o-debug ../o-profile UNUSED_FILES = irq_stub.S -EXTRA_DIST = \ -TODO \ -rtems.S \ -$(C_FILES) $(S_FILES) $(UNUSED_FILES) +EXTRA_DIST = TODO rtems.S $(C_FILES) $(S_FILES) $(UNUSED_FILES) include $(top_srcdir)/../../../../../../automake/local.am diff --git a/c/src/exec/score/cpu/powerpc/old_exception_processing/irq_stub.S b/c/src/exec/score/cpu/powerpc/old_exception_processing/irq_stub.S index 76c8927305..400cccdf73 100644 --- a/c/src/exec/score/cpu/powerpc/old_exception_processing/irq_stub.S +++ b/c/src/exec/score/cpu/powerpc/old_exception_processing/irq_stub.S @@ -55,7 +55,9 @@ lis r11,_CPU_IRQ_info@ha addi r11,r11,_CPU_IRQ_info@l #endif +#if ( PPC_USE_DATA_CACHE ) dcbt r0, r11 +#endif stw r5, IP_CR(r1) stw r6, IP_CTR(r1) stw r7, IP_XER(r1) diff --git a/c/src/exec/score/cpu/powerpc/rtems/score/ppc.h b/c/src/exec/score/cpu/powerpc/rtems/score/ppc.h index ff93f9b1b3..83a54bfa25 100644 --- a/c/src/exec/score/cpu/powerpc/rtems/score/ppc.h +++ b/c/src/exec/score/cpu/powerpc/rtems/score/ppc.h @@ -94,7 +94,28 @@ extern "C" { #define PPC_LOW_POWER_MODE_NONE 0 #define PPC_LOW_POWER_MODE_STANDARD 1 -#if defined(ppc403) +#if defined(rtems_multilib) +/* + * Figure out all CPU Model Feature Flags based upon compiler + * predefines. + */ + +#define CPU_MODEL_NAME "rtems_multilib" +#define PPC_ALIGNMENT 4 +#define PPC_CACHE_ALIGNMENT 16 +#define PPC_HAS_RFCI 1 +#define PPC_HAS_FPU 0 +#define PPC_USE_MULTIPLE 1 +#define PPC_I_CACHE 2048 +#define PPC_D_CACHE 1024 +#define PPC_DEBUG_MODEL PPC_DEBUG_MODEL_STANDARD +#define PPC_HAS_EXCEPTION_PREFIX 0 +#define PPC_HAS_EVPR 0 +#define PPC_INTERRUPT_MAX 16 +#define PPC_LOW_POWER_MODE PPC_LOW_POWER_MODE_STANDARD +#define PPC_HAS_DOUBLE 0 + +#elif defined(ppc403) /* * IBM 403 * @@ -129,7 +150,7 @@ extern "C" { #define PPC_ALIGNMENT 4 #define PPC_CACHE_ALIGNMENT 16 #define PPC_I_CACHE 4096 -#define PPC_I_CACHE 0 +#define PPC_D_CACHE 0 #elif defined(ppc601) @@ -281,6 +302,14 @@ extern "C" { */ #define PPC_ABI_EABI 3 +/* + * Default to the EABI used by current GNU tools + */ + +#ifndef PPC_ABI +#define PPC_ABI PPC_ABI_EABI +#endif + #if (PPC_ABI == PPC_ABI_POWEROPEN) #define PPC_STACK_ALIGNMENT 8 #elif (PPC_ABI == PPC_ABI_GCC27) @@ -310,6 +339,14 @@ extern "C" { #define PPC_ASM_XCOFF 1 /* + * Default to the assembler format used by the current GNU tools. + */ + +#ifndef PPC_ASM +#define PPC_ASM PPC_ASM_ELF +#endif + +/* * Use the default debug scheme defined in the architectural specification * if another model has not been specified. */ @@ -449,7 +486,14 @@ extern "C" { #define PPC_IRQ_FIT (PPC_STD_IRQ_LAST+2) /*0x01010- Fixed int. timer */ #define PPC_IRQ_WATCHDOG (PPC_STD_IRQ_LAST+3) /*0x01020- Watchdog timer */ #define PPC_IRQ_DEBUG (PPC_STD_IRQ_LAST+4) /*0x02000- Debug exceptions */ -#define PPC_IRQ_LAST PPC_IRQ_DEBUG +#define PPC_IRQ_LAST PPC_IRQ_DEBUG + +#elif defined(mpc505) || defined(mpc509) +#define PPC_IRQ_SOFTEMU (PPC_STD_IRQ_LAST+1) /* Software emulation. */ +#define PPC_IRQ_DATA_BP (PPC_STD_IRQ_LAST+ 2) +#define PPC_IRQ_INST_BP (PPC_STD_IRQ_LAST+ 3) +#define PPC_IRQ_MEXT_BP (PPC_STD_IRQ_LAST+ 4) +#define PPC_IRQ_NMEXT_BP (PPC_STD_IRQ_LAST+ 5) #elif defined(ppc601) #define PPC_IRQ_TRACE (PPC_STD_IRQ_LAST+1) /*0x02000-Run/Trace Exception*/ diff --git a/c/src/exec/score/cpu/powerpc/shared/Makefile.am b/c/src/exec/score/cpu/powerpc/shared/Makefile.am index a2d0fb5f96..7aae87d8d3 100644 --- a/c/src/exec/score/cpu/powerpc/shared/Makefile.am +++ b/c/src/exec/score/cpu/powerpc/shared/Makefile.am @@ -12,11 +12,9 @@ noinst_HEADERS = $(ROOT_H_FILES) $(RTEMS_SCORE_H_FILES) # (OPTIONAL) Add local stuff here using += # -PREINSTALL_FILES = \ -$(PROJECT_INCLUDE) \ -$(PROJECT_INCLUDE)/rtems/score \ -$(ROOT_H_FILES:%.h=$(PROJECT_INCLUDE)/%.h) \ -$(RTEMS_SCORE_H_FILES:%.h=$(PROJECT_INCLUDE)/rtems/score/%.h) +PREINSTALL_FILES += $(PROJECT_INCLUDE) $(PROJECT_INCLUDE)/rtems/score \ + $(ROOT_H_FILES:%.h=$(PROJECT_INCLUDE)/%.h) \ + $(RTEMS_SCORE_H_FILES:%.h=$(PROJECT_INCLUDE)/rtems/score/%.h) $(PROJECT_INCLUDE): $(mkinstalldirs) $@ diff --git a/c/src/exec/score/cpu/powerpc/shared/ppc.h b/c/src/exec/score/cpu/powerpc/shared/ppc.h index ff93f9b1b3..83a54bfa25 100644 --- a/c/src/exec/score/cpu/powerpc/shared/ppc.h +++ b/c/src/exec/score/cpu/powerpc/shared/ppc.h @@ -94,7 +94,28 @@ extern "C" { #define PPC_LOW_POWER_MODE_NONE 0 #define PPC_LOW_POWER_MODE_STANDARD 1 -#if defined(ppc403) +#if defined(rtems_multilib) +/* + * Figure out all CPU Model Feature Flags based upon compiler + * predefines. + */ + +#define CPU_MODEL_NAME "rtems_multilib" +#define PPC_ALIGNMENT 4 +#define PPC_CACHE_ALIGNMENT 16 +#define PPC_HAS_RFCI 1 +#define PPC_HAS_FPU 0 +#define PPC_USE_MULTIPLE 1 +#define PPC_I_CACHE 2048 +#define PPC_D_CACHE 1024 +#define PPC_DEBUG_MODEL PPC_DEBUG_MODEL_STANDARD +#define PPC_HAS_EXCEPTION_PREFIX 0 +#define PPC_HAS_EVPR 0 +#define PPC_INTERRUPT_MAX 16 +#define PPC_LOW_POWER_MODE PPC_LOW_POWER_MODE_STANDARD +#define PPC_HAS_DOUBLE 0 + +#elif defined(ppc403) /* * IBM 403 * @@ -129,7 +150,7 @@ extern "C" { #define PPC_ALIGNMENT 4 #define PPC_CACHE_ALIGNMENT 16 #define PPC_I_CACHE 4096 -#define PPC_I_CACHE 0 +#define PPC_D_CACHE 0 #elif defined(ppc601) @@ -281,6 +302,14 @@ extern "C" { */ #define PPC_ABI_EABI 3 +/* + * Default to the EABI used by current GNU tools + */ + +#ifndef PPC_ABI +#define PPC_ABI PPC_ABI_EABI +#endif + #if (PPC_ABI == PPC_ABI_POWEROPEN) #define PPC_STACK_ALIGNMENT 8 #elif (PPC_ABI == PPC_ABI_GCC27) @@ -310,6 +339,14 @@ extern "C" { #define PPC_ASM_XCOFF 1 /* + * Default to the assembler format used by the current GNU tools. + */ + +#ifndef PPC_ASM +#define PPC_ASM PPC_ASM_ELF +#endif + +/* * Use the default debug scheme defined in the architectural specification * if another model has not been specified. */ @@ -449,7 +486,14 @@ extern "C" { #define PPC_IRQ_FIT (PPC_STD_IRQ_LAST+2) /*0x01010- Fixed int. timer */ #define PPC_IRQ_WATCHDOG (PPC_STD_IRQ_LAST+3) /*0x01020- Watchdog timer */ #define PPC_IRQ_DEBUG (PPC_STD_IRQ_LAST+4) /*0x02000- Debug exceptions */ -#define PPC_IRQ_LAST PPC_IRQ_DEBUG +#define PPC_IRQ_LAST PPC_IRQ_DEBUG + +#elif defined(mpc505) || defined(mpc509) +#define PPC_IRQ_SOFTEMU (PPC_STD_IRQ_LAST+1) /* Software emulation. */ +#define PPC_IRQ_DATA_BP (PPC_STD_IRQ_LAST+ 2) +#define PPC_IRQ_INST_BP (PPC_STD_IRQ_LAST+ 3) +#define PPC_IRQ_MEXT_BP (PPC_STD_IRQ_LAST+ 4) +#define PPC_IRQ_NMEXT_BP (PPC_STD_IRQ_LAST+ 5) #elif defined(ppc601) #define PPC_IRQ_TRACE (PPC_STD_IRQ_LAST+1) /*0x02000-Run/Trace Exception*/ |