From: Roland McGrath Date: Tue, 6 Nov 2007 23:30:38 +0000 (-0800) Subject: x86_64: ia32 ptrace THREAD_AREA fix X-Git-Tag: v2.6.24-rc3~166 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fd181c72a3c202a3986bcee7551c0838265aec2a;p=pandora-kernel.git x86_64: ia32 ptrace THREAD_AREA fix The addr argument to PTRACE_GET_THREAD_AREA and PTRACE_SET_THREAD_AREA is not a magic constant. It's derived from the segment register values being used, which are computed originally from the index used with set_thread_area. The value does not need to match what a native i386 kernel would accept. It needs to match the segment selectors that can actually be in use in this 32-bit process. The 64-bit ptrace support for PTRACE_GET_THREAD_AREA (normally used only on 32-bit processes) is correct, but the 32-bit emulation of ptrace is broken. Signed-off-by: Roland McGrath Signed-off-by: Thomas Gleixner --- Reading git-diff-tree failed