Core: Check next for NULL before scheduling
If all the threads except for the current one are blocked, the function
tfm_thrd_next_thread(...) returns null. This can happen if a secure
service is waiting on an interrupt signal.
To prevent assertation failure in tfm_thrd_context_switch(...), the
'pth_next' pointer have to be checked for NULL, and only do context
switch if the pointer is not NULL.
Change-Id: Ic52752df5b795c3ad7f0a6768f2d64ca7fc3ba26
Signed-off-by: Mate Toth-Pal <mate.toth-pal@arm.com>
1 file changed