* Fix rescan_partition to propagate the low level I/O error. Signed Off by: Suzuki K P Index: linux-2.6.18/fs/partitions/check.c =================================================================== --- linux-2.6.18.orig/fs/partitions/check.c 2006-09-26 04:41:55.000000000 +0530 +++ linux-2.6.18/fs/partitions/check.c 2006-10-06 01:22:06.000000000 +0530 @@ -177,7 +177,7 @@ else if (warn_no_part) printk(" unable to read partition table\n"); kfree(state); - return NULL; + return ERR_PTR(res); } /* @@ -460,6 +460,9 @@ disk->fops->revalidate_disk(disk); if (!get_capacity(disk) || !(state = check_partition(disk, bdev))) return 0; + if (IS_ERR(state)) + /* I/O error reading the partition table */ + return -EIO; for (p = 1; p < state->limit; p++) { sector_t size = state->parts[p].size; sector_t from = state->parts[p].from;