LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Linus Torvalds <torvalds@linux-foundation.org>
To: Roland McGrath <roland@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Ingo Molnar <mingo@elte.hu>, Thomas Gleixner <tglx@linutronix.de>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] x86_64 ptrace orig_ax on ia32 task
Date: Fri, 7 Mar 2008 15:18:41 -0800 (PST) [thread overview]
Message-ID: <alpine.LFD.1.00.0803071507240.3013@woody.linux-foundation.org> (raw)
In-Reply-To: <20080307225602.6491B26F990@magilla.localdomain>
On Fri, 7 Mar 2008, Roland McGrath wrote:
>
> This makes 64-bit ptrace calls setting the 64-bit orig_ax field
> for a 32-bit task sign-extend the low 32 bits up to 64. This
> matches what a 64-bit debugger expects when tracing a 32-bit task.
Hmm. Why make this conditional on CONFIG_IA32_EMULATION and TIF_IA32?
That field is never really 64-bit anyway. The only allowable values are
- system call number (== small positive value)
- a small negative number for traps
So I'd suggest just making it entirely unconditionally just do
case offsetof(struct user_regs_struct, orig_ax):
value = (long) (s32) value;
break;
and be done with it. Why have arbitrarily different code on x86 and x86-64
when there is no real reason for it?
Linus
next prev parent reply other threads:[~2008-03-07 23:20 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-29 3:57 [PATCH] x86_64 ia32 syscall restart fix Roland McGrath
2008-02-29 15:52 ` Ingo Molnar
2008-02-29 16:26 ` Linus Torvalds
2008-02-29 16:45 ` Ingo Molnar
2008-02-29 17:03 ` Linus Torvalds
2008-02-29 17:17 ` Ingo Molnar
2008-02-29 17:37 ` Ingo Molnar
2008-02-29 21:02 ` Andrew Morton
2008-02-29 21:20 ` Ingo Molnar
2008-03-01 5:48 ` [stable] " Greg KH
2008-02-29 22:42 ` Roland McGrath
2008-02-29 23:18 ` Linus Torvalds
2008-03-07 22:56 ` [PATCH] x86_64 ptrace orig_ax on ia32 task Roland McGrath
2008-03-07 23:18 ` Linus Torvalds [this message]
2008-03-08 1:37 ` Roland McGrath
2008-03-10 19:19 ` Chuck Ebbert
2008-03-10 19:48 ` Linus Torvalds
2008-03-10 20:01 ` Roland McGrath
2008-03-11 9:32 ` Ingo Molnar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=alpine.LFD.1.00.0803071507240.3013@woody.linux-foundation.org \
--to=torvalds@linux-foundation.org \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=roland@redhat.com \
--cc=tglx@linutronix.de \
--subject='Re: [PATCH] x86_64 ptrace orig_ax on ia32 task' \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).