[PATCH] allow CONFIG_NET=n on ppc64

STALE7973d

6 messages, 5 authors, 2004-10-04 · open the first message on its own page

[PATCH] allow CONFIG_NET=n on ppc64

From: Olaf Hering <hidden>
Date: 2004-09-29 20:02:21

The attached minimal config does not compile on ppc64.
I was able to boot the resulting binary with this patch.


Signed-off-by: Olaf Hering <redacted>


diff -purNX /suse/olh/kernel/kernel_exclude.txt linux-2.6.9-rc2/arch/ppc64/kernel/misc.S linux-2.6.9-rc2.ppc64/arch/ppc64/kernel/misc.S
--- linux-2.6.9-rc2/arch/ppc64/kernel/misc.S	2004-09-13 07:33:23.000000000 +0200
+++ linux-2.6.9-rc2.ppc64/arch/ppc64/kernel/misc.S	2004-09-29 21:00:44.909074755 +0200
@@ -703,7 +703,11 @@ _GLOBAL(sys_call_table32)
 	.llong .compat_sys_statfs
 	.llong .compat_sys_fstatfs		/* 100 */
 	.llong .sys_ni_syscall		/* old ioperm syscall */
+#ifdef CONFIG_NET
 	.llong .compat_sys_socketcall
+#else
+	.llong .sys_ni_syscall		/* old ioperm syscall */
+#endif
 	.llong .sys32_syslog
 	.llong .compat_sys_setitimer
 	.llong .compat_sys_getitimer		/* 105 */
