Lines Matching refs:sh
437 struct logfs_segment_header *sh)
442 err = wbuf_read(sb, ofs, sizeof(*sh), sh);
445 crc = logfs_crc32(sh, sizeof(*sh), 4);
446 if (crc != sh->crc) {
448 "got %x\n", ofs, be32_to_cpu(sh->crc),
828 struct logfs_segment_header sh; in ostore_erase_segment() local
836 sh.pad = 0; in ostore_erase_segment()
837 sh.type = SEG_OSTORE; in ostore_erase_segment()
838 sh.level = (__force u8)area->a_level; in ostore_erase_segment()
839 sh.segno = cpu_to_be32(area->a_segno); in ostore_erase_segment()
840 sh.ec = cpu_to_be32(area->a_erase_count); in ostore_erase_segment()
841 sh.gec = cpu_to_be64(logfs_super(sb)->s_gec); in ostore_erase_segment()
842 sh.crc = logfs_crc32(&sh, sizeof(sh), 4); in ostore_erase_segment()
848 area->a_used_bytes = sizeof(sh); in ostore_erase_segment()
849 logfs_buf_write(area, ofs, &sh, sizeof(sh)); in ostore_erase_segment()