Skip to content
Commit 440d9dc5 authored by Mulin Chao's avatar Mulin Chao Committed by Anas Nashif
Browse files

driver: itim: npcx: check ITEN bit to prevent return fake error.



During polling ITEN bit to make sure ITIM timer is enabled, we might
have the chance that npcx_itim_evt_enable() return fake error when
timeout expired but ITEN bit is set already if CONFIG_ZERO_LATENCY_IRQS
is enabled. (Since SVCall's interrupt priority is not the highest, the
other interrupts with IRQ_ZERO_LATENCY flag could preempt CPU resource
at this moment.)

In order to prevent return fake error code, this CL adjusts the check
conditions for ITEN bit and timeout.

Signed-off-by: default avatarMulin Chao <mlchao@nuvoton.com>
parent abb94b11
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment