public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Keith Owens <kaos@sgi.com>
To: linux-kernel@vger.kernel.org
Cc: viro@math.psu.edu, marcelo.tosatti@cyclades.com
Subject: [patch 2.4.28-rc1] Avoid oops in proc_delete_inode
Date: Thu, 04 Nov 2004 13:35:33 +1100	[thread overview]
Message-ID: <9663.1099535733@kao2.melbourne.sgi.com> (raw)

Under heavy load, vmstat, top and other programs that access /proc can
oops.  PROC_INODE_PROPER(inode) is sometimes false for pid entries
(usually zombies), but inode->u.generic_ip is not NULL.

Backport a fix by AL Viro from 2.5.7-pre2 to 2.4.28-rc1.

Signed-off-by: Keith Owens <kaos@sgi.com>

Index: 2.4.28-rc1/fs/proc/base.c
===================================================================
--- 2.4.28-rc1.orig/fs/proc/base.c	2004-08-08 10:10:49.000000000 +1000
+++ 2.4.28-rc1/fs/proc/base.c	2004-11-04 13:25:16.402602459 +1100
@@ -780,6 +780,7 @@ out:
 	return inode;
 
 out_unlock:
+	node->u.generic_ip = NULL;
 	iput(inode);
 	return NULL;
 }


             reply	other threads:[~2004-11-04  2:36 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-11-04  2:35 Keith Owens [this message]
2004-11-04 15:29 ` [patch 2.4.28-rc1] Avoid oops in proc_delete_inode Marc-Christian Petersen
2004-11-04 17:31   ` Marcelo Tosatti
2004-11-04 20:35   ` Keith Owens

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=9663.1099535733@kao2.melbourne.sgi.com \
    --to=kaos@sgi.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marcelo.tosatti@cyclades.com \
    --cc=viro@math.psu.edu \
    /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