This patch is fixing three related problems: 1. When calling a syscall the marshalling function is using the ssf parameter as value to be saved in _current->syscall_frame to mark the beginning and the end of the syscall. This ssf value is not currently being explictly set and instead the syscall code is using whatever value is stored in x6 when the syscall is called. If it happens that x6 is 0 at the time the syscall is called, this causes the z_is_in_user_syscall() function to fail. Fix this passing the ESF as value for ssf. 2. Given that in the ssf is now present the ESF, we can fix arch_syscall_oops() using the ESF to print a more detailed error message with registers dump. 3. When a wrong syscall number is used, handler_bad_syscall() is called. This function expects the ID number as first parameter to print the error message, fix this. Signed-off-by: Carlo Caione <ccaione@baylibre.com> |
||
|---|---|---|
| .. | ||
| arc | ||
| arm | ||
| arm64 | ||
| common | ||
| nios2 | ||
| posix | ||
| riscv | ||
| sparc | ||
| x86 | ||
| xtensa | ||
| CMakeLists.txt | ||
| Kconfig | ||