Lines Matching full:csum

278  * Return 0 for the range [disk_bytenr, disk_bytenr + sectorsize) has no csum
299 /* Check if the current csum item covers disk_bytenr */ in search_csum_tree()
340 * Lookup the checksum for the read bio in csum tree.
366 * - All our csums should only be in csum tree in btrfs_lookup_bio_sums()
380 bbio->csum = kmalloc_array(nblocks, csum_size, GFP_NOFS); in btrfs_lookup_bio_sums()
381 if (!bbio->csum) { in btrfs_lookup_bio_sums()
386 bbio->csum = bbio->csum_inline; in btrfs_lookup_bio_sums()
391 * kick the readahead for csum tree. in btrfs_lookup_bio_sums()
400 * between reading the free space cache and updating the csum tree. in btrfs_lookup_bio_sums()
410 u8 *csum_dst = bbio->csum + in btrfs_lookup_bio_sums()
417 if (bbio->csum != bbio->csum_inline) in btrfs_lookup_bio_sums()
418 kfree(bbio->csum); in btrfs_lookup_bio_sums()
419 bbio->csum = NULL; in btrfs_lookup_bio_sums()
424 * We didn't find a csum for this range. We need to make sure in btrfs_lookup_bio_sums()
430 * copying is in fact NODATASUM. If we don't find a csum we in btrfs_lookup_bio_sums()
446 "csum hole found for disk bytenr range [%llu, %llu)", in btrfs_lookup_bio_sums()
496 * There are two cases we can hit here for the previous csum in btrfs_lookup_csums_list()
500 * |<- csum item ->| in btrfs_lookup_csums_list()
504 * |<- csum item ->| in btrfs_lookup_csums_list()
506 * Check if the previous csum item covers the leading part of in btrfs_lookup_csums_list()
507 * the search range. If so we have to start from previous csum in btrfs_lookup_csums_list()
596 * that there is a csum found.
645 * There are two cases we can hit here for the previous csum in btrfs_lookup_csums_bitmap()
649 * |<- csum item ->| in btrfs_lookup_csums_bitmap()
653 * |<- csum item ->| in btrfs_lookup_csums_bitmap()
655 * Check if the previous csum item covers the leading part of in btrfs_lookup_csums_bitmap()
656 * the search range. If so we have to start from previous csum in btrfs_lookup_csums_bitmap()
805 * This expects the key to describe the csum pointed to by the path, and it
806 * expects the csum to overlap the range [bytenr, len]
808 * The csum should not be entirely contained in the range and the range should
809 * not be entirely contained in the csum.
835 * [csum ] in truncate_one_csum()
846 * [csum ] in truncate_one_csum()
847 * we need to truncate from the beginning of the csum in truncate_one_csum()
862 * Delete the csum items from the csum tree for a given range of bytes.
914 /* this csum ends before we start, we're done */ in btrfs_del_csums()
923 * Check how many csum items preceding this one in this in btrfs_del_csums()
957 * [csum ] in btrfs_del_csums()
959 * Our bytes are in the middle of the csum, in btrfs_del_csums()
963 * csum could change, get removed, extended etc. in btrfs_del_csums()
965 * The trick here is the max size of a csum item leaves in btrfs_del_csums()
970 * a nicely formed csum item that we can neatly in btrfs_del_csums()
1096 /* We didn't find a csum item, insert one. */ in btrfs_csum_file_blocks()
1208 goto csum; in btrfs_csum_file_blocks()
1235 csum: in btrfs_csum_file_blocks()