1/* 2 * Copyright 2017, Data61 3 * Commonwealth Scientific and Industrial Research Organisation (CSIRO) 4 * ABN 41 687 119 230. 5 * 6 * This software may be distributed and modified according to the terms of 7 * the BSD 2-Clause license. Note that NO WARRANTY is provided. 8 * See "LICENSE_BSD2.txt" for details. 9 * 10 * @TAG(DATA61_BSD) 11 */ 12 13#include <sel4/sel4.h> 14#include <sel4debug/unknown_syscall.h> 15 16void debug_unknown_syscall_message(int (*printfn)(const char *format, ...), 17 seL4_Word* mrs) 18{ 19 /* See section 5.2.2 of the manual. */ 20 printfn(" EAX = %p\n" 21 " EBX = %p\n" 22 " ECX = %p\n" 23 " EDX = %p\n" 24 " ESI = %p\n" 25 " EDI = %p\n" 26 " EBP = %p\n" 27 " EIP = %p\n" 28 " ESP = %p\n" 29 " EFLAGS = %p\n" 30 " syscall = %p\n", 31 (void*)mrs[0], (void*)mrs[1], (void*)mrs[2], (void*)mrs[3], 32 (void*)mrs[4], (void*)mrs[5], (void*)mrs[6], (void*)mrs[7], 33 (void*)mrs[8], (void*)mrs[9], (void*)mrs[10]); 34} 35