Skip to content

Commit bb25e86

Browse files
author
Deepika
committed
Reverted 4 CMSIS/RTX commits for Assembly files
1. Revert "CMSIS/RTX: __FPU_USED to be set based on HW FPU support" This reverts commit b4f5bed7e75c21927c954a50d40422b81a1de5a0. 2. Revert "CMSIS/RTX: Update Armv8M IAR 8.x assembly files - add END" This reverts commit b228cd9. 3. Revert "CMSIS/RTX: Pre-processor defines used for assembly" This reverts commit 287121f. 4. Revert "CMSIS/RTX: Patch RTX so irq_cm4f.s files work with no FPU targets" This reverts commit cc2e051.
1 parent 8f48104 commit bb25e86

File tree

9 files changed

+16
-39
lines changed

9 files changed

+16
-39
lines changed

rtos/TARGET_CORTEX/rtx5/RTX/Source/TOOLCHAIN_ARM/TARGET_M23/irq_armv8mbl.S

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@
2424
; */
2525

2626

27-
#ifndef DOMAIN_NS
28-
DOMAIN_NS EQU 0
29-
#endif
27+
IF :LNOT::DEF:DOMAIN_NS
28+
DOMAIN_NS EQU 0
29+
ENDIF
3030

3131
I_T_RUN_OFS EQU 20 ; osRtxInfo.thread.run offset
3232
TCB_SM_OFS EQU 48 ; TCB.stack_mem offset

rtos/TARGET_CORTEX/rtx5/RTX/Source/TOOLCHAIN_ARM/TARGET_M33/irq_armv8mml.S

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,15 @@
2424
; */
2525

2626

27-
#ifndef DOMAIN_NS
28-
DOMAIN_NS EQU 0
29-
#endif
27+
IF :LNOT::DEF:DOMAIN_NS
28+
DOMAIN_NS EQU 0
29+
ENDIF
3030

31-
#ifndef __FPU_USED
31+
IF ({FPU}="FPv5-SP") || ({FPU}="FPv5_D16")
32+
__FPU_USED EQU 1
33+
ELSE
3234
__FPU_USED EQU 0
33-
#endif
35+
ENDIF
3436

3537
I_T_RUN_OFS EQU 20 ; osRtxInfo.thread.run offset
3638
TCB_SM_OFS EQU 48 ; TCB.stack_mem offset

rtos/TARGET_CORTEX/rtx5/RTX/Source/TOOLCHAIN_ARM/TARGET_RTOS_M4_M7/irq_cm4f.S

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -74,22 +74,17 @@ SVC_Context
7474
CBNZ R1,SVC_ContextSave ; Branch if running thread is not deleted
7575
TST LR,#0x10 ; Check if extended stack frame
7676
BNE SVC_ContextSwitch
77-
#ifdef __FPU_PRESENT
7877
LDR R1,=0xE000EF34 ; FPCCR Address
7978
LDR R0,[R1] ; Load FPCCR
8079
BIC R0,R0,#1 ; Clear LSPACT (Lazy state)
8180
STR R0,[R1] ; Store FPCCR
8281
B SVC_ContextSwitch
83-
#endif
8482

