Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752931AbYACNvj (ORCPT ); Thu, 3 Jan 2008 08:51:39 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751212AbYACNvb (ORCPT ); Thu, 3 Jan 2008 08:51:31 -0500 Received: from courier.cs.helsinki.fi ([128.214.9.1]:58215 "EHLO mail.cs.helsinki.fi" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750939AbYACNva (ORCPT ); Thu, 3 Jan 2008 08:51:30 -0500 Date: Thu, 3 Jan 2008 15:51:28 +0200 (EET) From: Pekka J Enberg To: Jiri Slaby cc: Al Viro , Linux Kernel Mailing List Subject: Re: isofs oops - d_splice_alias+0x1f (2.6.24-rc5-mm1) In-Reply-To: <477CE1E0.4010504@gmail.com> Message-ID: References: <477CE1E0.4010504@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1590 Lines: 56 Hi Jiri, On Thu, 3 Jan 2008, Jiri Slaby wrote: > this happened, while playing with broken dvd. [snip] > Buffer I/O error on device sr0, logical block 5441 > end_request: I/O error, dev sr0, sector 136 > ISOFS: unable to read i-node block > Unable to handle kernel NULL pointer dereference at 00000000000000ad RIP: > [] d_splice_alias+0x1f/0x100 [snip] > Call Trace: > [] :isofs:isofs_lookup+0x395/0x4a0 > [] d_alloc+0x2b/0x1d0 > [] do_lookup+0x1ac/0x200 Does the following patch fix it? Pekka [PATCH] isofs: check for bad inode in isofs_lookup From: Pekka Enberg If isofs_read_inode() fails to read one of the inode blocks from disk, it returns a bad inode. Signed-off-by: Pekka Enberg --- fs/isofs/namei.c | 5 +++++ 1 file changed, 5 insertions(+) Index: linux-2.6/fs/isofs/namei.c =================================================================== --- linux-2.6.orig/fs/isofs/namei.c +++ linux-2.6/fs/isofs/namei.c @@ -183,6 +183,11 @@ struct dentry *isofs_lookup(struct inode unlock_kernel(); return ERR_PTR(-EACCES); } + if (is_bad_inode(inode)) { + unlock_kernel(); + iput(inode); + return ERR_PTR(-ENOENT); + } } unlock_kernel(); return d_splice_alias(inode, dentry); -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/