Lines Matching refs:gpt_header_offset
402 int64_t gpt_header_offset; in gpt_get_state() local
421 gpt_header_offset = blk_size; in gpt_get_state()
423 gpt_header_offset = lseek64(fd, 0, SEEK_END) - blk_size; in gpt_get_state()
424 if (gpt_header_offset < 0) { in gpt_get_state()
430 if (blk_rw(fd, 0, gpt_header_offset, gpt_header, blk_size)) { in gpt_get_state()
468 int64_t gpt_header_offset; in gpt_set_state() local
485 gpt_header_offset = blk_size; in gpt_set_state()
487 gpt_header_offset = lseek64(fd, 0, SEEK_END) - blk_size; in gpt_set_state()
488 if (gpt_header_offset < 0) { in gpt_set_state()
493 if (blk_rw(fd, 0, gpt_header_offset, gpt_header, blk_size)) { in gpt_set_state()
513 if (blk_rw(fd, 1, gpt_header_offset, gpt_header, blk_size)) { in gpt_set_state()
1153 off_t gpt_header_offset = 0; in gpt_set_header() local
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()
1169 if (gpt_header_offset <= 0) { in gpt_set_header()
1174 gpt_header_offset); in gpt_set_header()
1175 if (blk_rw(fd, 1, gpt_header_offset, gpt_header, block_size)) { in gpt_set_header()