From: John Kennedy <jk@csuchico.edu>
To: linux-kernel@vger.kernel.org
Subject: Re: attempt to access beyond end of device
Date: Thu, 7 Dec 2000 09:10:45 -0800 [thread overview]
Message-ID: <20001207091045.A29789@north.csuchico.edu> (raw)
In-Reply-To: <20001207165659.A1167@gondor.com> <20001207173428.A23936@veritas.com>
In-Reply-To: <20001207173428.A23936@veritas.com>; from aeb@veritas.com on Thu, Dec 07, 2000 at 05:34:28PM +0100
On Thu, Dec 07, 2000 at 05:34:28PM +0100, Andries Brouwer wrote:
> On Thu, Dec 07, 2000 at 04:56:59PM +0100, Jan Niehusmann wrote:
> > That means that if blk_size[major][MINOR(bh->b_rdev)] == 0, the request
> > is canceled but no message is printed. Shouldn't there be a warning message?
>
> Maybe that code fragment is mine. If so, then at some point
> in time I decided that the answer to your question is no.
As a potential real-world case (but possibly unrelated), I had an
interesting situation crop-up while I was playing with the loopback
filesystems.
If you just use the program-tools, you end up with a situation like:
losetup <blah> [close all] dd <blah> [close all] losetup -d [blah]
In my case, I was making a standalone program that did it all in one
program and I messed up in the ordering of the close() and the LOOP_CLR_FD.
I'm pretty sure that (with my small 10K test dataset) the I/O between
the loopback device and the looped file was never hitting the disk.
If I LOOP_CLR_FD before I closed, I ended up with bad data in the looped
file and kernel errors syslogged:
kernel: attempt to access beyond end of device
kernel: 07:00: rw=1, want=1, limit=0
kernel: dev 07:00 blksize=0 blocknr=0 sector=0 size=1024 count=1
I tended to get 10 of those, one for each of the 10 1K blocks in
my test dataset.
Doing the close() then the LOOP_CLR_FD got rid of the errors.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
next prev parent reply other threads:[~2000-12-07 17:41 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2000-12-07 15:56 Jan Niehusmann
2000-12-07 16:34 ` Andries Brouwer
2000-12-07 17:10 ` John Kennedy [this message]
-- strict thread matches above, loose matches on Subject: below --
2002-12-06 5:21 Justin Pryzby
2002-12-05 18:54 Justin Pryzby
2000-11-24 9:02 Janek
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=20001207091045.A29789@north.csuchico.edu \
--to=jk@csuchico.edu \
--cc=linux-kernel@vger.kernel.org \
/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®