Lines Matching refs:checksum
150 // number of bytes to checksum in a block_list_header
247 // this isn't a great checksum routine but it will do for now.
248 // we use it to checksum the journal header and the block list
256 // this is a lame checksum but for now it'll do
479 jnl->jhdr->checksum = 0;
480 jnl->jhdr->checksum = calc_checksum((char *)jnl->jhdr, JOURNAL_HEADER_CKSUM_SIZE);
734 jnl->jhdr->checksum = SWAP32(jnl->jhdr->checksum);
747 blhdr->checksum = SWAP32(blhdr->checksum);
1094 int i, orig_checksum, checksum, check_block_checksums=0, bad_blocks=0;
1155 orig_checksum = blhdr->checksum;
1156 blhdr->checksum = 0;
1158 // calculate the checksum based on the unswapped data
1161 checksum = calc_checksum((char *)blhdr, BLHDR_CHECKSUM_SIZE);
1164 checksum = calc_checksum((char *)blhdr, BLHDR_CHECKSUM_SIZE);
1174 if (checksum != orig_checksum) {
1186 printf("jnl: %s: replay_journal: bad block list header @ 0x%llx (checksum 0x%x != 0x%x)\n",
1187 jnl->jdev_name, blhdr_offset, orig_checksum, checksum);
1287 // read the block so we can check the checksum
1297 // there is no need to swap the checksum from disk because
1827 int orig_checksum, checksum;
1896 orig_checksum = jnl->jhdr->checksum;
1897 jnl->jhdr->checksum = 0;
1902 checksum = calc_checksum((char *)jnl->jhdr, JOURNAL_HEADER_CKSUM_SIZE);
1906 checksum = calc_checksum((char *)jnl->jhdr, JOURNAL_HEADER_CKSUM_SIZE);
1918 if (orig_checksum != checksum) {
1919 printf("jnl: %s: open: journal checksum is bad (0x%x != 0x%x)\n",
1920 jdev_name, orig_checksum, checksum);
2076 int orig_checksum, checksum;
2133 orig_checksum = jnl.jhdr->checksum;
2134 jnl.jhdr->checksum = 0;
2139 checksum = calc_checksum((char *)jnl.jhdr, JOURNAL_HEADER_CKSUM_SIZE);
2143 checksum = calc_checksum((char *)jnl.jhdr, JOURNAL_HEADER_CKSUM_SIZE);
2153 if (orig_checksum != checksum) {
2154 printf("jnl: %s: is_clean: journal checksum is bad (0x%x != 0x%x)\n", jdev_name, orig_checksum, checksum);
2298 printf(" chksum: 0x%.8x\n", jnl->jhdr->checksum);
2464 // journal replay code checksum check depends on this.
2810 // journal replay code checksum check depends on this.
3889 blhdr->checksum = 0;
3890 blhdr->checksum = calc_checksum((char *)blhdr, BLHDR_CHECKSUM_SIZE);