From: Steve VanDeBogart <vandebo-uml@NerdBox.Net> - 2008-08-13 18:35:22
Another problem detected by running UML under Valgrind; UML implements
a architecture independent version of get_wchan() in arch/um/kernel/process.c
It examines each word on the stack, looking for the first one that
appears to be a non-scheduler instruction pointer. Other architectures
are more precise, doing things like finding the base pointer and only
examining the value that should be the return address.
The UML version seems reasonable except that some values on the stack
may not be initialized and will therefore have a random value, possibly
a return address from a previous function call.
The value of get_wchan() is exported to userspace in proc, so it's not
clear to me how important it is to get this value right.