• Home
  • Raw
  • Download

Lines Matching refs:numparts

158 static int calc_parts_list_len(int numparts)  in calc_parts_list_len()  argument
165 partlistlen += numparts * (strlen("name=,") + PART_NAME_LEN + 1); in calc_parts_list_len()
167 partlistlen += numparts * (strlen("start=MiB,") + sizeof(lbaint_t) + 1); in calc_parts_list_len()
168 partlistlen += numparts * (strlen("size=MiB,") + sizeof(lbaint_t) + 1); in calc_parts_list_len()
169 partlistlen += numparts * (strlen("uuid=;") + UUID_STR_LEN + 1); in calc_parts_list_len()
173 numparts); in calc_parts_list_len()
265 static int create_gpt_partitions_list(int numparts, const char *guid, in create_gpt_partitions_list() argument
659 int partlistlen, ret, numparts = 0, partnum, i = 1, ctr1 = 0, ctr2 = 0; in do_rename_gpt_parts() local
672 numparts = get_gpt_info(dev_desc); in do_rename_gpt_parts()
673 if (numparts <= 0) in do_rename_gpt_parts()
674 return numparts ? numparts : -ENODEV; in do_rename_gpt_parts()
676 partlistlen = calc_parts_list_len(numparts); in do_rename_gpt_parts()
684 ret = create_gpt_partitions_list(numparts, disk_guid, partitions_list); in do_rename_gpt_parts()
736 if ((partnum < 0) || (partnum > numparts)) { in do_rename_gpt_parts()
756 ret = create_gpt_partitions_list(numparts, disk_guid, partitions_list); in do_rename_gpt_parts()
778 ret = gpt_restore(dev_desc, disk_guid, new_partitions, numparts); in do_rename_gpt_parts()
790 numparts = get_gpt_info(dev_desc); in do_rename_gpt_parts()
791 if (numparts <= 0) { in do_rename_gpt_parts()
792 ret = numparts ? numparts : -ENODEV; in do_rename_gpt_parts()
795 printf("new partition table with %d partitions is:\n", numparts); in do_rename_gpt_parts()