Skip to content

Commit 6af9393

Browse files
authored
fix(CMSIS): Remove WUT1 from MAX32655 source files (#1584)
Signed-off-by: dnguye14-adi <dung.nguyen@analog.com>
1 parent 51753b2 commit 6af9393

4 files changed

Lines changed: 15 additions & 20 deletions

File tree

Libraries/CMSIS/Device/Maxim/MAX32655/Include/max32655.h

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
*
33
* Copyright (C) 2022-2023 Maxim Integrated Products, Inc. (now owned by
44
* Analog Devices, Inc.),
5-
* Copyright (C) 2023-2024 Analog Devices, Inc.
5+
* Copyright (C) 2023-2026 Analog Devices, Inc.
66
*
77
* Licensed under the Apache License, Version 2.0 (the "License");
88
* you may not use this file except in compliance with the License.
@@ -177,7 +177,6 @@ typedef enum {
177177
RSV122_IRQn, /* 0x7A 0x01E8 122: Reserved */
178178
RSV123_IRQn, /* 0x7B 0x01EC 123: Reserved */
179179
RSV124_IRQn, /* 0x7C 0x01F0 124: Reserved */
180-
WUT1_IRQn, /* 0x7D 0x01F4 125: ERFO Ready/WUT 1 */
181180
#else // __riscv
182181
PF_IRQn = 4, /* 0x04,4 PFW | SYSFAULT | CM4 */
183182
WDT0_IRQn, /* 0x05,5 Watchdog 0 */
@@ -227,7 +226,7 @@ typedef enum {
227226
WDT1_IRQn, /* 0x30,48 Watchdog 1 (LP) */
228227
DVS_IRQn, /* 0x31,49 DVS Controller */
229228
SIMO_IRQn, /* 0x32,50 SIMO Controller */
230-
WUT1_IRQn, /* 0x33,51 ERFO Ready/WUT1 */
229+
RSV51_IRQn, /* 0x33,51 Reserved */
231230
PT_IRQn, /* 0x34,52 Pulse train */
232231
ADC_IRQn, /* 0x35,53 ADC */
233232
OWM_IRQn, /* 0x36,54 One Wire Master */
@@ -334,13 +333,11 @@ typedef enum {
334333

335334
/******************************************************************************/
336335
/* Wake-Up Timer (WUT) */
337-
#define MXC_CFG_WUT_INSTANCES (2)
336+
#define MXC_CFG_WUT_INSTANCES (1)
338337

339338
#define MXC_BASE_WUT0 ((uint32_t)0x40006400UL)
340339
#define MXC_WUT0 ((mxc_wut_regs_t *)MXC_BASE_WUT0)
341340
#define MXC_WUT MXC_WUT0
342-
#define MXC_BASE_WUT1 ((uint32_t)0x40006600UL)
343-
#define MXC_WUT1 ((mxc_wut_regs_t *)MXC_BASE_WUT1)
344341

345342
// Included for legacy compatability after changing WUT_IRQn -> WUT0_IRQn
346343
// in system startup files.

Libraries/CMSIS/Device/Maxim/MAX32655/Source/GCC/startup_max32655.S

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
*
33
* Copyright (C) 2022-2023 Maxim Integrated Products, Inc. (now owned by
44
* Analog Devices, Inc.),
5-
* Copyright (C) 2023-2024 Analog Devices, Inc.
5+
* Copyright (C) 2023-2026 Analog Devices, Inc.
66
*
77
* Licensed under the Apache License, Version 2.0 (the "License");
88
* you may not use this file except in compliance with the License.
@@ -237,8 +237,7 @@ __isr_vector:
237237
.long RSV121_IRQHandler /* 0x79 0x01E4 121: Reserved */
238238
.long RSV122_IRQHandler /* 0x7A 0x01E8 122: Reserved */
239239
.long RSV123_IRQHandler /* 0x7B 0x01EC 123: Reserved */
240-
.long RSV124_IRQHandler /* 0x7C 0x01F0 124: Reserved */
241-
.long WUT1_IRQHandler /* 0x7D 0x01F4 125: Wakeup Timer 1 */
240+
.long RSV124_IRQHandler /* 0x7C 0x01F0 124: Reserved */
242241
.text
243242
.thumb
244243
.thumb_func
@@ -457,6 +456,5 @@ Reset_Handler:
457456
def_irq_handler RSV121_IRQHandler /* 0x79 0x01E4 121: Reserved */
458457
def_irq_handler RSV122_IRQHandler /* 0x7A 0x01E8 122: Reserved */
459458
def_irq_handler RSV123_IRQHandler /* 0x7B 0x01EC 123: Reserved */
460-
def_irq_handler RSV124_IRQHandler /* 0x7C 0x01F0 124: Reserved */
461-
def_irq_handler WUT1_IRQHandler /* 0x7D 0x01F4 125: Wakeup Timer 1 */
459+
def_irq_handler RSV124_IRQHandler /* 0x7C 0x01F0 124: Reserved */
462460
.end

Libraries/CMSIS/Device/Maxim/MAX32655/Source/GCC/startup_riscv_max32655.S

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ __isr_vector:
147147
jal x0, WDT1_IRQHandlerWrap
148148
jal x0, DVS_IRQHandlerWrap
149149
jal x0, SIMO_IRQHandlerWrap
150-
jal x0, WUT1_IRQHandlerWrap
150+
jal x0, RSV51_IRQHandlerWrap
151151
jal x0, PT_IRQHandlerWrap
152152
jal x0, ADC_IRQHandlerWrap
153153
jal x0, OWM_IRQHandlerWrap
@@ -326,7 +326,7 @@ main_entry:
326326
def_irq_handler WDT1_IRQHandlerWrap
327327
def_irq_handler DVS_IRQHandlerWrap
328328
def_irq_handler SIMO_IRQHandlerWrap
329-
def_irq_handler WUT1_IRQHandlerWrap
329+
def_irq_handler RSV51_IRQHandlerWrap
330330
def_irq_handler PT_IRQHandlerWrap
331331
def_irq_handler ADC_IRQHandlerWrap
332332
def_irq_handler OWM_IRQHandlerWrap

Libraries/CMSIS/Device/Maxim/MAX32655/Source/system_riscv_max32655.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
*
33
* Copyright (C) 2022-2023 Maxim Integrated Products, Inc. (now owned by
44
* Analog Devices, Inc.),
5-
* Copyright (C) 2023-2025 Analog Devices, Inc.
5+
* Copyright (C) 2023-2026 Analog Devices, Inc.
66
*
77
* Licensed under the Apache License, Version 2.0 (the "License");
88
* you may not use this file except in compliance with the License.
@@ -97,7 +97,7 @@ void __attribute__((weak)) TRNG_IRQHandler(void) {}
9797
void __attribute__((weak)) WDT1_IRQHandler(void) {}
9898
void __attribute__((weak)) DVS_IRQHandler(void) {}
9999
void __attribute__((weak)) SIMO_IRQHandler(void) {}
100-
void __attribute__((weak)) WUT1_IRQHandler(void) {}
100+
void __attribute__((weak)) RSV51_IRQHandler(void) {}
101101
void __attribute__((weak)) PT_IRQHandler(void) {}
102102
void __attribute__((weak)) ADC_IRQHandler(void) {}
103103
void __attribute__((weak)) OWM_IRQHandler(void) {}
@@ -577,14 +577,14 @@ void __attribute__((interrupt("machine"))) SIMO_IRQHandlerWrap(void)
577577
NVIC_EnableIRQ(SIMO_IRQn);
578578
intContext = 0;
579579
}
580-
void __attribute__((interrupt("machine"))) WUT1_IRQHandlerWrap(void)
580+
void __attribute__((interrupt("machine"))) RSV51_IRQHandlerWrap(void)
581581
{
582582
intContext = 1;
583583

584-
NVIC_DisableIRQ(WUT1_IRQn);
585-
NVIC_ClearPendingIRQ(WUT1_IRQn);
586-
WUT1_IRQHandler();
587-
NVIC_EnableIRQ(WUT1_IRQn);
584+
NVIC_DisableIRQ(RSV51_IRQn);
585+
NVIC_ClearPendingIRQ(RSV51_IRQn);
586+
RSV51_IRQHandler();
587+
NVIC_EnableIRQ(RSV51_IRQn);
588588
intContext = 0;
589589
}
590590
void __attribute__((interrupt("machine"))) PT_IRQHandlerWrap(void)

0 commit comments

Comments
 (0)