From: Andrew Morton <akpm@osdl.org>
To: Tom Vier <tmv@comcast.net>
Cc: linux-kernel@vger.kernel.org
Subject: Re: 2.6.7: preempt + sysfs = BUG on ppc
Date: Sun, 20 Jun 2004 14:49:06 -0700 [thread overview]
Message-ID: <20040620144906.095a4f93.akpm@osdl.org> (raw)
In-Reply-To: <20040620153922.GA20103@zero>
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
_
next prev parent reply other threads:[~2004-06-20 21:50 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-06-20 15:39 Tom Vier
2004-06-20 21:49 ` Andrew Morton [this message]
2004-06-21 23:44 ` Tom Vier
2004-06-22 0:26 ` Andrew Morton
2004-06-23 0:50 ` Tom Vier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20040620144906.095a4f93.akpm@osdl.org \
--to=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=tmv@comcast.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®