lb->parttypes = xbsd_fstypes;
lb->nparttypes = ARRAY_SIZE(xbsd_fstypes);
- /* don't ask for partition number for op->part_add() */
- lb->flags = FDISK_LABEL_FL_ADDPART_NOPARTNO;
+ lb->flags |= FDISK_LABEL_FL_ADDPART_NOPARTNO;
+ lb->flags |= FDISK_LABEL_FL_REQUIRE_GEOMETRY;
return lb;
}
lb->parttypes = dos_parttypes;
lb->nparttypes = ARRAY_SIZE(dos_parttypes);
- /* don't ask for partition number for op->part_add() */
- lb->flags = FDISK_LABEL_FL_ADDPART_NOPARTNO;
+ lb->flags |= FDISK_LABEL_FL_ADDPART_NOPARTNO;
+ lb->flags |= FDISK_LABEL_FL_REQUIRE_GEOMETRY;
return lb;
}
/* label driver flags */
enum {
- FDISK_LABEL_FL_ADDPART_NOPARTNO = (1 << 1)
+ FDISK_LABEL_FL_ADDPART_NOPARTNO = (1 << 1),
+ FDISK_LABEL_FL_REQUIRE_GEOMETRY = (1 << 2)
};
/* label allocators */
* @cxt: fdisk context
* @t: partition type to create or NULL for label-specific default
*
- * Creates a new partition, with number @partnum and type @parttype.
+ * Creates a new partition with type @parttype.
*
* Returns 0.
*/
lb->parttypes = sgi_parttypes;
lb->nparttypes = ARRAY_SIZE(sgi_parttypes);
+ lb->flags |= FDISK_LABEL_FL_REQUIRE_GEOMETRY;
+
return lb;
}
lb->parttypes = sun_parttypes;
lb->nparttypes = ARRAY_SIZE(sun_parttypes);
+ lb->flags |= FDISK_LABEL_FL_REQUIRE_GEOMETRY;
+
return lb;
}