/external/syslinux/com32/gpllib/disk/ |
D | geom.c | 25 void lba_to_chs(const struct driveinfo *drive_info, const int lba, in lba_to_chs() argument 32 if (drive_info->edd_params.sectors_per_track > 0 && in lba_to_chs() 33 drive_info->edd_params.heads > 0) { in lba_to_chs() 34 *cylinder = (lba % drive_info->edd_params.sectors_per_track) + 1; in lba_to_chs() 35 track = lba / drive_info->edd_params.sectors_per_track; in lba_to_chs() 36 *head = track % drive_info->edd_params.heads; in lba_to_chs() 37 *sector = track / drive_info->edd_params.heads; in lba_to_chs() 38 } else if (drive_info->cbios) { in lba_to_chs() 39 *cylinder = (lba % drive_info->legacy_sectors_per_track) + 1; in lba_to_chs() 40 track = lba / drive_info->legacy_sectors_per_track; in lba_to_chs() [all …]
|
D | read.c | 39 struct driveinfo drive_info; in read_mbr() local 40 drive_info.disk = drive; in read_mbr() 43 return read_sectors(&drive_info, buf, 0, 1); in read_mbr() 59 struct driveinfo drive_info; in dev_read() local 60 drive_info.disk = drive; in dev_read() 62 return read_sectors(&drive_info, buf, lba, sectors); in dev_read() 75 int read_sectors(struct driveinfo *drive_info, void *data, in read_sectors() argument 84 if (get_drive_parameters(drive_info) == -1) in read_sectors() 97 if (drive_info->ebios) { in read_sectors() 106 inreg.edx.b[0] = drive_info->disk; in read_sectors() [all …]
|
D | write.c | 35 int write_sectors(const struct driveinfo *drive_info, const unsigned int lba, in write_sectors() argument 54 if (drive_info->ebios) { in write_sectors() 63 inreg.edx.b[0] = drive_info->disk; in write_sectors() 68 if (!drive_info->cbios) { // XXX errno in write_sectors() 77 lba_to_chs(drive_info, lba, &s, &h, &c); in write_sectors() 87 inreg.edx.b[0] = drive_info->disk; in write_sectors() 109 int write_verify_sector(struct driveinfo *drive_info, in write_verify_sector() argument 112 return write_verify_sectors(drive_info, lba, data, SECTOR); in write_verify_sector() 122 int write_verify_sectors(struct driveinfo *drive_info, in write_verify_sectors() argument 129 if (write_sectors(drive_info, lba, data, size) == -1) in write_verify_sectors() [all …]
|
D | msdos.c | 44 static int process_extended_partition(struct driveinfo *drive_info, in process_extended_partition() argument 53 if (read_sectors(drive_info, ebr, partition_offset + ebr_offset, 1) == -1) in process_extended_partition() 88 callback(drive_info, in process_extended_partition() 92 status = process_extended_partition(drive_info, in process_extended_partition() 112 static int process_mbr(struct driveinfo *drive_info, struct part_entry *ptab, in process_mbr() argument 123 callback(drive_info, &ptab[i], ptab[i].start_lba, i + 1); in process_mbr() 125 process_extended_partition(drive_info, ptab[i].start_lba, 0, in process_mbr() 128 callback(drive_info, &ptab[i], ptab[i].start_lba, i + 1); in process_mbr()
|
D | swsusp.c | 13 int swsusp_check(struct driveinfo *drive_info, struct part_entry *ptab) in swsusp_check() argument 21 if (read_sectors(drive_info, &header_p, offset, PAGE_SIZE / SECTOR) == -1) { in swsusp_check()
|
/external/syslinux/com32/gplinclude/disk/ |
D | geom.h | 304 static inline int chs_to_lba(const struct driveinfo *drive_info, in chs_to_lba() argument 309 if (drive_info->edd_params.sectors_per_track > 0 && in chs_to_lba() 310 drive_info->edd_params.heads > 0) in chs_to_lba() 312 (head * drive_info->edd_params.sectors_per_track) + in chs_to_lba() 313 (cylinder * (drive_info->edd_params.heads) * in chs_to_lba() 314 drive_info->edd_params.sectors_per_track); in chs_to_lba() 315 else if (drive_info->cbios) in chs_to_lba() 316 return (sector - 1) + (head * drive_info->legacy_sectors_per_track) + in chs_to_lba() 317 (cylinder * (drive_info->legacy_max_head + 1) * in chs_to_lba() 318 drive_info->legacy_sectors_per_track); in chs_to_lba() [all …]
|
D | write.h | 22 int write_verify_sector(struct driveinfo *drive_info,
|
/external/syslinux/com32/hdt/ |
D | hdt-menu-disk.c | 36 static void show_partition_information(struct driveinfo *drive_info, in show_partition_information() argument 50 drive_info[dn].disk, nb_partitions_seen); in show_partition_information() 73 static void compute_partition_information(struct driveinfo *drive_info, in compute_partition_information() argument 92 drive_info[dn].disk, nb_partitions_seen); in compute_partition_information() 116 if (get_bootloader_string(drive_info, ptab, bootloader_name, 9) == 0) { in compute_partition_information() 144 if (ptab->ostype == 0x82 && swsusp_check(drive_info, ptab) != -1) { in compute_partition_information()
|
D | hdt-cli-disk.c | 53 static void show_partition_information(struct driveinfo *drive_info, in show_partition_information() argument 84 if (ptab->ostype == 0x82 && swsusp_check(drive_info, ptab)) in show_partition_information() 87 if (get_bootloader_string(drive_info, ptab, bootloader_name, 9) == 0) in show_partition_information()
|
D | hdt-dump-disks.c | 36 static void show_partition_information(struct driveinfo *drive_info, in show_partition_information() argument 55 get_bootloader_string(drive_info, ptab, bootloader_name, 9); in show_partition_information()
|
/external/syslinux/com32/mboot/ |
D | mb_info.h | 60 struct drive_info { struct
|