part: Rename test_part_xx() and print_part_xx()
Rename these functions so that part_ is at the start. This more clearly identifies these functions as partition functions. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
61ccd886e2
commit
084bf4c244
|
@ -207,27 +207,27 @@ struct bootcode_block *get_bootcode(struct blk_desc *dev_desc)
|
||||||
* Test if the given partition has an Amiga partition table/Rigid
|
* Test if the given partition has an Amiga partition table/Rigid
|
||||||
* Disk block
|
* Disk block
|
||||||
*/
|
*/
|
||||||
static int test_part_amiga(struct blk_desc *dev_desc)
|
static int part_test_amiga(struct blk_desc *dev_desc)
|
||||||
{
|
{
|
||||||
struct rigid_disk_block *rdb;
|
struct rigid_disk_block *rdb;
|
||||||
struct bootcode_block *bootcode;
|
struct bootcode_block *bootcode;
|
||||||
|
|
||||||
PRINTF("test_part_amiga: Testing for an Amiga RDB partition\n");
|
PRINTF("part_test_amiga: Testing for an Amiga RDB partition\n");
|
||||||
|
|
||||||
rdb = get_rdisk(dev_desc);
|
rdb = get_rdisk(dev_desc);
|
||||||
if (rdb)
|
if (rdb)
|
||||||
{
|
{
|
||||||
bootcode = get_bootcode(dev_desc);
|
bootcode = get_bootcode(dev_desc);
|
||||||
if (bootcode)
|
if (bootcode)
|
||||||
PRINTF("test_part_amiga: bootable Amiga disk\n");
|
PRINTF("part_test_amiga: bootable Amiga disk\n");
|
||||||
else
|
else
|
||||||
PRINTF("test_part_amiga: non-bootable Amiga disk\n");
|
PRINTF("part_test_amiga: non-bootable Amiga disk\n");
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
PRINTF("test_part_amiga: no RDB found\n");
|
PRINTF("part_test_amiga: no RDB found\n");
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -318,7 +318,7 @@ static int part_get_info_amiga(struct blk_desc *dev_desc, int part,
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void print_part_amiga(struct blk_desc *dev_desc)
|
static void part_print_amiga(struct blk_desc *dev_desc)
|
||||||
{
|
{
|
||||||
struct rigid_disk_block *rdb;
|
struct rigid_disk_block *rdb;
|
||||||
struct bootcode_block *boot;
|
struct bootcode_block *boot;
|
||||||
|
@ -329,14 +329,14 @@ static void print_part_amiga(struct blk_desc *dev_desc)
|
||||||
rdb = get_rdisk(dev_desc);
|
rdb = get_rdisk(dev_desc);
|
||||||
if (!rdb)
|
if (!rdb)
|
||||||
{
|
{
|
||||||
PRINTF("print_part_amiga: no rdb found\n");
|
PRINTF("part_print_amiga: no rdb found\n");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
PRINTF("print_part_amiga: Scanning partition list\n");
|
PRINTF("part_print_amiga: Scanning partition list\n");
|
||||||
|
|
||||||
block = rdb->partition_list;
|
block = rdb->partition_list;
|
||||||
PRINTF("print_part_amiga: partition list at 0x%x\n", block);
|
PRINTF("part_print_amiga: partition list at 0x%x\n", block);
|
||||||
|
|
||||||
printf("Summary: DiskBlockSize: %d\n"
|
printf("Summary: DiskBlockSize: %d\n"
|
||||||
" Cylinders : %d\n"
|
" Cylinders : %d\n"
|
||||||
|
@ -382,8 +382,8 @@ U_BOOT_PART_TYPE(amiga) = {
|
||||||
.name = "AMIGA",
|
.name = "AMIGA",
|
||||||
.part_type = PART_TYPE_AMIGA,
|
.part_type = PART_TYPE_AMIGA,
|
||||||
.get_info = part_get_info_amiga,
|
.get_info = part_get_info_amiga,
|
||||||
.print = print_part_amiga,
|
.print = part_print_amiga,
|
||||||
.test = test_part_amiga,
|
.test = part_test_amiga,
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -87,7 +87,7 @@ static int test_block_type(unsigned char *buffer)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static int test_part_dos(struct blk_desc *dev_desc)
|
static int part_test_dos(struct blk_desc *dev_desc)
|
||||||
{
|
{
|
||||||
ALLOC_CACHE_ALIGN_BUFFER(unsigned char, buffer, dev_desc->blksz);
|
ALLOC_CACHE_ALIGN_BUFFER(unsigned char, buffer, dev_desc->blksz);
|
||||||
|
|
||||||
|
@ -285,7 +285,7 @@ static int part_get_info_extended(struct blk_desc *dev_desc,
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
void print_part_dos(struct blk_desc *dev_desc)
|
void part_print_dos(struct blk_desc *dev_desc)
|
||||||
{
|
{
|
||||||
printf("Part\tStart Sector\tNum Sectors\tUUID\t\tType\n");
|
printf("Part\tStart Sector\tNum Sectors\tUUID\t\tType\n");
|
||||||
print_partition_extended(dev_desc, 0, 0, 1, 0);
|
print_partition_extended(dev_desc, 0, 0, 1, 0);
|
||||||
|
@ -301,8 +301,8 @@ U_BOOT_PART_TYPE(dos) = {
|
||||||
.name = "DOS",
|
.name = "DOS",
|
||||||
.part_type = PART_TYPE_DOS,
|
.part_type = PART_TYPE_DOS,
|
||||||
.get_info = part_get_info_ptr(part_get_info_dos),
|
.get_info = part_get_info_ptr(part_get_info_dos),
|
||||||
.print = part_print_ptr(print_part_dos),
|
.print = part_print_ptr(part_print_dos),
|
||||||
.test = test_part_dos,
|
.test = part_test_dos,
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -176,7 +176,7 @@ static void prepare_backup_gpt_header(gpt_header *gpt_h)
|
||||||
* Public Functions (include/part.h)
|
* Public Functions (include/part.h)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
void print_part_efi(struct blk_desc *dev_desc)
|
void part_print_efi(struct blk_desc *dev_desc)
|
||||||
{
|
{
|
||||||
ALLOC_CACHE_ALIGN_BUFFER_PAD(gpt_header, gpt_head, 1, dev_desc->blksz);
|
ALLOC_CACHE_ALIGN_BUFFER_PAD(gpt_header, gpt_head, 1, dev_desc->blksz);
|
||||||
gpt_entry *gpt_pte = NULL;
|
gpt_entry *gpt_pte = NULL;
|
||||||
|
@ -319,7 +319,7 @@ int part_get_info_efi_by_name(struct blk_desc *dev_desc,
|
||||||
return -2;
|
return -2;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int test_part_efi(struct blk_desc *dev_desc)
|
static int part_test_efi(struct blk_desc *dev_desc)
|
||||||
{
|
{
|
||||||
ALLOC_CACHE_ALIGN_BUFFER_PAD(legacy_mbr, legacymbr, 1, dev_desc->blksz);
|
ALLOC_CACHE_ALIGN_BUFFER_PAD(legacy_mbr, legacymbr, 1, dev_desc->blksz);
|
||||||
|
|
||||||
|
@ -959,7 +959,7 @@ U_BOOT_PART_TYPE(a_efi) = {
|
||||||
.name = "EFI",
|
.name = "EFI",
|
||||||
.part_type = PART_TYPE_EFI,
|
.part_type = PART_TYPE_EFI,
|
||||||
.get_info = part_get_info_ptr(part_get_info_efi),
|
.get_info = part_get_info_ptr(part_get_info_efi),
|
||||||
.print = part_print_ptr(print_part_efi),
|
.print = part_print_ptr(part_print_efi),
|
||||||
.test = test_part_efi,
|
.test = part_test_efi,
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -223,7 +223,7 @@ static int part_get_info_iso(struct blk_desc *dev_desc, int part_num,
|
||||||
return part_get_info_iso_verb(dev_desc, part_num, info, 1);
|
return part_get_info_iso_verb(dev_desc, part_num, info, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void print_part_iso(struct blk_desc *dev_desc)
|
static void part_print_iso(struct blk_desc *dev_desc)
|
||||||
{
|
{
|
||||||
disk_partition_t info;
|
disk_partition_t info;
|
||||||
int i;
|
int i;
|
||||||
|
@ -242,7 +242,7 @@ static void print_part_iso(struct blk_desc *dev_desc)
|
||||||
} while (part_get_info_iso_verb(dev_desc, i, &info, 0) != -1);
|
} while (part_get_info_iso_verb(dev_desc, i, &info, 0) != -1);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int test_part_iso(struct blk_desc *dev_desc)
|
static int part_test_iso(struct blk_desc *dev_desc)
|
||||||
{
|
{
|
||||||
disk_partition_t info;
|
disk_partition_t info;
|
||||||
|
|
||||||
|
@ -253,7 +253,7 @@ U_BOOT_PART_TYPE(iso) = {
|
||||||
.name = "ISO",
|
.name = "ISO",
|
||||||
.part_type = PART_TYPE_ISO,
|
.part_type = PART_TYPE_ISO,
|
||||||
.get_info = part_get_info_iso,
|
.get_info = part_get_info_iso,
|
||||||
.print = print_part_iso,
|
.print = part_print_iso,
|
||||||
.test = test_part_iso,
|
.test = part_test_iso,
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -40,7 +40,7 @@ static int part_mac_read_pdb(struct blk_desc *dev_desc, int part,
|
||||||
/*
|
/*
|
||||||
* Test for a valid MAC partition
|
* Test for a valid MAC partition
|
||||||
*/
|
*/
|
||||||
static int test_part_mac(struct blk_desc *dev_desc)
|
static int part_test_mac(struct blk_desc *dev_desc)
|
||||||
{
|
{
|
||||||
ALLOC_CACHE_ALIGN_BUFFER(mac_driver_desc_t, ddesc, 1);
|
ALLOC_CACHE_ALIGN_BUFFER(mac_driver_desc_t, ddesc, 1);
|
||||||
ALLOC_CACHE_ALIGN_BUFFER(mac_partition_t, mpart, 1);
|
ALLOC_CACHE_ALIGN_BUFFER(mac_partition_t, mpart, 1);
|
||||||
|
@ -63,7 +63,7 @@ static int test_part_mac(struct blk_desc *dev_desc)
|
||||||
return (0);
|
return (0);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void print_part_mac(struct blk_desc *dev_desc)
|
static void part_print_mac(struct blk_desc *dev_desc)
|
||||||
{
|
{
|
||||||
ulong i, n;
|
ulong i, n;
|
||||||
ALLOC_CACHE_ALIGN_BUFFER(mac_driver_desc_t, ddesc, 1);
|
ALLOC_CACHE_ALIGN_BUFFER(mac_driver_desc_t, ddesc, 1);
|
||||||
|
@ -240,7 +240,7 @@ U_BOOT_PART_TYPE(mac) = {
|
||||||
.name = "MAC",
|
.name = "MAC",
|
||||||
.part_type = PART_TYPE_MAC,
|
.part_type = PART_TYPE_MAC,
|
||||||
.get_info = part_get_info_mac,
|
.get_info = part_get_info_mac,
|
||||||
.print = print_part_mac,
|
.print = part_print_mac,
|
||||||
.test = test_part_mac,
|
.test = part_test_mac,
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue