2000-12-06 17:50:32

by Peng Dai

[permalink] [raw]
Subject: Fixing random corruption in raw IO on 2.2.x kernel with bigmem enabled

--- linux/fs/iobuf.c.orig Tue Nov 28 13:54:26 2000
+++ linux/fs/iobuf.c Tue Nov 28 13:55:17 2000
@@ -213,10 +213,10 @@
unsigned long kin, kout;
int pagelen = length;

- if (bounce_page) {
- if ((pagelen+offset) > PAGE_SIZE)
- pagelen = PAGE_SIZE - offset;
-
+ if ((pagelen+offset) > PAGE_SIZE)
+ pagelen = PAGE_SIZE - offset;
+
+ if (bounce_page) {
if (direction == COPY_TO_BOUNCE) {
kin = kmap(page, KM_READ);
kout = kmap(bounce_page, KM_WRITE);


Attachments:
iobuf.c.patch (485.00 B)

2000-12-06 18:59:59

by Stephen C. Tweedie

[permalink] [raw]
Subject: Re: Fixing random corruption in raw IO on 2.2.x kernel with bigmem enabled

Hi,

On Wed, Dec 06, 2000 at 12:28:54PM -0500, Peng Dai wrote:
>
> This patch fixes a subtle corruption when doing raw IO on the 2.2.x
> kernel
> with bigmem enabled. The problem was first reported by Markus D?hr while

That patch is already part of the full bugfixed raw IO patchset I
posted out a few days ago. Look for kiobuf-2.2.18pre24-B.tar.gz in

ftp.uk.linux.org:/pub/linux/sct/fs/raw-io
or ftp.*.kernel.org:/pub/linux/kernel/people/sct/raw-io

Cheers,
Stephen