8583
SVC_ContextSave
8684
STMDB R12!,{R4-R11} ; Save R4..R11
87-
#ifdef __FPU_PRESENT
8885
TST LR,#0x10 ; Check if extended stack frame
8986
IT EQ
9087
VSTMDBEQ R12!,{S16-S31} ; Save VFP S16.S31
91-
#endif
92-
9388
STR R12,[R1,#TCB_SP_OFS] ; Store SP
9489
STRB LR, [R1,#TCB_SF_OFS] ; Store stack frame information
9590

@@ -108,11 +103,9 @@ SVC_ContextRestore
108103
LDR R0,[R2,#TCB_SP_OFS] ; Load SP
109104
ORR LR,R1,#0xFFFFFF00 ; Set EXC_RETURN
110105

111-
#ifdef __FPU_PRESENT
112106
TST LR,#0x10 ; Check if extended stack frame
113107
IT EQ
114108
VLDMIAEQ R0!,{S16-S31} ; Restore VFP S16..S31
115-
#endif
116109
LDMIA R0!,{R4-R11} ; Restore R4..R11
117110
MSR PSP,R0 ; Set PSP
118111

rtos/TARGET_CORTEX/rtx5/RTX/Source/TOOLCHAIN_GCC/TARGET_M23/irq_armv8mbl.S

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,9 @@
2727
.file "irq_armv8mbl.S"
2828
.syntax unified
2929

30-
#ifndef DOMAIN_NS
30+
.ifndef DOMAIN_NS
3131
.equ DOMAIN_NS, 0
32-
#endif
32+
.endif
3333

3434
.equ I_T_RUN_OFS, 20 // osRtxInfo.thread.run offset
3535
.equ TCB_SM_OFS, 48 // TCB.stack_mem offset

rtos/TARGET_CORTEX/rtx5/RTX/Source/TOOLCHAIN_GCC/TARGET_M33/irq_armv8mml.S

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@
2727
.file "irq_armv8mml.S"
2828
.syntax unified
2929

30-
#ifndef DOMAIN_NS
30+
.ifndef DOMAIN_NS
3131
.equ DOMAIN_NS, 0
32-
#endif
32+
.endif
3333

34-
#ifndef __FPU_USED
34+
.ifndef __FPU_USED
3535
.equ __FPU_USED, 0
36-
#endif
36+
.endif
3737

3838
.equ I_T_RUN_OFS, 20 // osRtxInfo.thread.run offset
3939
.equ TCB_SM_OFS, 48 // TCB.stack_mem offset

rtos/TARGET_CORTEX/rtx5/RTX/Source/TOOLCHAIN_GCC/TARGET_RTOS_M4_M7/irq_cm4f.S

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -74,22 +74,17 @@ SVC_Context:
7474
CBNZ R1,SVC_ContextSave // Branch if running thread is not deleted
7575
TST LR,#0x10 // Check if extended stack frame
7676
BNE SVC_ContextSwitch
77-
#ifdef __FPU_PRESENT
7877
LDR R1,=0xE000EF34 // FPCCR Address
7978
LDR R0,[R1] // Load FPCCR
8079
BIC R0,R0,#1 // Clear LSPACT (Lazy state)
8180
STR R0,[R1] // Store FPCCR
8281
B SVC_ContextSwitch
83-
#endif
8482

8583
SVC_ContextSave:
8684
STMDB R12!,{R4-R11} // Save R4..R11
87-
#ifdef __FPU_PRESENT
8885
TST LR,#0x10 // Check if extended stack frame
8986
IT EQ
9087
VSTMDBEQ R12!,{S16-S31} // Save VFP S16.S31
91-
#endif
92-
9388
STR R12,[R1,#TCB_SP_OFS] // Store SP
9489
STRB LR, [R1,#TCB_SF_OFS] // Store stack frame information
9590

@@ -101,11 +96,9 @@ SVC_ContextRestore:
10196
LDR R0,[R2,#TCB_SP_OFS] // Load SP
10297
ORR LR,R1,#0xFFFFFF00 // Set EXC_RETURN
10398

104-
#ifdef __FPU_PRESENT
10599
TST LR,#0x10 // Check if extended stack frame
106100
IT EQ
107101
VLDMIAEQ R0!,{S16-S31} // Restore VFP S16..S31
108-
#endif
109102
LDMIA R0!,{R4-R11} // Restore R4..R11
110103
MSR PSP,R0 // Set PSP
111104

rtos/TARGET_CORTEX/rtx5/RTX/Source/TOOLCHAIN_IAR/TARGET_M23/irq_armv8mbl_common.S

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -297,5 +297,3 @@ Sys_ContextRestore2
297297

298298
Sys_ContextExit
299299
BX LR ; Exit from handler
300-
301-
END

rtos/TARGET_CORTEX/rtx5/RTX/Source/TOOLCHAIN_IAR/TARGET_M33/irq_armv8mml_common.S

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -270,5 +270,3 @@ Sys_ContextRestore2
270270

271271
Sys_ContextExit
272272
BX LR ; Exit from handler
273-
274-
END

rtos/TARGET_CORTEX/rtx5/RTX/Source/TOOLCHAIN_IAR/TARGET_RTOS_M4_M7/irq_cm4f.S

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -74,22 +74,17 @@ SVC_Context
7474
CBNZ R1,SVC_ContextSave ; Branch if running thread is not deleted
7575
TST LR,#0x10 ; Check if extended stack frame
7676
BNE SVC_ContextSwitch
77-
#ifdef __FPU_PRESENT
7877
LDR R1,=0xE000EF34 ; FPCCR Address
7978
LDR R0,[R1] ; Load FPCCR
8079
BIC R0,R0,#1 ; Clear LSPACT (Lazy state)
8180
STR R0,[R1] ; Store FPCCR
8281
B SVC_ContextSwitch
83-
#endif
8482

8583
SVC_ContextSave
8684
STMDB R12!,{R4-R11} ; Save R4..R11
87-
#ifdef __FPU_PRESENT
8885
TST LR,#0x10 ; Check if extended stack frame
8986
IT EQ
9087
VSTMDBEQ R12!,{S16-S31} ; Save VFP S16.S31
91-
#endif
92-
9388
STR R12,[R1,#TCB_SP_OFS] ; Store SP
9489
STRB LR, [R1,#TCB_SF_OFS] ; Store stack frame information
9590

@@ -101,11 +96,9 @@ SVC_ContextRestore
10196
LDR R0,[R2,#TCB_SP_OFS] ; Load SP
10297
ORR LR,R1,#0xFFFFFF00 ; Set EXC_RETURN
10398

104-
#ifdef __FPU_PRESENT
10599
TST LR,#0x10 ; Check if extended stack frame
106100
IT EQ
107101
VLDMIAEQ R0!,{S16-S31} ; Restore VFP S16..S31
108-
#endif
109102
LDMIA R0!,{R4-R11} ; Restore R4..R11
110103
MSR PSP,R0 ; Set PSP
111104

0 commit comments

Comments
 (0)