PSR register not getting updated

Daniel Cederman cederman at gaisler.com
Thu Nov 12 10:27:50 UTC 2015


Hello,

I experienced a bug when using 4.11 SMP on a LEON4 system. One of the 
tasks in my program suddenly lost the FPU enable bit in the PSR register 
after a task switch. I tracked down the problem being due to the task 
switching code not updating the PSR if the heir changes during the 
switch (which happens if the original heir gets scheduled on another 
CPU). I am submitting a patch that updates the PSR register to match the 
value for the new heir. It can probably be improved by moving the PSR 
update to after the heir has been acquired, but I wanted to change as 
little as possible.

-- 
Daniel Cederman
Software Engineer
Cobham Gaisler
F : +46 (0) 31 421407
daniel.cederman at gaisler.com


More information about the devel mailing list