I want to use ptrace in qemu mips, but I can't wake up the child process when using fork and attach, however, I got success in kernel 3.2. I hope to know why got this ques in kernel 2.6?
I got the kernel from
I want to use ptrace in qemu mips, but I can't wake up the child process when using fork and attach, however, I got success in kernel 3.2. I hope to know why got this ques in kernel 2.6?
I got the kernel from
I cannot really answer your question, because it contains no usable information, so I'll just guess. Some of the ptrace constructs available were introduced into Linux later than the kernel you are using.
If you are using PTRACE_TRACEME
or PTRACE_ATTACH
, than you should be fine. If you are using PTRACE_SEIZE
, then you are using a mechanism that simply did not exist in the kernel version you are using.
I solved this pro. I use kernel 2.6.32, and this kernel had a bug for ptrace mips and I got from here, https://sourceforge.net/p/strace/mailman/message/31856938/,
and the patch is here, http://gitlab.pedjaapps.net/pedja/lge-kernel-omap4/commit/55436c91652b45be576b91ec96a8d65f6b7447fa
and I patch it and recompile the kernel and then ptrace work well.