Re: 2.6.24-rc3-mm2 - Build Failure on powerpc timerfd() undeclared

5 messages, 4 authors, 2007-11-29 · open the first message on its own page

Re: 2.6.24-rc3-mm2 - Build Failure on powerpc timerfd() undeclared

From: Kamalesh Babulal <hidden>
Date: 2007-11-28 12:41:22

Hi Andrew,

Kernel build fails, with build error

  CC      arch/powerpc/platforms/cell/spu_callbacks.o
In file included from arch/powerpc/platforms/cell/spu_callbacks.c:49:
include/asm/systbl.h:312: error: ‘sys_timerfd’ undeclared here (not in a function)
make[2]: *** [arch/powerpc/platforms/cell/spu_callbacks.o] Error 1
make[1]: *** [arch/powerpc/platforms/cell] Error 2
make: *** [arch/powerpc/platforms] Error 2

-- 
Thanks & Regards,
Kamalesh Babulal,
Linux Technology Center,
IBM, ISTL.

Re: 2.6.24-rc3-mm2 - Build Failure on powerpc timerfd() undeclared

From: Arnd Bergmann <arnd@arndb.de>
Date: 2007-11-28 13:33:48

On Wednesday 28 November 2007, Kamalesh Babulal wrote:
Kernel build fails, with build error
=20
=C2=A0 CC =C2=A0 =C2=A0 =C2=A0arch/powerpc/platforms/cell/spu_callbacks.o
In file included from arch/powerpc/platforms/cell/spu_callbacks.c:49:
include/asm/systbl.h:312: error: =E2=80=98sys_timerfd=E2=80=99 undeclared=
 here (not in a function)
make[2]: *** [arch/powerpc/platforms/cell/spu_callbacks.o] Error 1
make[1]: *** [arch/powerpc/platforms/cell] Error 2
make: *** [arch/powerpc/platforms] Error 2
=20
I guess all architectures except x86 are currently broken because they
reference the old sys_timerfd function. This patch should add the missing
bits to powerpc.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>

=2D--

Disclaimer: Not tested at all, just applied common sense.
Disclaimer2: conflicts with the sys_indirect kernel implementation
sent by paulus last week.
diff --git a/include/asm-powerpc/systbl.h b/include/asm-powerpc/systbl.h
index 11d5383..b029368 100644
=2D-- a/include/asm-powerpc/systbl.h
+++ b/include/asm-powerpc/systbl.h
@@ -309,7 +309,9 @@ SYSCALL_SPU(getcpu)
 COMPAT_SYS(epoll_pwait)
 COMPAT_SYS_SPU(utimensat)
 COMPAT_SYS_SPU(signalfd)
=2DCOMPAT_SYS_SPU(timerfd)
+COMPAT_SYS_SPU(timerfd_create)
 SYSCALL_SPU(eventfd)
 COMPAT_SYS_SPU(sync_file_range2)
 COMPAT_SYS(fallocate)
+COMPAT_SYS_SPU(sys_timerfd_settime)
+COMPAT_SYS_SPU(sys_timerfd_gettime)
diff --git a/include/asm-powerpc/unistd.h b/include/asm-powerpc/unistd.h
index 97d82b6..4ba2d20 100644
=2D-- a/include/asm-powerpc/unistd.h
+++ b/include/asm-powerpc/unistd.h
@@ -328,14 +328,16 @@
 #define __NR_epoll_pwait	303
 #define __NR_utimensat		304
 #define __NR_signalfd		305
=2D#define __NR_timerfd		306
+#define __NR_timerfd_create	306
 #define __NR_eventfd		307
 #define __NR_sync_file_range2	308
 #define __NR_fallocate		309
+#define __NR_sys_timerfd_settime 310
+#define __NR_sys_timerfd_gettime 311
=20
 #ifdef __KERNEL__
=20
=2D#define __NR_syscalls		310
+#define __NR_syscalls		312
=20
 #define __NR__exit __NR_exit
 #define NR_syscalls	__NR_syscalls

Re: 2.6.24-rc3-mm2 - Build Failure on powerpc timerfd() undeclared

From: Andrew Morton <akpm@linux-foundation.org>
Date: 2007-11-28 18:54:43

On Wed, 28 Nov 2007 14:32:07 +0100 Arnd Bergmann [off-list ref] wrote:
On Wednesday 28 November 2007, Kamalesh Babulal wrote:
quoted
Kernel build fails, with build error

  CC      arch/powerpc/platforms/cell/spu_callbacks.o
