The patch titled fix rescan_partitions to return errors properly has been added to the -mm tree. Its filename is fix-rescan_partitions-to-return-errors-properly.patch See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find out what to do about this ------------------------------------------------------ Subject: fix rescan_partitions to return errors properly From: Suzuki Kp <suzuki@xxxxxxxxxx> Signed-off-by: Suzuki K P <suzuki@xxxxxxxxxx> Cc: Erik Mouw <erik@xxxxxxxxxxxxxxxxxxxxx> Cc: Christoph Hellwig <hch@xxxxxx> Cc: Al Viro <viro@xxxxxxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxx> --- fs/partitions/check.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletion(-) diff -puN fs/partitions/check.c~fix-rescan_partitions-to-return-errors-properly fs/partitions/check.c --- a/fs/partitions/check.c~fix-rescan_partitions-to-return-errors-properly +++ a/fs/partitions/check.c @@ -177,7 +177,7 @@ check_partition(struct gendisk *hd, stru else if (warn_no_part) printk(" unable to read partition table\n"); kfree(state); - return NULL; + return ERR_PTR(res); } /* @@ -460,6 +460,8 @@ int rescan_partitions(struct gendisk *di 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 PTR_ERR(state); for (p = 1; p < state->limit; p++) { sector_t size = state->parts[p].size; sector_t from = state->parts[p].from; _ Patches currently in -mm which might be from suzuki@xxxxxxxxxx are fix-rescan_partitions-to-return-errors-properly.patch - To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html