* [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall
@ 2012-05-16 21:57 Jonathan Nieder
2012-05-16 22:29 ` Ben Hutchings
` (8 more replies)
0 siblings, 9 replies; 10+ messages in thread
From: Jonathan Nieder @ 2012-05-16 21:57 UTC (permalink / raw)
To: linux-ia64
From: Émeric Maschino <emeric.maschino@gmail.com>
commit 65cc21b4523e94d5640542a818748cd3be8cd6b4 upstream.
While debugging udev > 170 failure on Debian Wheezy
(http://bugs.debian.org/cgi-bin/bugreport.cgi?bugd8325), it appears
that the issue was in fact due to missing accept4() in ia64.
This patch simply adds accept4() to ia64.
Signed-off-by: Émeric Maschino <emeric.maschino@gmail.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
---
Hi Ben and Greg,
Émeric Maschino wrote[1]:
> Starting with udev 170 (well, IIRC!), console is flooded at startup with:
>
> udevd[XXX]: unable to receive ctrl connection: Function not implemented
>
> where XXX is a number (PID?).
>
> And system takes ~3 min. to get login prompt.
Indeed, udev versions since 168 (2011-04-22) require the accept4()
syscall. That syscall was added to the kernel in 2.6.28 (2008-11-19),
but arches were slow to pick it up because checksyscalls.sh didn't
catch it[2] (it was implemented on 32-bit x86 using sys_socketcall).
Here is a list of when each arch added the syscall:
x86 and arches using socketcall (2008-11-19) v2.6.28-rc6~45
sparc64 (2008-11-19) v2.6.28-rc6~44
MIPS (2009-08-03) v2.6.31-rc6~64^2
microblaze (2009-12-28) v2.6.33-rc5~19^2~3
sh64 (2010-01-19) v2.6.33-rc5~13^2
parisc (2009-12-26) v2.6.34-rc1~13^2~6
ARM (2010-08-15) v2.6.36-rc2~52^2~2
sh (2010-12-13) v2.6.37-rc6~10^2
alpha (2011-10-31) v3.2-rc1~108^2~58
ia64 (2012-01-09) v3.3-rc1~73^2
Lots of arches are not listed above because they use the multiplexed
socketcall call and got support right away. (sh and sh64 provide both
the direct syscall and socketcall.)
This patch was merged upstream during the 3.3 merge window and has
been in use in Debian's 3.2.y-based kernel since January.
As long as libc was built to use the syscall, applying this patch
makes udev work properly again on ia64. What do you think?
Jonathan
[1] http://bugs.debian.org/648325
[2] http://thread.gmane.org/gmane.linux.kernel.cross-arch/11888/focus\x11907
arch/ia64/include/asm/unistd.h | 3 ++-
arch/ia64/kernel/entry.S | 3 +++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/arch/ia64/include/asm/unistd.h b/arch/ia64/include/asm/unistd.h
index 7c928da35b17..d8de1825b736 100644
--- a/arch/ia64/include/asm/unistd.h
+++ b/arch/ia64/include/asm/unistd.h
@@ -321,11 +321,12 @@
#define __NR_syncfs 1329
#define __NR_setns 1330
#define __NR_sendmmsg 1331
+#define __NR_accept4 1334
#ifdef __KERNEL__
-#define NR_syscalls 308 /* length of syscall table */
+#define NR_syscalls 311 /* length of syscall table */
/*
* The following defines stop scripts/checksyscalls.sh from complaining about
diff --git a/arch/ia64/kernel/entry.S b/arch/ia64/kernel/entry.S
index 97dd2abdeb1a..df477f8c9d82 100644
--- a/arch/ia64/kernel/entry.S
+++ b/arch/ia64/kernel/entry.S
@@ -1777,6 +1777,9 @@ sys_call_table:
data8 sys_syncfs
data8 sys_setns // 1330
data8 sys_sendmmsg
+ data8 sys_ni_syscall /* process_vm_readv */
+ data8 sys_ni_syscall /* process_vm_writev */
+ data8 sys_accept4
.org sys_call_table + 8*NR_syscalls // guard against failures to increase NR_syscalls
#endif /* __IA64_ASM_PARAVIRTUALIZED_NATIVE */
--
1.7.10.2
^ permalink raw reply related [flat|nested] 10+ messages in thread
* Re: [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall
2012-05-16 21:57 [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall Jonathan Nieder
@ 2012-05-16 22:29 ` Ben Hutchings
2012-05-17 10:29 ` Émeric Maschino
` (7 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Ben Hutchings @ 2012-05-16 22:29 UTC (permalink / raw)
To: linux-ia64
[-- Attachment #1: Type: text/plain, Size: 556 bytes --]
On Wed, 2012-05-16 at 16:57 -0500, Jonathan Nieder wrote:
> From: Émeric Maschino <emeric.maschino@gmail.com>
>
> commit 65cc21b4523e94d5640542a818748cd3be8cd6b4 upstream.
>
> While debugging udev > 170 failure on Debian Wheezy
> (http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=648325), it appears
> that the issue was in fact due to missing accept4() in ia64.
>
> This patch simply adds accept4() to ia64.
[...]
Queued up for 3.2.y.
Ben.
--
Ben Hutchings
The two most common things in the universe are hydrogen and stupidity.
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 828 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall
2012-05-16 21:57 [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall Jonathan Nieder
2012-05-16 22:29 ` Ben Hutchings
@ 2012-05-17 10:29 ` Émeric Maschino
2012-05-17 11:46 ` Ben Hutchings
` (6 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Émeric Maschino @ 2012-05-17 10:29 UTC (permalink / raw)
To: linux-ia64
2012/5/17 Ben Hutchings <ben@decadent.org.uk>:
> On Wed, 2012-05-16 at 16:57 -0500, Jonathan Nieder wrote:
>> From: Émeric Maschino <emeric.maschino@gmail.com>
>>
>> [...]
>>
>> This patch simply adds accept4() to ia64.
> [...]
>
> Queued up for 3.2.y.
Hasn't it been already added [1]?
Indeed, I'm no more having this issue with (at least) Debian kernel
3.2.14-1 and 3.2.16-1.
Discussion about direct syscalls and indirect socketcalls [2], with
PPC deprecating socketcalls, is beyond my knowledge. Jonathan, was it
your point?
Emeric
[1] http://bugs.debian.org/cgi-bin/bugreport.cgi?bugd7825#123
[2] http://thread.gmane.org/gmane.linux.kernel.cross-arch/11888/focus\x11907
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall
2012-05-16 21:57 [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall Jonathan Nieder
2012-05-16 22:29 ` Ben Hutchings
2012-05-17 10:29 ` Émeric Maschino
@ 2012-05-17 11:46 ` Ben Hutchings
2012-05-17 22:11 ` Émeric Maschino
` (5 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Ben Hutchings @ 2012-05-17 11:46 UTC (permalink / raw)
To: linux-ia64
[-- Attachment #1: Type: text/plain, Size: 633 bytes --]
On Thu, 2012-05-17 at 12:29 +0200, Émeric Maschino wrote:
> 2012/5/17 Ben Hutchings <ben@decadent.org.uk>:
> > On Wed, 2012-05-16 at 16:57 -0500, Jonathan Nieder wrote:
> >> From: Émeric Maschino <emeric.maschino@gmail.com>
> >>
> >> [...]
> >>
> >> This patch simply adds accept4() to ia64.
> > [...]
> >
> > Queued up for 3.2.y.
>
> Hasn't it been already added [1]?
>
> Indeed, I'm no more having this issue with (at least) Debian kernel
> 3.2.14-1 and 3.2.16-1.
[...]
Right, but this is not just for Debian.
Ben.
--
Ben Hutchings
Every program is either trivial or else contains at least one bug
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 828 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall
2012-05-16 21:57 [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall Jonathan Nieder
` (2 preceding siblings ...)
2012-05-17 11:46 ` Ben Hutchings
@ 2012-05-17 22:11 ` Émeric Maschino
2012-05-17 22:49 ` Jonathan Nieder
` (4 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Émeric Maschino @ 2012-05-17 22:11 UTC (permalink / raw)
To: linux-ia64
2012/5/17 Ben Hutchings <ben@decadent.org.uk>:
> On Thu, 2012-05-17 at 12:29 +0200, Émeric Maschino wrote:
>> 2012/5/17 Ben Hutchings <ben@decadent.org.uk>:
>> > On Wed, 2012-05-16 at 16:57 -0500, Jonathan Nieder wrote:
>> >> From: Émeric Maschino <emeric.maschino@gmail.com>
>> >>
>> >> [...]
>> >>
>> >> This patch simply adds accept4() to ia64.
>> > [...]
>> >
>> > Queued up for 3.2.y.
>>
>> Hasn't it been already added [1]?
>>
>
> Right, but this is not just for Debian.
Uh? I thought that Debian was the latest Linux distribution to support IA-64.
Emeric
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall
2012-05-16 21:57 [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall Jonathan Nieder
` (3 preceding siblings ...)
2012-05-17 22:11 ` Émeric Maschino
@ 2012-05-17 22:49 ` Jonathan Nieder
2012-05-18 9:07 ` Émeric Maschino
` (3 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Jonathan Nieder @ 2012-05-17 22:49 UTC (permalink / raw)
To: linux-ia64
Hi Émeric,
Émeric Maschino wrote:
> 2012/5/17 Ben Hutchings <ben@decadent.org.uk>:
>> Right, but this is not just for Debian.
>
> Uh? I thought that Debian was the latest Linux distribution to support IA-64.
Gentoo and Linux From Scratch include support for Itanium. It is also
not too unusual to upgrade some components (especially the kernel) on
an older system when one wants newer features.
My original message was proposing to include this patch in the 3.0.y
and 3.2.y kernels available from kernel.org. Ben made that change for
3.2.y so it will be included in 3.2.18 (unless some problem comes up
before then). Sorry for the lack of context.
Ciao,
Jonathan
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall
2012-05-16 21:57 [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall Jonathan Nieder
` (4 preceding siblings ...)
2012-05-17 22:49 ` Jonathan Nieder
@ 2012-05-18 9:07 ` Émeric Maschino
2012-05-18 19:28 ` Greg KH
` (2 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Émeric Maschino @ 2012-05-18 9:07 UTC (permalink / raw)
To: linux-ia64
2012/5/18 Jonathan Nieder <jrnieder@gmail.com>:
> Émeric Maschino wrote:
>> 2012/5/17 Ben Hutchings <ben@decadent.org.uk>:
>
>>> Right, but this is not just for Debian.
>>
>> Uh? I thought that Debian was the latest Linux distribution to support IA-64.
>
> Gentoo and Linux From Scratch include support for Itanium. It is also
> not too unusual to upgrade some components (especially the kernel) on
> an older system when one wants newer features.
>
> My original message was proposing to include this patch in the 3.0.y
> and 3.2.y kernels available from kernel.org. Ben made that change for
> 3.2.y so it will be included in 3.2.18 (unless some problem comes up
> before then). Sorry for the lack of context.
I didn't understand you were talking about upstream. Thank you for the
clarification. And for pointing out that Gentoo is still alive ;-)
Emeric
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall
2012-05-16 21:57 [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall Jonathan Nieder
` (5 preceding siblings ...)
2012-05-18 9:07 ` Émeric Maschino
@ 2012-05-18 19:28 ` Greg KH
2012-05-18 19:37 ` Jonathan Nieder
2012-05-19 0:53 ` Greg KH
8 siblings, 0 replies; 10+ messages in thread
From: Greg KH @ 2012-05-18 19:28 UTC (permalink / raw)
To: linux-ia64
On Wed, May 16, 2012 at 04:57:00PM -0500, Jonathan Nieder wrote:
> From: Émeric Maschino <emeric.maschino@gmail.com>
>
> commit 65cc21b4523e94d5640542a818748cd3be8cd6b4 upstream.
>
> While debugging udev > 170 failure on Debian Wheezy
> (http://bugs.debian.org/cgi-bin/bugreport.cgi?bugd8325), it appears
> that the issue was in fact due to missing accept4() in ia64.
>
> This patch simply adds accept4() to ia64.
>
> Signed-off-by: Émeric Maschino <emeric.maschino@gmail.com>
> Signed-off-by: Tony Luck <tony.luck@intel.com>
> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
> ---
> Hi Ben and Greg,
>
> Émeric Maschino wrote[1]:
>
> > Starting with udev 170 (well, IIRC!), console is flooded at startup with:
> >
> > udevd[XXX]: unable to receive ctrl connection: Function not implemented
> >
> > where XXX is a number (PID?).
> >
> > And system takes ~3 min. to get login prompt.
>
> Indeed, udev versions since 168 (2011-04-22) require the accept4()
> syscall. That syscall was added to the kernel in 2.6.28 (2008-11-19),
> but arches were slow to pick it up because checksyscalls.sh didn't
> catch it[2] (it was implemented on 32-bit x86 using sys_socketcall).
> Here is a list of when each arch added the syscall:
>
> x86 and arches using socketcall (2008-11-19) v2.6.28-rc6~45
> sparc64 (2008-11-19) v2.6.28-rc6~44
> MIPS (2009-08-03) v2.6.31-rc6~64^2
> microblaze (2009-12-28) v2.6.33-rc5~19^2~3
> sh64 (2010-01-19) v2.6.33-rc5~13^2
> parisc (2009-12-26) v2.6.34-rc1~13^2~6
> ARM (2010-08-15) v2.6.36-rc2~52^2~2
> sh (2010-12-13) v2.6.37-rc6~10^2
> alpha (2011-10-31) v3.2-rc1~108^2~58
> ia64 (2012-01-09) v3.3-rc1~73^2
>
> Lots of arches are not listed above because they use the multiplexed
> socketcall call and got support right away. (sh and sh64 provide both
> the direct syscall and socketcall.)
>
> This patch was merged upstream during the 3.3 merge window and has
> been in use in Debian's 3.2.y-based kernel since January.
>
> As long as libc was built to use the syscall, applying this patch
> makes udev work properly again on ia64. What do you think?
I'd accept it for the 3.0-stable kernel, but it doesn't apply, care to
provide a backported version that does?
thanks,
greg k-h
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall
2012-05-16 21:57 [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall Jonathan Nieder
` (6 preceding siblings ...)
2012-05-18 19:28 ` Greg KH
@ 2012-05-18 19:37 ` Jonathan Nieder
2012-05-19 0:53 ` Greg KH
8 siblings, 0 replies; 10+ messages in thread
From: Jonathan Nieder @ 2012-05-18 19:37 UTC (permalink / raw)
To: linux-ia64
Greg KH wrote:
> I'd accept it for the 3.0-stable kernel, but it doesn't apply, care to
> provide a backported version that does?
The message you were replying to is such a backported version. :)
Thanks,
Jonathan
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall
2012-05-16 21:57 [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall Jonathan Nieder
` (7 preceding siblings ...)
2012-05-18 19:37 ` Jonathan Nieder
@ 2012-05-19 0:53 ` Greg KH
8 siblings, 0 replies; 10+ messages in thread
From: Greg KH @ 2012-05-19 0:53 UTC (permalink / raw)
To: linux-ia64
On Fri, May 18, 2012 at 02:37:22PM -0500, Jonathan Nieder wrote:
> Greg KH wrote:
>
> > I'd accept it for the 3.0-stable kernel, but it doesn't apply, care to
> > provide a backported version that does?
>
> The message you were replying to is such a backported version. :)
Ugh, you are right, it is, I thought I had tried that, sorry for the
noise, I'll go apply it now...
greg k-h
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2012-05-19 0:53 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-05-16 21:57 [PATCH 3.0.y, 3.2.y] ia64: Add accept4() syscall Jonathan Nieder
2012-05-16 22:29 ` Ben Hutchings
2012-05-17 10:29 ` Émeric Maschino
2012-05-17 11:46 ` Ben Hutchings
2012-05-17 22:11 ` Émeric Maschino
2012-05-17 22:49 ` Jonathan Nieder
2012-05-18 9:07 ` Émeric Maschino
2012-05-18 19:28 ` Greg KH
2012-05-18 19:37 ` Jonathan Nieder
2012-05-19 0:53 ` Greg KH
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox