Home | History | Annotate | Download | only in ext2fs

Lines Matching refs:hdr

150 	struct undo_header hdr;
231 memcpy(data->hdr.magic, E2UNDO_MAGIC, sizeof(data->hdr.magic));
232 data->hdr.num_keys = ext2fs_cpu_to_le64(data->num_keys);
233 data->hdr.super_offset = ext2fs_cpu_to_le64(data->super_blk_num);
234 data->hdr.key_offset = ext2fs_cpu_to_le64(data->first_key_blk);
235 data->hdr.fs_block_size = ext2fs_cpu_to_le32(block_size);
236 data->hdr.sb_crc = ext2fs_cpu_to_le32(sb_crc);
237 data->hdr.fs_offset = ext2fs_cpu_to_le64(data->offset);
239 e2undo_set_feature_fs_offset(&data->hdr);
241 e2undo_clear_feature_fs_offset(&data->hdr);
242 hdr_crc = ext2fs_crc32c_le(~0, (unsigned char *)&data->hdr,
243 sizeof(data->hdr) -
244 sizeof(data->hdr.header_crc));
245 data->hdr.header_crc = ext2fs_cpu_to_le32(hdr_crc);
247 -(int)sizeof(data->hdr),
248 &data->hdr);
299 data->hdr.block_size = ext2fs_cpu_to_le32(data->tdb_data_size);
497 static int check_filesystem(struct undo_header *hdr, io_channel undo_file,
529 if (ext2fs_le32_to_cpu(hdr->sb_crc) != sb_crc) {
548 struct undo_header hdr;
565 retval = io_channel_read_blk64(data->undo_file, 0, -(int)sizeof(hdr),
566 &hdr);
570 if (memcmp(hdr.magic, E2UNDO_MAGIC,
571 sizeof(hdr.magic)))
573 hdr_crc = ext2fs_crc32c_le(~0, (unsigned char *)&hdr,
576 if (ext2fs_le32_to_cpu(hdr.header_crc) != hdr_crc)
578 blocksize = ext2fs_le32_to_cpu(hdr.block_size);
579 fs_blocksize = ext2fs_le32_to_cpu(hdr.fs_block_size);
584 super_block = ext2fs_le64_to_cpu(hdr.super_offset);
585 num_keys = ext2fs_le64_to_cpu(hdr.num_keys);
588 * Do not compare hdr.f_compat with the available compatible
592 if (hdr.f_incompat || hdr.f_rocompat)
596 if (check_filesystem(&hdr, data->undo_file, blocksize, super_block,
609 data->first_key_blk = ext2fs_le64_to_cpu(hdr.key_offset);
664 data->hdr.state = hdr.state & ~E2UNDO_STATE_FINISHED;
665 data->hdr.f_compat = hdr.f_compat;
666 data->hdr.f_incompat = hdr.f_incompat;
667 data->hdr.f_rocompat = hdr.f_rocompat;
809 data->hdr.state = ext2fs_cpu_to_le32(E2UNDO_STATE_FINISHED);