Skip to content

Commit c38427e

Browse files
authored
Fix function parameter shadowing global variable. (#1221)
The function vApplicationFPUSafeIRQHandler gets the value of ICCIAR as parameter, but a constant containing the address of ICCIAR was also defined. Fix the name of the constant to align it with what it actually holds.
1 parent 3a7b308 commit c38427e

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

portable/GCC/ARM_CA9/port.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -208,9 +208,9 @@ volatile uint32_t ulPortYieldRequired = pdFALSE;
208208
volatile uint32_t ulPortInterruptNesting = 0UL;
209209

210210
/* Used in the asm file. */
211-
__attribute__( ( used ) ) const uint32_t ulICCIAR = portICCIAR_INTERRUPT_ACKNOWLEDGE_REGISTER_ADDRESS;
212-
__attribute__( ( used ) ) const uint32_t ulICCEOIR = portICCEOIR_END_OF_INTERRUPT_REGISTER_ADDRESS;
213-
__attribute__( ( used ) ) const uint32_t ulICCPMR = portICCPMR_PRIORITY_MASK_REGISTER_ADDRESS;
211+
__attribute__( ( used ) ) const uint32_t ulICCIARAddress = portICCIAR_INTERRUPT_ACKNOWLEDGE_REGISTER_ADDRESS;
212+
__attribute__( ( used ) ) const uint32_t ulICCEOIRAddress = portICCEOIR_END_OF_INTERRUPT_REGISTER_ADDRESS;
213+
__attribute__( ( used ) ) const uint32_t ulICCPMRAddress = portICCPMR_PRIORITY_MASK_REGISTER_ADDRESS;
214214
__attribute__( ( used ) ) const uint32_t ulMaxAPIPriorityMask = ( configMAX_API_CALL_INTERRUPT_PRIORITY << portPRIORITY_SHIFT );
215215

216216
/*-----------------------------------------------------------*/

portable/GCC/ARM_CA9/portASM.S

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,10 +33,10 @@
3333
.set SVC_MODE, 0x13
3434
.set IRQ_MODE, 0x12
3535

36-
/* Hardware registers. */
37-
.extern ulICCIAR
38-
.extern ulICCEOIR
39-
.extern ulICCPMR
36+
/* Hardware registers addresses. */
37+
.extern ulICCIARAddress
38+
.extern ulICCEOIRAddress
39+
.extern ulICCPMRAddress
4040

4141
/* Variables and functions. */
4242
.extern ulMaxAPIPriorityMask
@@ -317,9 +317,9 @@ vApplicationIRQHandler:
317317
POP {PC}
318318

319319

320-
ulICCIARConst: .word ulICCIAR
321-
ulICCEOIRConst: .word ulICCEOIR
322-
ulICCPMRConst: .word ulICCPMR
320+
ulICCIARConst: .word ulICCIARAddress
321+
ulICCEOIRConst: .word ulICCEOIRAddress
322+
ulICCPMRConst: .word ulICCPMRAddress
323323
pxCurrentTCBConst: .word pxCurrentTCB
324324
ulCriticalNestingConst: .word ulCriticalNesting
325325
ulPortTaskHasFPUContextConst: .word ulPortTaskHasFPUContext

0 commit comments

Comments
 (0)