mirror of https://github.com/ARMmbed/mbed-os.git
Enable access to kernel tick information in ISR
The osKernelGetTickCount() is the only function to get kernel tick information, however it's not allowed to access in ISR. It's already enabled in API v2.1.1.pull/5078/head
parent
de6d2918b8
commit
6c5af87c73
|
@ -607,8 +607,7 @@ void osKernelResume (uint32_t sleep_ticks) {
|
|||
/// Get the RTOS kernel tick count.
|
||||
uint64_t osKernelGetTickCount (void) {
|
||||
if (IS_IRQ_MODE() || IS_IRQ_MASKED()) {
|
||||
EvrRtxKernelGetTickCount(0U);
|
||||
return 0U;
|
||||
return svcRtxKernelGetTickCount();
|
||||
} else {
|
||||
return __svcKernelGetTickCount();
|
||||
}
|
||||
|
@ -617,8 +616,7 @@ uint64_t osKernelGetTickCount (void) {
|
|||
/// Get the RTOS kernel tick frequency.
|
||||
uint32_t osKernelGetTickFreq (void) {
|
||||
if (IS_IRQ_MODE() || IS_IRQ_MASKED()) {
|
||||
EvrRtxKernelGetTickFreq(0U);
|
||||
return 0U;
|
||||
return svcRtxKernelGetTickFreq();
|
||||
} else {
|
||||
return __svcKernelGetTickFreq();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue