Build Issue - Sparc64
Anyone got any ideas. This is from the 2.6.15 build. We are doing some testing building a 64 bit kernel with no 32 bit support for testing purposes and we ran into this error. GCC 4, Binutils 2.16.1, Glibc 2.3.6.
cc1: warnings being treated as errors arch/sparc64/kernel/process.c: In function 'show_regwindow32':arch/sparc64/kernel/process.c:174: warning: implicit declaration of function 'compat_ptr'arch/sparc64/kernel/process.c:174: warning: assignment makes pointer from integer without a cast
make[1]: *** [arch/sparc64/kernel/process.o] Error 1
make: *** [arch/sparc64/kernel] Error 2
Signature · 3 lines
---- Jim Gifford [email protected]
Quoted 4 lines · Jim Gifford
Anyone got any ideas. This is from the 2.6.15 build. We are doing some testing building a 64 bit kernel with no 32 bit support for testing purposes and we ran into this error. GCC 4, Binutils 2.16.1, Glibc 2.3.6.
Quoted 9 lines
cc1: warnings being treated as errors
arch/sparc64/kernel/process.c: In function 'show_regwindow32':arch/sparc64/kernel/process.c:174: warning: implicit declaration of function 'compat_ptr'arch/sparc64/kernel/process.c:174: warning: assignment makes pointer from integer without a cast
make[1]: *** [arch/sparc64/kernel/process.o] Error 1
make: *** [arch/sparc64/kernel] Error 2
Fixed the issue with this patch.
process.c 2006-01-12 13:28:21.000000000 -0800 renamed from process.c.orig 2006-01-12 13:27:03.000000000 -0800 +7 -1
@@ -164,6 +164,7 @@ panic("Reboot failed!"); } +#ifdef CONFIG_COMPAT static void show_regwindow32(struct pt_regs *regs) { struct reg_window32 __user *rw;
@@ -189,6 +190,7 @@ r_w.ins[0], r_w.ins[1], r_w.ins[2], r_w.ins[3], r_w.ins[4], r_w.ins[5], r_w.ins[6], r_w.ins[7]); } +#endif static void show_regwindow(struct pt_regs *regs) {
@@ -214,7 +216,11 @@ set_fs (old_fs); } } else { - show_regwindow32(regs); + #ifdef CONFIG_COMPAT + show_regwindow32(regs); + #else + show_regwindow(regs); + #endif return; } printk("l0: %016lx l1: %016lx l2: %016lx l3: %016lx\n",
Signature · 3 lines
---- Jim Gifford [email protected]
Quoted 4 lines · Jim Gifford
Anyone got any ideas. This is from the 2.6.15 build. We are doing some testing building a 64 bit kernel with no 32 bit support for testing purposes and we ran into this error. GCC 4, Binutils 2.16.1, Glibc 2.3.6.
Quoted 9 lines
cc1: warnings being treated as errors
arch/sparc64/kernel/process.c: In function 'show_regwindow32':arch/sparc64/kernel/process.c:174: warning: implicit declaration of function 'compat_ptr'arch/sparc64/kernel/process.c:174: warning: assignment makes pointer from integer without a cast
make[1]: *** [arch/sparc64/kernel/process.o] Error 1
make: *** [arch/sparc64/kernel] Error 2
Fixed the issue with this patch.
process.c 2006-01-12 13:28:21.000000000 -0800 renamed from process.c.orig 2006-01-12 13:27:03.000000000 -0800 +0 -0
@@ -164,6 +164,7 @@ panic("Reboot failed!");
}
+#ifdef CONFIG_COMPAT
static void show_regwindow32(struct pt_regs *regs)
{
struct reg_window32 __user *rw;
@@ -189,6 +190,7 @@
r_w.ins[0], r_w.ins[1], r_w.ins[2], r_w.ins[3],
r_w.ins[4], r_w.ins[5], r_w.ins[6], r_w.ins[7]);
}+#endif
static void show_regwindow(struct pt_regs *regs)
{
@@ -214,7 +216,11 @@
set_fs (old_fs);
}
} else {- show_regwindow32(regs);
+ #ifdef CONFIG_COMPAT
+ show_regwindow32(regs);
+ #else
+ show_regwindow(regs);
+ #endif
return;
}
printk("l0: %016lx l1: %016lx l2: %016lx l3: %016lx\n",Signature · 3 lines
---- Jim Gifford [email protected]
From: Jim Gifford <[email protected]>
Date: Thu, 12 Jan 2006 13:30:56 -0800
Quoted 1 line
Fixed the issue with this patch.
Thanks for the report and preliminary fix patch Jim. I've solved it slightly differently in my tree, let me know if this works for you as well.
Thanks.
arch/sparc64/kernel/process.c +4 -0
@@ -164,6 +164,7 @@ void machine_restart(char * cmd)panic ("Reboot failed!" ); } +#ifdef CONFIG_COMPAT static void show_regwindow32 (struct pt_regs *regs) {struct reg_window32 __user *rw;
@@ -189,6 +190,9 @@ static void show_regwindow32(struct pt_r r_w.ins[0 ], r_w.ins[1 ], r_w.ins[2 ], r_w.ins[3 ], r_w.ins[4], r_w.ins[5], r_w.ins[6], r_w.ins[7]); } +#else +#define show_regwindow32 (regs) do { } while (0) +#endif static void show_regwindow (struct pt_regs *regs) {
I'll try the other patch and also, we ran into this on the build also, said we were missing symbol verify_compat_iovec, so I CONFIG_COMPAT that one also.
arch/sparc64/kernel/sparc64_ksyms.c +2 -0
@@ -239,7 +239,9 @@/* Solaris/SunOS binary compatibility */ EXPORT_SYMBOL (_sigpause_common); +#ifdef CONFIG_COMPAT EXPORT_SYMBOL (verify_compat_iovec); +#endif EXPORT_SYMBOL (dump_thread);EXPORT_SYMBOL (dump_fpu);
Signature · 3 lines
---- Jim Gifford [email protected]
From: Jim Gifford <[email protected]>
Date: Wed, 18 Jan 2006 15:02:51 -0800
Quoted 3 lines
I'll try the other patch and also, we ran into this on the build also, said we were missing symbol
verify_compat_iovec, so ICONFIG_COMPATthat one also.
I'll add this to my tree when I get a chance, thanks Jim.
Quoted 14 lines · David S. Miller
arch/sparc64/kernel/process.c +1
-0@@ -164,6 +164,7 @@ void machine_restart(char * cmd)panic ("Reboot failed!" ); } +#ifdef CONFIG_COMPAT static void show_regwindow32 (struct pt_regs *regs) {struct reg_window32 __user *rw;
arch/sparc64/kernel/process.c static void show_regwindow32(struct pt_r · line 198
Quoted 9 lines
arch/sparc64/kernel/process.c +3
-0@@ -189,6 +190,9 @@ static void show_regwindow32(struct pt_r r_w.ins[0 ], r_w.ins[1 ], r_w.ins[2 ], r_w.ins[3 ], r_w.ins[4], r_w.ins[5], r_w.ins[6], r_w.ins[7]); } +#else +#define show_regwindow32 (regs) do { } while (0) +#endif static void show_regwindow (struct pt_regs *regs) {
Worked like a champ. Thank you.
Signature · 3 lines
---- Jim Gifford [email protected]
From: Jim Gifford <[email protected]>
Date: Wed, 18 Jan 2006 16:32:43 -0800
Quoted 1 line
Worked like a champ. Thank you.
Thanks for testing. That fix is in Linus's tree now, I'll push your symbol export fix later.