mips32r2_common/periph/timer: fix return values

Fix 'timer_set', 'timer_set_absolute' and 'timer_clear' return value to 1 on
success as documented in the API.
This commit is contained in:
Gaëtan Harter 2018-03-02 15:18:43 +01:00
parent 7f91bfe96e
commit d6e47461ba

View File

@ -135,7 +135,7 @@ int timer_set(tim_t dev, int channel, unsigned int timeout)
compares[channel] = counter + timeout;
irq_restore(status);
return channel;
return 1;
}
int timer_set_absolute(tim_t dev, int channel, unsigned int value)
@ -152,7 +152,7 @@ int timer_set_absolute(tim_t dev, int channel, unsigned int value)
compares[channel] = value;
irq_restore(status);
return channel;
return 1;
}
int timer_clear(tim_t dev, int channel)
@ -166,7 +166,7 @@ int timer_clear(tim_t dev, int channel)
compares[channel] = 0;
irq_restore(status);
return channel;
return 1;
}
unsigned int timer_read(tim_t dev)