Re: [PATCH] 2.5.68-bk1 crash in devfs_remove() for defpts files

Christoph Hellwig
2003-04-21T18:49:44Z

On Mon, Apr 21, 2003 at 02:53:54PM -0400, Pavel Roskin wrote:
> On Mon, 21 Apr 2003, Christoph Hellwig wrote:
>
> > On Mon, Apr 21, 2003 at 07:55:55PM +0200, Christoph Hellwig wrote:
> > > Could you please try this patch?
> >
> > Better this one :) Sorry.
>
> No, it doesn't help, although the stack trace is different this time:

Hmm. Can you please apply the following patch in addition and
see what the printk I added sais?

--- 1.87/fs/devfs/base.c Mon Apr 21 10:43:52 2003
+++ edited/fs/devfs/base.c Mon Apr 21 19:36:20 2003
@@ -1754,6 +1803,12 @@
n = vsnprintf(buf, 64, fmt, args);
if (n < 64 && buf[0]) {
devfs_handle_t de = _devfs_find_entry(NULL, buf, 0);
+
+ if (!de) {
+ printk(KERN_WARNING "%s: no entry for %s!\n",
+ __FUNCTION__, buf);
+ return;
+ }

write_lock(&de->parent->u.dir.lock);
_devfs_unregister(de->parent, de);