mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-16 18:03:34 +08:00
Update Kinetis stubs to uses NuttX IRQ API changes
This commit is contained in:
committed by
Daniel Agar
parent
3bdbd53441
commit
e5eab6854c
@@ -133,7 +133,7 @@ static volatile uint32_t dummy[18];
|
||||
#undef modifyreg32
|
||||
#define modifyreg32(reg,clr,set)
|
||||
#define HRT_TIMER_VECTOR 0
|
||||
#define irq_attach(HRT_TIMER_VECTOR, isr) (void)(isr)
|
||||
#define irq_attach(HRT_TIMER_VECTOR, isr, args) (void)(isr)
|
||||
|
||||
#define rCR1 REG(0)
|
||||
#define rCR2 REG(1)
|
||||
@@ -309,7 +309,7 @@ static void
|
||||
hrt_tim_init(void)
|
||||
{
|
||||
/* claim our interrupt vector */
|
||||
irq_attach(HRT_TIMER_VECTOR, hrt_tim_isr);
|
||||
irq_attach(HRT_TIMER_VECTOR, hrt_tim_isr, NULL);
|
||||
|
||||
/* clock/power on our timer */
|
||||
modifyreg32(HRT_TIMER_POWER_REG, 0, HRT_TIMER_POWER_BIT);
|
||||
|
||||
@@ -210,25 +210,25 @@ static int io_timer_handler(uint16_t timer_index)
|
||||
return 0;
|
||||
}
|
||||
|
||||
int io_timer_handler0(int irq, void *context)
|
||||
int io_timer_handler0(int irq, void *context, void *arg)
|
||||
{
|
||||
|
||||
return io_timer_handler(0);
|
||||
}
|
||||
|
||||
int io_timer_handler1(int irq, void *context)
|
||||
int io_timer_handler1(int irq, void *context, void *arg)
|
||||
{
|
||||
return io_timer_handler(1);
|
||||
|
||||
}
|
||||
|
||||
int io_timer_handler2(int irq, void *context)
|
||||
int io_timer_handler2(int irq, void *context, void *arg)
|
||||
{
|
||||
return io_timer_handler(2);
|
||||
|
||||
}
|
||||
|
||||
int io_timer_handler3(int irq, void *context)
|
||||
int io_timer_handler3(int irq, void *context, void *arg)
|
||||
{
|
||||
return io_timer_handler(3);
|
||||
|
||||
@@ -478,7 +478,7 @@ static int io_timer_init_timer(unsigned timer)
|
||||
* and active but DEIR bits are not set.
|
||||
*/
|
||||
|
||||
irq_attach(io_timers[timer].vectorno, io_timers[timer].handler);
|
||||
irq_attach(io_timers[timer].vectorno, io_timers[timer].handler, NULL);
|
||||
|
||||
up_enable_irq(io_timers[timer].vectorno);
|
||||
|
||||
|
||||
@@ -99,10 +99,10 @@ __EXPORT extern const io_timers_t led_pwm_timers[MAX_LED_TIMERS];
|
||||
__EXPORT extern const timer_io_channels_t led_pwm_channels[MAX_TIMER_LED_CHANNELS];
|
||||
|
||||
__EXPORT extern io_timer_channel_allocation_t allocations[IOTimerChanModeSize];
|
||||
__EXPORT int io_timer_handler0(int irq, void *context);
|
||||
__EXPORT int io_timer_handler1(int irq, void *context);
|
||||
__EXPORT int io_timer_handler2(int irq, void *context);
|
||||
__EXPORT int io_timer_handler3(int irq, void *context);
|
||||
__EXPORT int io_timer_handler0(int irq, void *context, void *args);
|
||||
__EXPORT int io_timer_handler1(int irq, void *context, void *args);
|
||||
__EXPORT int io_timer_handler2(int irq, void *context, void *args);
|
||||
__EXPORT int io_timer_handler3(int irq, void *context, void *args);
|
||||
|
||||
__EXPORT int io_timer_channel_init(unsigned channel, io_timer_channel_mode_t mode,
|
||||
channel_handler_t channel_handler, void *context);
|
||||
|
||||
Reference in New Issue
Block a user