kernel/poll: Remove dummy waitq from stack

The poll code uses a dummy wait queue so the threads have something to
block on, but the previous coherence pass (which rearranged things to
put the _poller data elsewhere) missed that this was on the stack,
which is not allowed.  It actually has no use except as a list, so
make it a global static instead.

Signed-off-by: Andy Ross <andrew.j.ross@intel.com>
This commit is contained in:
Andy Ross 2021-02-09 13:46:21 -08:00 committed by Anas Nashif
commit 4dc6a0b89b

View file

@ -284,7 +284,7 @@ int z_impl_k_poll(struct k_poll_event *events, int num_events,
return -EAGAIN;
}
_wait_q_t wait_q = Z_WAIT_Q_INIT(&wait_q);
static _wait_q_t wait_q = Z_WAIT_Q_INIT(&wait_q);
int swap_rc = z_pend_curr(&lock, key, &wait_q, timeout);