lkml.org 
[lkml]   [1999]   [Jun]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
SubjectRemovable media bug FOUND !!
Date
From

Finally I've located the buf that caused me so mush truobleas with my
magneto-optical drive. The bug is in genhd.c::amiga_partition(), that's
why all works fine to 99% of people... Here is the patch:

-----------cut-------------
--- linux/drivers/block/genhd.c Mon Jun 28 16:34:31 1999
+++ linux/drivers/block/genhd.c Mon Jun 28 17:39:09 1999
@@ -923,13 +923,14 @@
blk = htonl(pb->pb_Next);
if (pb->pb_ID == htonl(IDNAME_PARTITION) &&
checksum_block(
(u32 *)pb,htonl(pb->pb_SummedLongs) & 0x7F) == 0 )
{
-
+
/* Tell Kernel about it */

if (!(nr_sects = (htonl(pb->pb_Environment[10]) + 1
-
htonl(pb->pb_Environment[9])) *
htonl(pb->pb_Environment[3]) *
htonl(pb->pb_Environment[5]))) {
+ brelse(bh);
continue;
}
start_sect = htonl(pb->pb_Environment[9]) *
@@ -942,8 +943,9 @@
brelse(bh);
}
printk("\n");
- break;
}
+ else
+ brelse(bh);
}

rdb_done:
-----------cut-------------
Bye.

P.S. Please don't send me too many medals :)))

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:52    [W:0.035 / U:0.104 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site