From: Jens Axboe <axboe@suse.de>
To: Christophe Saout <christophe@saout.de>
Cc: LKML <linux-kernel@vger.kernel.org>, Andrew Morton <akpm@osdl.org>
Subject: Re: [PATCH] fix small highmem bio bounce bvec handling glitch
Date: Thu, 26 Feb 2004 16:33:07 +0100 [thread overview]
Message-ID: <20040226153307.GS7580@suse.de> (raw)
In-Reply-To: <1077809433.10397.11.camel@leto.cs.pocnet.net>
On Thu, Feb 26 2004, Christophe Saout wrote:
> Am Do, den 26.02.2004 schrieb Jens Axboe um 16:10:
>
> > > --- linux.orig/mm/highmem.c 2004-01-21 19:08:45.000000000 +0100
> > > +++ linux/mm/highmem.c 2004-02-26 15:47:14.574722576 +0100
> > > @@ -294,7 +294,12 @@
> > > if (tovec->bv_page == fromvec->bv_page)
> > > continue;
> > >
> > > - vfrom = page_address(fromvec->bv_page) + fromvec->bv_offset;
> > > + /*
> > > + * fromvec->bv_offset and fromvec->bv_len might have been
> > > + * modified by the block layer, so use the original copy,
> > > + * bounce_copy_vec already uses tovec->bv_len
> > > + */
> > > + vfrom = page_address(fromvec->bv_page) + tovec->bv_offset;
> > >
> > > bounce_copy_vec(tovec, vfrom);
> >
> > Irk yes, that's is pretty nasty, I really wish we could avoid screwing
> > with vec entries
>
> What about a bio->bi_bvec_done field?
That'd work. Suparna originally suggested bio->bi_voffset (iirc) as a
current offset. It just doesn't feel completely right...
> > (it's pretty obscure for bio clones, too)...
>
> Yes, I noticed that dm-crypt also does the same mistake for reads. I'm
> going to change it too (easily accomplished).
Great.
--
Jens Axboe
prev parent reply other threads:[~2004-02-26 15:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-02-26 15:06 [PATCH] fix small highmem bio bounce bvec handling glitch Christophe Saout
2004-02-26 15:10 ` Jens Axboe
2004-02-26 15:30 ` Christophe Saout
2004-02-26 15:33 ` Jens Axboe [this message]
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=20040226153307.GS7580@suse.de \
--to=axboe@suse.de \
--cc=akpm@osdl.org \
--cc=christophe@saout.de \
--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