소스 검색

partitions: increase MAX_SEARCH_PARTITIONS and move to part.h

Move MAX_SEARCH_PARTITIONS to part.h so that functions in cmd
directory can find it.  At the same time, increase the value to
64 since some operating systems use many, and the resources
consumed by a larger value are minimal.

Changes since v6: none.

Signed-off-by: Alison Chaiken <alison@peloton-tech.com>
Alison Chaiken 8 년 전
부모
커밋
e6faf21f25
2개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 0 1
      disk/part.c
  2. 1 0
      include/part.h

+ 0 - 1
disk/part.c

@@ -388,7 +388,6 @@ cleanup:
 
 #define PART_UNSPECIFIED -2
 #define PART_AUTO -1
-#define MAX_SEARCH_PARTITIONS 16
 int blk_get_device_part_str(const char *ifname, const char *dev_part_str,
 			     struct blk_desc **dev_desc,
 			     disk_partition_t *info, int allow_whole_dev)

+ 1 - 0
include/part.h

@@ -49,6 +49,7 @@ struct block_drvr {
 
 #define PART_NAME_LEN 32
 #define PART_TYPE_LEN 32
+#define MAX_SEARCH_PARTITIONS 64
 
 typedef struct disk_partition {
 	lbaint_t	start;	/* # of first block in partition	*/