mdadm/mdadm-3.2.2-fixbuild.patch
Milan Broz b979607a1c Fix build on PPC.
Resolves: bz719379
2011-07-06 15:27:18 -04:00

27 lines
928 B
Diff

--- a/super-intel.c
+++ b/super-intel.c
@@ -2326,7 +2326,9 @@ static void getinfo_super_imsm_volume(st
dprintf("IMSM: General Migration checkpoint : %llu "
"(%llu) -> read reshape progress : %llu\n",
- units, blocks_per_unit, info->reshape_progress);
+ (unsigned long long)units,
+ (unsigned long long)blocks_per_unit,
+ info->reshape_progress);
used_disks = imsm_num_data_members(dev, 1);
if (used_disks > 0) {
@@ -8661,7 +8663,11 @@ static int imsm_reshape_super(struct sup
dprintf("imsm: info: Volume operation\n");
/* find requested device */
while (dev) {
- imsm_find_array_minor_by_subdev(dev->index, st->container_dev, &devnum);
+ if (imsm_find_array_minor_by_subdev(dev->index,
+ st->container_dev, &devnum) < 0) {
+ dprintf("imsm: cannot find array\n");
+ goto exit_imsm_reshape_super;
+ }
if (devnum == geo.dev_id)
break;
dev = dev->next;