kernel: work_q: use flags_get() in work_delayable_busy_get_locked().

The k_work::flags field is not an atomic_t and would cause
-Wpointer-sign warning on some compilers. This function was the only
one in work.c to use atomic_get() so there is no benefit to atomicity.

Signed-off-by: Chris Reed <chris.reed@arm.com>
This commit is contained in:
Chris Reed 2021-10-13 15:02:42 -05:00 committed by Anas Nashif
commit ab4d69baf3

View file

@ -829,7 +829,7 @@ void k_work_init_delayable(struct k_work_delayable *dwork,
static inline int work_delayable_busy_get_locked(const struct k_work_delayable *dwork)
{
return atomic_get(&dwork->work.flags) & K_WORK_MASK;
return flags_get(&dwork->work.flags) & K_WORK_MASK;
}
int k_work_delayable_busy_get(const struct k_work_delayable *dwork)