Lines Matching refs:block_size
1130 uint32_t block_size = 0; in gpt_get_block_size() local
1136 if (ioctl(fd, BLKSSZGET, &block_size) != 0) { in gpt_get_block_size()
1142 return block_size; in gpt_get_block_size()
1152 uint32_t block_size = 0; in gpt_set_header() local
1159 block_size = gpt_get_block_size(fd); in gpt_set_header()
1160 ALOGI("%s: Block size is : %d", __func__, block_size); in gpt_set_header()
1161 if (block_size == 0) { in gpt_set_header()
1166 gpt_header_offset = block_size; in gpt_set_header()
1168 gpt_header_offset = lseek64(fd, 0, SEEK_END) - block_size; in gpt_set_header()
1175 if (blk_rw(fd, 1, gpt_header_offset, gpt_header, block_size)) { in gpt_set_header()
1190 uint32_t block_size = 0; in gpt_get_header() local
1211 block_size = gpt_get_block_size(fd); in gpt_get_header()
1212 if (block_size == 0) in gpt_get_header()
1220 hdr = (uint8_t*)malloc(block_size); in gpt_get_header()
1226 hdr_offset = block_size; in gpt_get_header()
1228 hdr_offset = lseek64(fd, 0, SEEK_END) - block_size; in gpt_get_header()
1235 if (blk_rw(fd, 0, hdr_offset, hdr, block_size)) { in gpt_get_header()
1258 uint32_t block_size = 0; in gpt_get_pentry_arr() local
1270 block_size = gpt_get_block_size(fd); in gpt_get_pentry_arr()
1271 if (!block_size) { in gpt_get_pentry_arr()
1276 pentries_start = GET_8_BYTES(hdr + PENTRIES_OFFSET) * block_size; in gpt_get_pentry_arr()
1304 uint32_t block_size = 0; in gpt_set_pentry_arr() local
1313 block_size = gpt_get_block_size(fd); in gpt_set_pentry_arr()
1314 if (!block_size) { in gpt_set_pentry_arr()
1319 ALOGI("%s : Block size is %d", __func__, block_size); in gpt_set_pentry_arr()
1320 pentries_start = GET_8_BYTES(hdr + PENTRIES_OFFSET) * block_size; in gpt_set_pentry_arr()
1439 disk->block_size = gpt_get_block_size(fd); in gpt_disk_get_disk_info()