public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: Dave Young <hidave.darkstar@gmail.com>
Cc: Valdis.Kletnieks@vt.edu, viro@zeniv.linux.org.uk,
	linux-kernel@vger.kernel.org, David Howells <dhowells@redhat.com>
Subject: Re: 2.6.24-rc5-mm1 - wonky disk cache and CDROM behavior...
Date: Mon, 17 Dec 2007 18:52:13 -0800	[thread overview]
Message-ID: <20071217185213.d0d02149.akpm@linux-foundation.org> (raw)
In-Reply-To: <20071218023732.GA3215@darkstar.te-china.tietoenator.com>

On Tue, 18 Dec 2007 10:37:32 +0800 Dave Young <hidave.darkstar@gmail.com> wrote:

> On Mon, Dec 17, 2007 at 09:07:56PM -0500, Valdis.Kletnieks@vt.edu wrote:
> > On Mon, 17 Dec 2007 14:56:44 PST, Andrew Morton said:
> > 
> > (Adding Al Viro to the list, he's listed as "file systems" and MAINTAINERS
> > doesn't list 'isofs' anyplace.  Will Al or Andrew please vector to whoever
> > actually does that code?)
> > 
> > > > I try it again, and it reports it died at the same exact place, but in about
> > > > 2 seconds flat, and reports 91M/sec transfer.  OK, that's *weird*, I didn't
> > > > think that blocks read from /dev/cdrom would get cached, but OK.
> > > 
> > > It'll remain cached if something is holding the device open.
> > 
> > Does it need to be "device open", or are there other things as well? If the
> > drop_cache was hosed, that would result in the same symptoms, no?
> > 
> > > Something's holding s_umount for writing I guess.  Possibly busted error
> > > handling somewhere totally different.
> > 
> > Aha - found what was holding it - an attempt to loopback mount the truncated
> > file (before I realized it was truncated) had failed - I had gotten a 'Killed'
> > back from the mount, but I didn't realize it had pulled an actual oops:
> > 
> > Dec 17 15:54:33 turing-police kernel: [14503.402385] attempt to access beyond end of device
> > Dec 17 15:54:33 turing-police kernel: [14503.402391] loop1: rw=0, want=1284500, limit=314240
> > Dec 17 15:54:33 turing-police kernel: [14503.402395] ISOFS: unable to read i-node block
> > Dec 17 15:54:33 turing-police kernel: [14503.402428] Unable to handle kernel NULL pointer dereference at 000000000000010b RIP:
> > Dec 17 15:54:33 turing-police kernel: [14503.402440]  [<ffffffff802a096b>] iput+0x11/0x80
> > ...
> > Dec 17 15:54:33 turing-police kernel: [14503.403008] Call Trace:
> > Dec 17 15:54:33 turing-police kernel: [14503.403026]  [<ffffffff802ff73e>] isofs_fill_super+0x7e9/0xa6b
> > Dec 17 15:54:33 turing-police kernel: [14503.403045]  [<ffffffff80523d28>] __down_write_nested+0x3d/0xa1
> > Dec 17 15:54:33 turing-police kernel: [14503.403061]  [<ffffffff80523d97>] __down_write+0xb/0xd
> > Dec 17 15:54:33 turing-police kernel: [14503.403076]  [<ffffffff8028fb63>] sget+0x397/0x3a9
> > Dec 17 15:54:33 turing-police kernel: [14503.403090]  [<ffffffff8028f204>] set_bdev_super+0x0/0x14
> > Dec 17 15:54:33 turing-police kernel: [14503.403106]  [<ffffffff80290301>] get_sb_bdev+0x109/0x157
> > Dec 17 15:54:33 turing-police kernel: [14503.403120]  [<ffffffff802fef55>] isofs_fill_super+0x0/0xa6b
> > Dec 17 15:54:33 turing-police kernel: [14503.403138]  [<ffffffff802fe2e9>] isofs_get_sb+0x13/0x15
> > Dec 17 15:54:33 turing-police kernel: [14503.403151]  [<ffffffff80290075>] vfs_kern_mount+0x90/0x11a
> > Dec 17 15:54:33 turing-police kernel: [14503.403167]  [<ffffffff8029015c>] do_kern_mount+0x47/0xe3
> > Dec 17 15:54:33 turing-police kernel: [14503.403183]  [<ffffffff802a5012>] do_mount+0x717/0x78a
> > Dec 17 15:54:33 turing-police kernel: [14503.403199]  [<ffffffff805242fc>] _read_lock_irq+0x9/0xb
> > Dec 17 15:54:33 turing-police kernel: [14503.403212]  [<ffffffff8026cce0>] find_lock_page+0x8c/0x97
> > Dec 17 15:54:33 turing-police kernel: [14503.403227]  [<ffffffff8026ecb6>] filemap_fault+0x1fa/0x3c6
> > Dec 17 15:54:33 turing-police kernel: [14503.403241]  [<ffffffff8026cb6b>] unlock_page+0x2d/0x31
> > Dec 17 15:54:33 turing-police kernel: [14503.403254]  [<ffffffff8027925c>] __do_fault+0x38d/0x3c3
> > Dec 17 15:54:33 turing-police kernel: [14503.403274]  [<ffffffff8027ab68>] handle_mm_fault+0x36d/0x6e9
> > Dec 17 15:54:33 turing-police kernel: [14503.403293]  [<ffffffff80271903>] __alloc_pages+0x68/0x2f6
> > Dec 17 15:54:33 turing-police kernel: [14503.403314]  [<ffffffff802a510e>] sys_mount+0x89/0xcb
> > Dec 17 15:54:33 turing-police kernel: [14503.403328]  [<ffffffff80214f34>] syscall_trace_enter+0x97/0x9b
> > Dec 17 15:54:33 turing-police kernel: [14503.403344]  [<ffffffff8020c34c>] tracesys+0xdc/0xe1
> > Dec 17 15:54:33 turing-police kernel: [14503.403359]
> > Dec 17 15:54:33 turing-police kernel: [14503.403366]
> > Dec 17 15:54:33 turing-police kernel: [14503.403367] Code: 48 8b 87 10 01 00 00 48 83 bf 38 02 00 00 40 48 8b 40 38 75
> > 
> > I don't mind it failing the mount, but the oops seems excessive.  I suspect
> > that *somewhere* in that stack trace, we're wanting something like a
> > 
> > 	if (!foo_ptr)
> > 		return -EIO;
> > 
> > but I admit not being competent enough to decide where that should be.
> > 
> 
> Hi,
> Could you please try the below patch:
> 
> Signed-off-by: Dave Young <hidave.darkstar@gmail.com> 
> 
> ---
> fs/isofs/inode.c |    2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff -upr linux/fs/isofs/inode.c linux.new/fs/isofs/inode.c
> --- linux/fs/isofs/inode.c	2007-12-18 10:31:12.000000000 +0800
> +++ linux.new/fs/isofs/inode.c	2007-12-18 10:31:56.000000000 +0800
> @@ -1414,7 +1414,7 @@ struct inode *isofs_iget(struct super_bl
>  		ret = isofs_read_inode(inode);
>  		if (ret < 0) {
>  			iget_failed(inode);
> -			inode = ERR_PTR(ret);
> +			return NULL;
>  		} else {
>  			unlock_new_inode(inode);
>  		}
> 

Yup.

David, this is concerning.  More such error-path bugs in that code will
take years and years to get found and fixed.  The best way to eliminate
them is a line-by-line re-review of the patchset.


  reply	other threads:[~2007-12-18  2:53 UTC|newest]

Thread overview: 76+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-13 10:40 2.6.24-rc5-mm1 Andrew Morton
2007-12-13 11:59 ` 2.6.24-rc5-mm1 kobject changes broken with hvcs driver on powerpc - regression Kamalesh Babulal
2007-12-13 16:22   ` Greg KH
2007-12-13 12:28 ` 2.6.24-rc5-mm1 Gautham R Shenoy
2007-12-13 21:15   ` 2.6.24-rc5-mm1 Andrew Morton
2007-12-14  9:49   ` 2.6.24-rc5-mm1 Andrew Morton
2007-12-14 13:15     ` 2.6.24-rc5-mm1 Gregory Haskins
2007-12-13 14:18 ` 2.6.24-rc5-mm1 Pierre Peiffer
2007-12-13 15:01   ` 2.6.24-rc5-mm1 Benjamin Thery
2007-12-13 16:07     ` 2.6.24-rc5-mm1 Borislav Petkov
2007-12-13 17:54       ` 2.6.24-rc5-mm1 Adrian Bunk
2007-12-13 17:45     ` 2.6.24-rc5-mm1 David Miller
2007-12-14  2:08       ` 2.6.24-rc5-mm1 Herbert Xu
2007-12-14 19:26         ` 2.6.24-rc5-mm1 David Miller
2007-12-13 14:56 ` 2.6.24-rc5-mm1 regression - kernel warning on tcp_fastretrans_alert() Kamalesh Babulal
2007-12-13 19:55   ` Andrew Morton
2007-12-13 15:16 ` 2.6.24-rc5-mm1 - build failures due to kobject changes Kamalesh Babulal
2007-12-13 16:21   ` Greg KH
2007-12-13 17:46 ` (was Re: 2.6.24-rc5-mm1) crypto/authenc.c select symbol in Kconfig Borislav Petkov
2007-12-14  8:53   ` Herbert Xu
2007-12-14  5:32 ` 2.6.24-rc5-mm1 Dave Young
2007-12-14 15:44   ` 2.6.24-rc5-mm1 Alan Stern
2007-12-17  1:14     ` 2.6.24-rc5-mm1 Dave Young
2007-12-19  7:49       ` 2.6.24-rc5-mm1 Dave Young
2007-12-19 16:07         ` 2.6.24-rc5-mm1 Alan Stern
2007-12-20  0:43           ` 2.6.24-rc5-mm1 Dave Young
2007-12-20  3:34             ` 2.6.24-rc5-mm1 Alan Stern
2007-12-20  4:32               ` 2.6.24-rc5-mm1 Dave Young
2007-12-14 14:08 ` 2.6.24-rc5-mm1 Dhaval Giani
2007-12-15 19:20 ` 2.6.24-rc5-mm1 Alexey Dobriyan
2007-12-16  9:10   ` 2.6.24-rc5-mm1 Andrew Morton
2007-12-15 23:59 ` broken suspend, sometimes (drm related) [Was: 2.6.24-rc5-mm1] Jiri Slaby
2007-12-17 16:55   ` Jesse Barnes
2007-12-16  0:18 ` 2.6.24-rc5-mm1: cat /proc/net/packet -> oops Mariusz Kozlowski
2007-12-16  3:07   ` Herbert Xu
2007-12-16  3:41     ` [PACKET]: Fix /proc/net/packet crash due to bogus private pointer Herbert Xu
2007-12-16 10:48       ` Mariusz Kozlowski
2007-12-16 22:04       ` David Miller
2007-12-16 10:11 ` 2.6.24-rc5-mm1: problems with cat /proc/kpageflags Mariusz Kozlowski
2007-12-16 10:14   ` Mariusz Kozlowski
2007-12-16 10:41     ` Mariusz Kozlowski
2007-12-16 11:40       ` Mariusz Kozlowski
2007-12-16 18:27         ` Matt Mackall
2007-12-16 18:48           ` Mariusz Kozlowski
2007-12-16 19:10             ` Mariusz Kozlowski
2007-12-17  2:11               ` Matt Mackall
2007-12-17  4:26                 ` David Miller
2007-12-17  6:39                   ` Andrew Morton
2007-12-17 14:55                     ` Matt Mackall
2007-12-20 12:53                       ` David Miller
2007-12-20 17:45                         ` Matt Mackall
2007-12-20 19:47                           ` Mariusz Kozlowski
2007-12-21  0:17                             ` David Miller
2007-12-21  1:06                               ` Matt Mackall
2007-12-21  3:15                                 ` David Miller
2007-12-21 21:51                                 ` Mariusz Kozlowski
2007-12-22  5:00                                   ` Andrew Morton
2007-12-17 19:05                 ` Mariusz Kozlowski
2007-12-17 22:44 ` 2.6.24-rc5-mm1 - wonky disk cache and CDROM behavior Valdis.Kletnieks
2007-12-17 22:56   ` Andrew Morton
2007-12-18  2:07     ` Valdis.Kletnieks
2007-12-18  2:37       ` Dave Young
2007-12-18  2:52         ` Andrew Morton [this message]
2007-12-19  1:22           ` David Howells
2007-12-19  1:33             ` Dave Young
2007-12-19  2:04             ` Andrew Morton
2007-12-19  3:30               ` Jeff Dike
2007-12-18  5:52         ` Valdis.Kletnieks
2007-12-18  6:10 ` 2.6.24-rc5-mm1 - IPv6 throws section mismatches Valdis.Kletnieks
2007-12-18 15:12   ` Daniel Lezcano
2007-12-20 16:55 ` 2.6.24-rc5-mm1 Jason Wessel
2007-12-20 23:11   ` 2.6.24-rc5-mm1 Andrew Morton
2007-12-21 13:46     ` 2.6.24-rc5-mm1 Jason Wessel
2007-12-20 20:57 ` 2.6.24-rc5-mm1 - SCSI/blkdev probing hang Rik van Riel
2007-12-20 21:22   ` Andrew Morton
2007-12-24 15:12     ` Rik van Riel

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=20071217185213.d0d02149.akpm@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=Valdis.Kletnieks@vt.edu \
    --cc=dhowells@redhat.com \
    --cc=hidave.darkstar@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=viro@zeniv.linux.org.uk \
    /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