Home
last modified time | relevance | path

Searched refs:sect_size (Results 1 – 4 of 4) sorted by relevance

/system/core/libdiskconfig/
Dconfig_mbr.c56 kb_to_lba(uint32_t len_kb, uint32_t sect_size) in kb_to_lba() argument
62 lba = (lba + (uint64_t)sect_size - 1) & ~((uint64_t)sect_size - 1); in kb_to_lba()
63 lba /= (uint64_t)sect_size; in kb_to_lba()
104 len_lba += ((uint64_t)dinfo->sect_size - 1); in mk_pri_pentry()
105 len_lba &= ~((uint64_t)dinfo->sect_size - 1); in mk_pri_pentry()
106 len_lba /= (uint64_t)dinfo->sect_size; in mk_pri_pentry()
155 item->offset = ((loff_t)(*lba)) * dinfo->sect_size; in mk_ext_pentry()
163 len = kb_to_lba(pinfo->len_kb, dinfo->sect_size); in mk_ext_pentry()
174 (uint32_t)(((uint64_t)len * (uint64_t)dinfo->sect_size) / in mk_ext_pentry()
196 next_len_lba = 1 + kb_to_lba(pnext->len_kb, dinfo->sect_size); in mk_ext_pentry()
[all …]
Ddiskconfig.c196 dinfo->sect_size = strtol(tmp, NULL, 0); in load_diskconfig()
197 if (!dinfo->sect_size) { in load_diskconfig()
307 if (!sect_sz || sect_sz != dinfo->sect_size) { in validate()
319 dinfo->num_lba = (uint32_t)(disk_size / (uint64_t)dinfo->sect_size); in validate()
321 disk_size = (uint64_t)dinfo->num_lba * (uint64_t)dinfo->sect_size; in validate()
324 if (!dinfo->sect_size) { in validate()
329 disk_size = (uint64_t)dinfo->num_lba * (uint64_t)dinfo->sect_size; in validate()
331 dinfo->num_lba = (uint32_t)(stat.st_size / dinfo->sect_size); in validate()
341 dinfo->device, disk_size, dinfo->num_lba, dinfo->sect_size); in validate()
346 total_size = dinfo->skip_lba * dinfo->sect_size; in validate()
[all …]
/system/core/include/diskconfig/
Ddiskconfig.h92 int sect_size; /* expected sector size in bytes. MUST BE POWER OF 2 */ member
/system/vold/
DDisk.cpp409 dinfo.sect_size = 512; in partitionPublic()