parted/parted-use-ext-range.patch

23 lines
907 B
Diff

Index: parted-2.4/libparted/arch/linux.c
===================================================================
--- parted-2.4.orig/libparted/arch/linux.c
+++ parted-2.4/libparted/arch/linux.c
@@ -2413,7 +2413,7 @@ _blkpg_remove_partition (PedDisk* disk,
/*
* The number of partitions that a device can have depends on the kernel.
- * If we don't find this value in /sys/block/DEV/range, we will use our own
+ * If we don't find this value in /sys/block/DEV/ext_range, we will use our own
* value.
*/
static unsigned int
@@ -2424,7 +2424,7 @@ _device_get_partition_range(PedDevice* d
FILE* fp;
bool ok;
- r = snprintf(path, sizeof(path), "/sys/block/%s/range",
+ r = snprintf(path, sizeof(path), "/sys/block/%s/ext_range",
last_component(dev->path));
if (r < 0 || r >= sizeof(path))
return MAX_NUM_PARTS;