Skip to content

Commit f0659d7

Browse files
authored
[bsp][infineon] fix the type of rtc_alarm_callback in drv_rtc #10830
1 parent 8816a9d commit f0659d7

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

bsp/Infineon/libraries/HAL_Drivers/drv_rtc.c

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,9 @@ static rt_err_t ifx_rtc_get_timeval(struct timeval *tv)
100100

101101
return RT_EOK;
102102
}
103-
103+
#ifdef RT_USING_ALARM
104+
void rtc_alarm_callback(void *callback_arg, cyhal_rtc_event_t event);
105+
#endif
104106
static rt_err_t _rtc_init(void)
105107
{
106108
#ifdef BSP_RTC_USING_LSE
@@ -187,8 +189,10 @@ static rt_err_t _rtc_set_alarm(struct rt_rtc_wkalarm *alarm)
187189
}
188190

189191
#ifdef RT_USING_ALARM
190-
void rtc_alarm_callback(void)
192+
void rtc_alarm_callback(void *callback_arg, cyhal_rtc_event_t event)
191193
{
194+
RT_UNUSED(callback_arg);
195+
RT_UNUSED(event);
192196
rt_interrupt_enter();
193197
rt_alarm_update(0, 0);
194198
rt_interrupt_leave();
@@ -232,3 +236,4 @@ static int rt_hw_rtc_init(void)
232236

233237
INIT_DEVICE_EXPORT(rt_hw_rtc_init);
234238
#endif
239+
#endif

0 commit comments

Comments
 (0)