On Sun, Nov 17, 2002 at 07:43:27PM -0500, Alexander Viro wrote:
> Not really. Correct fix is:
> a) in fs/block_dev.c::full_check_disk_change() replace
>
> if (check_disk_change(bdev)) {
> with
> if (check_disk_change(bdev) && bdev->bd_invalidated) {
>
> b) lost the check in rescan_partitions().
>
> Other callers either do that check themselves or don't want that check to
> happen at all (BLKRRPART).
Well, since you didn't attach the patch, here it is.
--
Doug Ledford <dledford@redhat.com> 919-754-3700 x44233
Red Hat, Inc.
1801 Varsity Dr.
Raleigh, NC 27606
--CE+1k2dSO48ffgeK
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="part.patch"
===== fs/block_dev.c 1.112 vs edited =====
--- 1.112/fs/block_dev.c Sun Nov 17 08:09:16 2002
+++ edited/fs/block_dev.c Sun Nov 17 22:00:23 2002
@@ -520,7 +520,7 @@
if (bdev->bd_contains != bdev)
BUG();
down(&bdev->bd_sem);
- if (check_disk_change(bdev)) {
+ if (check_disk_change(bdev) && bdev->bd_invalidated) {
rescan_partitions(bdev->bd_disk, bdev);
res = 1;
}
===== fs/partitions/check.c 1.85 vs edited =====
--- 1.85/fs/partitions/check.c Mon Nov 11 22:16:11 2002
+++ edited/fs/partitions/check.c Sun Nov 17 21:59:28 2002
@@ -453,8 +453,6 @@
struct parsed_partitions *state;
int p, res;
- if (!bdev->bd_invalidated)
- return 0;
if (bdev->bd_part_count)
return -EBUSY;
res = invalidate_device(dev, 1);
--CE+1k2dSO48ffgeK--
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/