In file included from arch/powerpc/platforms/cell/spu_callbacks.c:49:
include/asm/systbl.h:312: error: ‘sys_timerfd’ undeclared here (not in a function)
make[2]: *** [arch/powerpc/platforms/cell/spu_callbacks.o] Error 1
make[1]: *** [arch/powerpc/platforms/cell] Error 2
make: *** [arch/powerpc/platforms] Error 2
I guess all architectures except x86 are currently broken because they
reference the old sys_timerfd function.
None of them were broken in my testing and I'm unsure why powerpc broke
here.
This patch should add the missing
bits to powerpc.
Because the patches in -mm left the stubs in place in sys_ni.c and powerpc
_should_ have (incorrectly) picked those up.

Odd.
quoted hunk
---

Disclaimer: Not tested at all, just applied common sense.
Disclaimer2: conflicts with the sys_indirect kernel implementation
sent by paulus last week.
diff --git a/include/asm-powerpc/systbl.h b/include/asm-powerpc/systbl.h
index 11d5383..b029368 100644
--- a/include/asm-powerpc/systbl.h
+++ b/include/asm-powerpc/systbl.h
@@ -309,7 +309,9 @@ SYSCALL_SPU(getcpu)
 COMPAT_SYS(epoll_pwait)
 COMPAT_SYS_SPU(utimensat)
 COMPAT_SYS_SPU(signalfd)
-COMPAT_SYS_SPU(timerfd)
+COMPAT_SYS_SPU(timerfd_create)
 SYSCALL_SPU(eventfd)
 COMPAT_SYS_SPU(sync_file_range2)
 COMPAT_SYS(fallocate)
+COMPAT_SYS_SPU(sys_timerfd_settime)
+COMPAT_SYS_SPU(sys_timerfd_gettime)
diff --git a/include/asm-powerpc/unistd.h b/include/asm-powerpc/unistd.h
index 97d82b6..4ba2d20 100644
--- a/include/asm-powerpc/unistd.h
+++ b/include/asm-powerpc/unistd.h
@@ -328,14 +328,16 @@
 #define __NR_epoll_pwait	303
 #define __NR_utimensat		304
 #define __NR_signalfd		305
-#define __NR_timerfd		306
+#define __NR_timerfd_create	306
 #define __NR_eventfd		307
 #define __NR_sync_file_range2	308
 #define __NR_fallocate		309
+#define __NR_sys_timerfd_settime 310
+#define __NR_sys_timerfd_gettime 311
 
 #ifdef __KERNEL__
 
-#define __NR_syscalls		310
+#define __NR_syscalls		312
 
 #define __NR__exit __NR_exit
 #define NR_syscalls	__NR_syscalls

Re: 2.6.24-rc3-mm2 - Build Failure on powerpc timerfd() undeclared

From: Davide Libenzi <hidden>
Date: 2007-11-28 19:25:47

On Wed, 28 Nov 2007, Andrew Morton wrote:
On Wed, 28 Nov 2007 14:32:07 +0100 Arnd Bergmann [off-list ref] wrote:
quoted
On Wednesday 28 November 2007, Kamalesh Babulal wrote:
quoted
Kernel build fails, with build error

  CC      arch/powerpc/platforms/cell/spu_callbacks.o
In file included from arch/powerpc/platforms/cell/spu_callbacks.c:49:
include/asm/systbl.h:312: error: ‘sys_timerfd’ undeclared here (not in a function)
make[2]: *** [arch/powerpc/platforms/cell/spu_callbacks.o] Error 1
make[1]: *** [arch/powerpc/platforms/cell] Error 2
make: *** [arch/powerpc/platforms] Error 2
I guess all architectures except x86 are currently broken because they
reference the old sys_timerfd function.
None of them were broken in my testing and I'm unsure why powerpc broke
here.
quoted
This patch should add the missing
bits to powerpc.
Because the patches in -mm left the stubs in place in sys_ni.c and powerpc
_should_ have (incorrectly) picked those up.
My fault. I forgot to update sys_ni.c with the new functions (and with the
sys_timerfd->sys_timerfd_create name change).
Do you want a patch Andrew?



- Davide

Re: 2.6.24-rc3-mm2 - Build Failure on powerpc timerfd() undeclared

From: Arnd Bergmann <arnd@arndb.de>
Date: 2007-11-29 00:58:17

On Wednesday 28 November 2007 19:43:45 Andrew Morton wrote:
quoted
I guess all architectures except x86 are currently broken because they
reference the old sys_timerfd function.
None of them were broken in my testing and I'm unsure why powerpc broke
here.
PowerPC is unique in that it actually relies on the declarations
in include/{linux,asm}/syscalls.h to be present, because the
spu_syscall_table is generated from C code, not from assembly.
One reason why I did this was to be sure to find this exact
type of problem at compile-time, not at link time.

	Arnd <><
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help