* [PATCH] Fix prologue directives for sys_clone() and sys_clone2()]
@ 2003-08-16 0:07 John Byrne
2003-08-16 0:43 ` David Mosberger
0 siblings, 1 reply; 2+ messages in thread
From: John Byrne @ 2003-08-16 0:07 UTC (permalink / raw)
To: linux-ia64
[-- Attachment #1: Type: text/plain, Size: 553 bytes --]
To my limited understanding, the GRSAVE portions of the .prologue
directives for sys_clone() and sys_clone2() are incorrect. This patch,
against 2.6.0-test3, fixes them.
I also wonder whether the the continued usage of the 2 argument form of
clone() in kernel_thread() should be considered "bad form". Admittedly,
the other arguments are don't-care as long as the various CLONE_ flags
(which kernel_thread() does not mask off) are not set , but it just
feels wrong. I guess I wouldn't be a programmer if I didn't like to pick
nits.
John Byrne
[-- Attachment #2: diff.txt --]
[-- Type: text/plain, Size: 1094 bytes --]
diff -Nar -u4 -x '*~' linux-2.6.0-test3/arch/ia64/kernel/entry.S new/arch/ia64/kernel/entry.S
--- linux-2.6.0-test3/arch/ia64/kernel/entry.S 2003-08-08 21:34:02.000000000 -0700
+++ new/arch/ia64/kernel/entry.S 2003-08-15 16:39:29.000000000 -0700
@@ -112,9 +112,9 @@
* sys_clone2(u64 flags, u64 ustack_base, u64 ustack_size, u64 parent_tidptr, u64 child_tidptr,
* u64 tls)
*/
GLOBAL_ENTRY(sys_clone2)
- .prologue ASM_UNW_PRLG_RP|ASM_UNW_PRLG_PFS, ASM_UNW_PRLG_GRSAVE(2)
+ .prologue ASM_UNW_PRLG_RP|ASM_UNW_PRLG_PFS, ASM_UNW_PRLG_GRSAVE(6)
alloc r16=ar.pfs,6,2,6,0
DO_SAVE_SWITCH_STACK
adds r2=PT(R16)+IA64_SWITCH_STACK_SIZE+16,sp
mov loc0=rp
@@ -141,9 +141,9 @@
* sys_clone(u64 flags, u64 ustack_base, u64 parent_tidptr, u64 child_tidptr, u64 tls)
* Deprecated. Use sys_clone2() instead.
*/
GLOBAL_ENTRY(sys_clone)
- .prologue ASM_UNW_PRLG_RP|ASM_UNW_PRLG_PFS, ASM_UNW_PRLG_GRSAVE(2)
+ .prologue ASM_UNW_PRLG_RP|ASM_UNW_PRLG_PFS, ASM_UNW_PRLG_GRSAVE(5)
alloc r16=ar.pfs,5,2,6,0
DO_SAVE_SWITCH_STACK
adds r2=PT(R16)+IA64_SWITCH_STACK_SIZE+16,sp
mov loc0=rp
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] Fix prologue directives for sys_clone() and sys_clone2()]
2003-08-16 0:07 [PATCH] Fix prologue directives for sys_clone() and sys_clone2()] John Byrne
@ 2003-08-16 0:43 ` David Mosberger
0 siblings, 0 replies; 2+ messages in thread
From: David Mosberger @ 2003-08-16 0:43 UTC (permalink / raw)
To: linux-ia64
>>>>> On Fri, 15 Aug 2003 17:07:41 -0700, John Byrne <john.l.byrne@hp.com> said:
John> To my limited understanding, the GRSAVE portions of the .prologue
John> directives for sys_clone() and sys_clone2() are incorrect. This patch,
John> against 2.6.0-test3, fixes them.
Thanks, I applied the patch.
John> I also wonder whether the the continued usage of the 2
John> argument form of clone() in kernel_thread() should be
John> considered "bad form". Admittedly, the other arguments are
John> don't-care as long as the various CLONE_ flags (which
John> kernel_thread() does not mask off) are not set , but it just
John> feels wrong. I guess I wouldn't be a programmer if I didn't
John> like to pick nits.
clone() is a strict subset of clone2(), so some day we may want to
remove the former.
--david
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2003-08-16 0:43 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-08-16 0:07 [PATCH] Fix prologue directives for sys_clone() and sys_clone2()] John Byrne
2003-08-16 0:43 ` David Mosberger
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox