public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* 2.6.7: preempt + sysfs = BUG on ppc
@ 2004-06-20 15:39 Tom Vier
  2004-06-20 21:49 ` Andrew Morton
  0 siblings, 1 reply; 5+ messages in thread
From: Tom Vier @ 2004-06-20 15:39 UTC (permalink / raw)
  To: linux-kernel

i forgot to exclude /sys when i ran rsync. this is easily reproducable.

kernel BUG in fill_read_buffer at fs/sysfs/file.c:92!
Oops: Exception in kernel mode, sig: 5 [#1]
PREEMPT 
NIP: C009687C LR: C0096870 SP: D1587EA0 REGS: d1587df0 TRAP: 0700    Not tainted
MSR: 00029032 EE: 1 PR: 0 FP: 0 ME: 1 IR/DR: 11
TASK = c07b4060[879] 'rsync' THREAD: d1586000Last syscall: 3 
GPR00: 00000001 D1587EA0 C07B4060 FFFFFFEA C7E38000 D327F000 00007F11 00000000 
GPR08: 00000000 00000000 00000000 D1586000 20002442 1004CFE4 00000000 00000000 
GPR16: 00001000 10040000 10040000 10040000 10040000 00000003 00001000 00000000 
GPR24: 00001000 00000000 00000000 00000000 C010E348 C0264BEC D1B64F1C C079F1A8 
NIP [c009687c] fill_read_buffer+0x70/0xb4
LR [c0096870] fill_read_buffer+0x64/0xb4
Call trace:
 [c0096a28] sysfs_read_file+0x5c/0x78
 [c005ad68] vfs_read+0xdc/0x128
 [c005afd8] sys_read+0x40/0x74
 [c0005b20] ret_from_syscall+0x0/0x44

kernel BUG in fill_read_buffer at fs/sysfs/file.c:92!
Oops: Exception in kernel mode, sig: 5 [#2]
PREEMPT 
NIP: C009687C LR: C0096870 SP: C577FEA0 REGS: c577fdf0 TRAP: 0700    Not tainted
MSR: 00029032 EE: 1 PR: 0 FP: 0 ME: 1 IR/DR: 11
TASK = c07b4060[1230] 'rsync' THREAD: c577e000Last syscall: 3 
GPR00: 00000001 C577FEA0 C07B4060 FFFFFFEA C4828000 D327F000 00007F11 00000000 
GPR08: 00000000 00000000 00000000 C577E000 20002442 1004CFE4 00000000 00000000 
GPR16: 00001000 10040000 10040000 10040000 10040000 00000003 00001000 00000000 
GPR24: 00001000 00000000 00000000 00000000 C010E348 C0264BEC D1B6433C C079F1A8 
NIP [c009687c] fill_read_buffer+0x70/0xb4
LR [c0096870] fill_read_buffer+0x64/0xb4
Call trace:
 [c0096a28] sysfs_read_file+0x5c/0x78
 [c005ad68] vfs_read+0xdc/0x128
 [c005afd8] sys_read+0x40/0x74
 [c0005b20] ret_from_syscall+0x0/0x44

-- 
Tom Vier <tmv@comcast.net>
DSA Key ID 0x15741ECE


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: 2.6.7: preempt + sysfs = BUG on ppc
  2004-06-20 15:39 2.6.7: preempt + sysfs = BUG on ppc Tom Vier
@ 2004-06-20 21:49 ` Andrew Morton
  2004-06-21 23:44   ` Tom Vier
  0 siblings, 1 reply; 5+ messages in thread
From: Andrew Morton @ 2004-06-20 21:49 UTC (permalink / raw)
  To: Tom Vier; +Cc: linux-kernel

Tom Vier <tmv@comcast.net> wrote:
>
> i forgot to exclude /sys when i ran rsync. this is easily reproducable.
> 
>  kernel BUG in fill_read_buffer at fs/sysfs/file.c:92!

Please add this patch, then retest:

--- 25/fs/sysfs/file.c~sysfs-overflow-debug	2004-06-20 14:44:44.272707136 -0700
+++ 25-akpm/fs/sysfs/file.c	2004-06-20 14:48:23.580367304 -0700
@@ -5,6 +5,8 @@
 #include <linux/module.h>
 #include <linux/dnotify.h>
 #include <linux/kobject.h>
+#include <linux/kallsyms.h>
+
 #include <asm/uaccess.h>
 
 #include "sysfs.h"
@@ -83,7 +85,13 @@ static int fill_read_buffer(struct file 
 		return -ENOMEM;
 
 	count = ops->show(kobj,attr,buffer->page);
-	BUG_ON(count > PAGE_SIZE);
+	if (count > PAGE_SIZE) {
+		printk("%s: show handler overrun\n", __FUNCTION__);
+		printk("->show handler: 0x%p",  ops->show);
+		print_symbol(" (%s)", (unsigned long)ops->show);
+		printk("\n");
+		BUG();
+	}
 	if (count >= 0)
 		buffer->count = count;
 	else
_


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: 2.6.7: preempt + sysfs = BUG on ppc
  2004-06-20 21:49 ` Andrew Morton
@ 2004-06-21 23:44   ` Tom Vier
  2004-06-22  0:26     ` Andrew Morton
  0 siblings, 1 reply; 5+ messages in thread
From: Tom Vier @ 2004-06-21 23:44 UTC (permalink / raw)
  To: Andrew Morton; +Cc: linux-kernel

On Sun, Jun 20, 2004 at 02:49:06PM -0700, Andrew Morton wrote:
> >  kernel BUG in fill_read_buffer at fs/sysfs/file.c:92!
> 
> Please add this patch, then retest:
> 
> --- 25/fs/sysfs/file.c~sysfs-overflow-debug	2004-06-20 14:44:44.272707136 -0700
> +++ 25-akpm/fs/sysfs/file.c	2004-06-20 14:48:23.580367304 -0700

here ya go. it's /sys/class/net/eth1/wireless/beacon. that's for my airport
card (apple branded lucent chip). i would look at its sysfs code, but i'm
not familiar with it at all (and i'm busy).


fill_read_buffer: show handler overrun
->show handler: 0xc010e38c (class_device_attr_show+0x0/0x48)
kernel BUG in fill_read_buffer at fs/sysfs/file.c:99!
Oops: Exception in kernel mode, sig: 5 [#1]
PREEMPT 
NIP: C00968EC LR: C00968EC SP: D19A7EA0 REGS: d19a7df0 TRAP: 0700    Not tainted
MSR: 00029032 EE: 1 PR: 0 FP: 0 ME: 1 IR/DR: 11
TASK = d1366d80[878] 'rsync' THREAD: d19a6000Last syscall: 3 
GPR00: C00968EC D19A7EA0 D1366D80 00000001 00001AE3 FFFFFFFF C02D9674 C02D970C 
GPR08: 0019377F C0290000 00000000 D19A6000 80008424 1004CFE4 00000000 00000004 
GPR16: 10057B08 10040000 10057880 00000000 00001000 FFFFFFFF 00001000 00000000 
GPR24: 00001000 00000000 00000000 00000000 C025DFCC CB2598FC C079F1A8 FFFFFFEA 
NIP [c00968ec] fill_read_buffer+0xe0/0xf8
LR [c00968ec] fill_read_buffer+0xe0/0xf8
Call trace:
 [c0096a6c] sysfs_read_file+0x5c/0x78
 [c005ad68] vfs_read+0xdc/0x128
 [c005afd8] sys_read+0x40/0x74
 [c0005b20] ret_from_syscall+0x0/0x44

-- 
Tom Vier <tmv@comcast.net>
DSA Key ID 0x15741ECE

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: 2.6.7: preempt + sysfs = BUG on ppc
  2004-06-21 23:44   ` Tom Vier
@ 2004-06-22  0:26     ` Andrew Morton
  2004-06-23  0:50       ` Tom Vier
  0 siblings, 1 reply; 5+ messages in thread
From: Andrew Morton @ 2004-06-22  0:26 UTC (permalink / raw)
  To: Tom Vier; +Cc: linux-kernel

Tom Vier <tmv@comcast.net> wrote:
>
> On Sun, Jun 20, 2004 at 02:49:06PM -0700, Andrew Morton wrote:
> > >  kernel BUG in fill_read_buffer at fs/sysfs/file.c:92!
> > 
> > Please add this patch, then retest:
> > 
> > --- 25/fs/sysfs/file.c~sysfs-overflow-debug	2004-06-20 14:44:44.272707136 -0700
> > +++ 25-akpm/fs/sysfs/file.c	2004-06-20 14:48:23.580367304 -0700
> 
> here ya go. it's /sys/class/net/eth1/wireless/beacon. that's for my airport
> card (apple branded lucent chip). i would look at its sysfs code, but i'm
> not familiar with it at all (and i'm busy).

What device driver is this thing using?

> 
> fill_read_buffer: show handler overrun
> ->show handler: 0xc010e38c (class_device_attr_show+0x0/0x48)
> kernel BUG in fill_read_buffer at fs/sysfs/file.c:99!
> Oops: Exception in kernel mode, sig: 5 [#1]
> PREEMPT 
> NIP: C00968EC LR: C00968EC SP: D19A7EA0 REGS: d19a7df0 TRAP: 0700    Not tainted
> MSR: 00029032 EE: 1 PR: 0 FP: 0 ME: 1 IR/DR: 11
> TASK = d1366d80[878] 'rsync' THREAD: d19a6000Last syscall: 3 
> GPR00: C00968EC D19A7EA0 D1366D80 00000001 00001AE3 FFFFFFFF C02D9674 C02D970C 
> GPR08: 0019377F C0290000 00000000 D19A6000 80008424 1004CFE4 00000000 00000004 
> GPR16: 10057B08 10040000 10057880 00000000 00001000 FFFFFFFF 00001000 00000000 
> GPR24: 00001000 00000000 00000000 00000000 C025DFCC CB2598FC C079F1A8 FFFFFFEA 
> NIP [c00968ec] fill_read_buffer+0xe0/0xf8
> LR [c00968ec] fill_read_buffer+0xe0/0xf8
> Call trace:
>  [c0096a6c] sysfs_read_file+0x5c/0x78
>  [c005ad68] vfs_read+0xdc/0x128
>  [c005afd8] sys_read+0x40/0x74
>  [c0005b20] ret_from_syscall+0x0/0x44
> 
> -- 
> Tom Vier <tmv@comcast.net>
> DSA Key ID 0x15741ECE

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: 2.6.7: preempt + sysfs = BUG on ppc
  2004-06-22  0:26     ` Andrew Morton
@ 2004-06-23  0:50       ` Tom Vier
  0 siblings, 0 replies; 5+ messages in thread
From: Tom Vier @ 2004-06-23  0:50 UTC (permalink / raw)
  To: Andrew Morton; +Cc: linux-kernel

On Mon, Jun 21, 2004 at 05:26:11PM -0700, Andrew Morton wrote:
> > here ya go. it's /sys/class/net/eth1/wireless/beacon. that's for my airport
> > card (apple branded lucent chip). i would look at its sysfs code, but i'm
> > not familiar with it at all (and i'm busy).
> 
> What device driver is this thing using?

hermes.

-- 
Tom Vier <tmv@comcast.net>
DSA Key ID 0x15741ECE

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2004-06-23  0:50 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-06-20 15:39 2.6.7: preempt + sysfs = BUG on ppc Tom Vier
2004-06-20 21:49 ` Andrew Morton
2004-06-21 23:44   ` Tom Vier
2004-06-22  0:26     ` Andrew Morton
2004-06-23  0:50       ` Tom Vier

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox