OPTEEのgdbデバッグ
fail to set breakpoints. for example · Issue #463 · OP-TEE/optee_os · GitHubのbreakポイント設定例が間違えていて、無駄な時間過ごしてしまった><、
で、以下の手順でQEMU上のopteeでbreakすることを確認。
- plat_tee_entryなんて関数ないので、代わりにtee_entryを設定。
- make run で二つ立ち上がったlinux側でより
- opteeドライバmodprobe
- tee-supplicant実行
$ ./gcc-linaro-arm-none-eabi-4.9-2014.09_linux/bin/arm-none-eabi-gdb -q (gdb) optee SIGTRAP is used by the debugger. Are you sure you want to change it? (y or n) [answered Y; input not from terminal] 0x00000000 in ?? () (gdb) b tee_entry Breakpoint 1 at 0x7df0e5fa: file core/arch/arm/tee/entry.c, line 382. (gdb) c Continuing. Breakpoint 1, tee_entry (args=0x7df70918 <stack_tmp+1048>) at core/arch/arm/tee/entry.c:382 382 switch (args->a0) { (gdb)