Skip to content

Commit 542db6c

Browse files
d-katoadbridge
authored andcommitted
Fix missing mbed_get_a9_tick_irq in non-RTOS build
1 parent 0291651 commit 542db6c

File tree

3 files changed

+21
-31
lines changed

3 files changed

+21
-31
lines changed

targets/TARGET_RENESAS/TARGET_RZ_A1XX/TARGET_GR_LYCHEE/device/os_tick_ostm.c

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -22,28 +22,25 @@
2222
* limitations under the License.
2323
*/
2424

25-
#ifdef MBED_CONF_RTOS_PRESENT
26-
27-
#include "os_tick.h"
2825
#include "irq_ctrl.h"
2926
#include "cmsis.h"
3027
#include "mbed_drv_cfg.h"
3128

29+
// Define OS Timer channel and interrupt number
30+
#define OSTM (OSTM0)
31+
#define OSTM_IRQn ((IRQn_ID_t)OSTMI0TINT_IRQn)
32+
33+
#ifdef MBED_CONF_RTOS_PRESENT
34+
#include "os_tick.h"
3235

3336
// Define OS TImer interrupt priority
3437
#ifndef OSTM_IRQ_PRIORITY
3538
#define OSTM_IRQ_PRIORITY 0xFFU
3639
#endif
3740

38-
// Define OS Timer channel and interrupt number
39-
#define OSTM (OSTM0)
40-
#define OSTM_IRQn ((IRQn_ID_t)OSTMI0TINT_IRQn)
41-
42-
4341
static uint32_t OSTM_Clock; // Timer tick frequency
4442
static uint8_t OSTM_PendIRQ; // Timer interrupt pending flag
4543

46-
4744
// Setup OS Tick.
4845
int32_t OS_Tick_Setup (uint32_t freq, IRQHandler_t handler)
4946
{
@@ -190,10 +187,10 @@ uint32_t OS_Tick_GetOverflow (void)
190187
{
191188
return (IRQ_GetPending(OSTM_IRQn));
192189
}
190+
#endif
193191

194192
// Get Cortex-A9 OS Timer interrupt number
195193
IRQn_ID_t mbed_get_a9_tick_irqn(){
196194
return OSTM_IRQn;
197195
}
198-
#endif
199196

targets/TARGET_RENESAS/TARGET_RZ_A1XX/TARGET_RZ_A1H/device/os_tick_ostm.c

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -22,28 +22,25 @@
2222
* limitations under the License.
2323
*/
2424

25-
#ifdef MBED_CONF_RTOS_PRESENT
26-
27-
#include "os_tick.h"
2825
#include "irq_ctrl.h"
2926
#include "cmsis.h"
3027
#include "mbed_drv_cfg.h"
3128

29+
// Define OS Timer channel and interrupt number
30+
#define OSTM (OSTM0)
31+
#define OSTM_IRQn ((IRQn_ID_t)OSTMI0TINT_IRQn)
32+
33+
#ifdef MBED_CONF_RTOS_PRESENT
34+
#include "os_tick.h"
3235

3336
// Define OS TImer interrupt priority
3437
#ifndef OSTM_IRQ_PRIORITY
3538
#define OSTM_IRQ_PRIORITY 0xFFU
3639
#endif
3740

38-
// Define OS Timer channel and interrupt number
39-
#define OSTM (OSTM0)
40-
#define OSTM_IRQn ((IRQn_ID_t)OSTMI0TINT_IRQn)
41-
42-
4341
static uint32_t OSTM_Clock; // Timer tick frequency
4442
static uint8_t OSTM_PendIRQ; // Timer interrupt pending flag
4543

46-
4744
// Setup OS Tick.
4845
int32_t OS_Tick_Setup (uint32_t freq, IRQHandler_t handler)
4946
{
@@ -190,10 +187,10 @@ uint32_t OS_Tick_GetOverflow (void)
190187
{
191188
return (IRQ_GetPending(OSTM_IRQn));
192189
}
190+
#endif
193191

194192
// Get Cortex-A9 OS Timer interrupt number
195193
IRQn_ID_t mbed_get_a9_tick_irqn(){
196194
return OSTM_IRQn;
197195
}
198-
#endif
199196

targets/TARGET_RENESAS/TARGET_RZ_A1XX/TARGET_VK_RZ_A1H/device/os_tick_ostm.c

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -22,28 +22,25 @@
2222
* limitations under the License.
2323
*/
2424

25-
#ifdef MBED_CONF_RTOS_PRESENT
26-
27-
#include "os_tick.h"
2825
#include "irq_ctrl.h"
2926
#include "cmsis.h"
3027
#include "mbed_drv_cfg.h"
3128

29+
// Define OS Timer channel and interrupt number
30+
#define OSTM (OSTM0)
31+
#define OSTM_IRQn ((IRQn_ID_t)OSTMI0TINT_IRQn)
32+
33+
#ifdef MBED_CONF_RTOS_PRESENT
34+
#include "os_tick.h"
3235

3336
// Define OS TImer interrupt priority
3437
#ifndef OSTM_IRQ_PRIORITY
3538
#define OSTM_IRQ_PRIORITY 0xFFU
3639
#endif
3740

38-
// Define OS Timer channel and interrupt number
39-
#define OSTM (OSTM0)
40-
#define OSTM_IRQn ((IRQn_ID_t)OSTMI0TINT_IRQn)
41-
42-
4341
static uint32_t OSTM_Clock; // Timer tick frequency
4442
static uint8_t OSTM_PendIRQ; // Timer interrupt pending flag
4543

46-
4744
// Setup OS Tick.
4845
int32_t OS_Tick_Setup (uint32_t freq, IRQHandler_t handler)
4946
{
@@ -190,11 +187,10 @@ uint32_t OS_Tick_GetOverflow (void)
190187
{
191188
return (IRQ_GetPending(OSTM_IRQn));
192189
}
190+
#endif
193191

194192
// Get Cortex-A9 OS Timer interrupt number
195193
IRQn_ID_t mbed_get_a9_tick_irqn(){
196194
return OSTM_IRQn;
197195
}
198196

199-
#endif
200-

0 commit comments

Comments
 (0)