diff -purNX /suse/olh/kernel/kernel_exclude.txt linux-2.6.9-rc2/include/net/sock.h linux-2.6.9-rc2.ppc64/include/net/sock.h
--- linux-2.6.9-rc2/include/net/sock.h	2004-09-13 07:33:11.000000000 +0200
+++ linux-2.6.9-rc2.ppc64/include/net/sock.h	2004-09-29 21:06:03.544933591 +0200
@@ -1327,6 +1327,13 @@ static inline void sock_valbool_flag(str
 extern __u32 sysctl_wmem_max;
 extern __u32 sysctl_rmem_max;
 
+#ifdef CONFIG_NET
 int siocdevprivate_ioctl(unsigned int fd, unsigned int cmd, unsigned long arg);
+#else
+static inline int siocdevprivate_ioctl(unsigned int fd, unsigned int cmd, unsigned long arg)
+{
+	return -ENODEV;
+}
+#endif
 
 #endif	/* _SOCK_H */
-- 
USB is for mice, FireWire is for men!

sUse lINUX ag, nÜRNBERG

Re: [PATCH] allow CONFIG_NET=n on ppc64

From: Andi Kleen <hidden>
Date: 2004-09-29 20:17:34

On Wed, Sep 29, 2004 at 10:01:58PM +0200, Olaf Hering wrote:
The attached minimal config does not compile on ppc64.
I was able to boot the resulting binary with this patch.
I already fixed this some time ago, but the patch must have disappeared.
quoted hunk
diff -purNX /suse/olh/kernel/kernel_exclude.txt linux-2.6.9-rc2/arch/ppc64/kernel/misc.S linux-2.6.9-rc2.ppc64/arch/ppc64/kernel/misc.S
--- linux-2.6.9-rc2/arch/ppc64/kernel/misc.S	2004-09-13 07:33:23.000000000 +0200
+++ linux-2.6.9-rc2.ppc64/arch/ppc64/kernel/misc.S	2004-09-29 21:00:44.909074755 +0200
@@ -703,7 +703,11 @@ _GLOBAL(sys_call_table32)
 	.llong .compat_sys_statfs
 	.llong .compat_sys_fstatfs		/* 100 */
 	.llong .sys_ni_syscall		/* old ioperm syscall */
+#ifdef CONFIG_NET
 	.llong .compat_sys_socketcall
+#else
+	.llong .sys_ni_syscall		/* old ioperm syscall */
+#endif
Right fix is to declare compat_sys_socketcall as as cond_syscall() 
in sys.c

-Andi

Re: [PATCH] allow CONFIG_NET=n on ppc64

From: Olaf Hering <hidden>
Date: 2004-10-02 15:31:36

 On Wed, Sep 29, Andi Kleen wrote:
On Wed, Sep 29, 2004 at 10:01:58PM +0200, Olaf Hering wrote:
quoted
The attached minimal config does not compile on ppc64.
I was able to boot the resulting binary with this patch.
Right fix is to declare compat_sys_socketcall as as cond_syscall() 
in sys.c
ok.

Signed-off-by: Olaf Hering <redacted>

diff -purNX /suse/olh/kernel/kernel_exclude.txt linux-2.6.9-rc3-bk2/include/net/sock.h linux-2.6.9-rc3-bk2.nonet/include/net/sock.h
--- linux-2.6.9-rc3-bk2/include/net/sock.h	2004-09-30 05:05:21.000000000 +0200
+++ linux-2.6.9-rc3-bk2.nonet/include/net/sock.h	2004-10-02 17:24:23.666152810 +0200
@@ -1336,6 +1336,13 @@ static inline void sock_valbool_flag(str
 extern __u32 sysctl_wmem_max;
 extern __u32 sysctl_rmem_max;
 
+#ifdef CONFIG_NET
 int siocdevprivate_ioctl(unsigned int fd, unsigned int cmd, unsigned long arg);
+#else
+static inline int siocdevprivate_ioctl(unsigned int fd, unsigned int cmd, unsigned long arg)
+{
+	return -ENODEV;
+}
+#endif
 
 #endif	/* _SOCK_H */
diff -purNX /suse/olh/kernel/kernel_exclude.txt linux-2.6.9-rc3-bk2/kernel/sys.c linux-2.6.9-rc3-bk2.nonet/kernel/sys.c
--- linux-2.6.9-rc3-bk2/kernel/sys.c	2004-09-30 05:03:55.000000000 +0200
+++ linux-2.6.9-rc3-bk2.nonet/kernel/sys.c	2004-10-02 17:05:49.589116448 +0200
@@ -282,6 +282,7 @@ cond_syscall(compat_set_mempolicy)
 cond_syscall(sys_pciconfig_read)
 cond_syscall(sys_pciconfig_write)
 cond_syscall(sys_pciconfig_iobase)
+cond_syscall(compat_sys_socketcall)
 
 static int set_one_prio(struct task_struct *p, int niceval, int error)
 {
-- 
USB is for mice, FireWire is for men!

sUse lINUX ag, nÜRNBERG

Re: [PATCH] allow CONFIG_NET=n on ppc64

From: "David S. Miller" <davem@davemloft.net>
Date: 2004-10-03 22:01:22

Olaf, as I requested of you last time, please use attachments for
your patches since I can never apply them cleanly when you
inline them to the main body text.

Thanks a lot.

HELP NEEDED!!!

From: Pranav <hidden>
Date: 2004-10-04 18:07:14

Hi everyone,

            I have got a small problem regarding configuring my ethernet
card,while loading the eth0 driver the kernel performs auto-probing for the
device and configures the eth0 to half-duplex.

I used command line arguments while loading modules
insmod 8139too io=0x280 irq=10 duplex=2

but still it performs the autoprobing overriding the parameters.

Please help me out of this problem,i want to configure my ethernetcard to
fullduplex.

Waiting for a reply...

With Regards,
Pranav.

Re: HELP NEEDED!!!

From: Jeff Garzik <hidden>
Date: 2004-10-04 18:15:18

Pranav wrote:
Hi everyone,

            I have got a small problem regarding configuring my ethernet
card,while loading the eth0 driver the kernel performs auto-probing for the
device and configures the eth0 to half-duplex.

I used command line arguments while loading modules
insmod 8139too io=0x280 irq=10 duplex=2
8139too module does not take any arguments like io= or irq=.  PCI cards 
do not need such parameters.

You may use ethtool to select half-duplex or full-duplex.

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