Lines Matching full:unlikely

111 	if (unlikely(!IS_ALIGNED(btrfs_file_extent_##name((leaf), (fi)),      \
216 if (unlikely(!IS_ALIGNED(key->offset, sectorsize))) { in check_extent_data_item()
229 if (unlikely(!check_prev_ino(leaf, key, slot, prev_key))) in check_extent_data_item()
238 if (unlikely(item_size < BTRFS_FILE_EXTENT_INLINE_DATA_START)) { in check_extent_data_item()
245 if (unlikely(btrfs_file_extent_type(leaf, fi) >= in check_extent_data_item()
258 if (unlikely(btrfs_file_extent_compression(leaf, fi) >= in check_extent_data_item()
266 if (unlikely(btrfs_file_extent_encryption(leaf, fi))) { in check_extent_data_item()
274 if (unlikely(key->offset)) { in check_extent_data_item()
287 if (unlikely(item_size != BTRFS_FILE_EXTENT_INLINE_DATA_START + in check_extent_data_item()
299 if (unlikely(item_size != sizeof(*fi))) { in check_extent_data_item()
305 if (unlikely(CHECK_FE_ALIGNED(leaf, slot, fi, ram_bytes, sectorsize) || in check_extent_data_item()
313 if (unlikely(check_add_overflow(btrfs_file_extent_num_bytes(leaf, fi), in check_extent_data_item()
335 if (unlikely(prev_end > key->offset)) { in check_extent_data_item()
371 if (unlikely(key->objectid != BTRFS_EXTENT_CSUM_OBJECTID)) { in check_csum_item()
377 if (unlikely(!IS_ALIGNED(key->offset, sectorsize))) { in check_csum_item()
383 if (unlikely(!IS_ALIGNED(btrfs_item_size(leaf, slot), csumsize))) { in check_csum_item()
396 if (unlikely(prev_csum_end > key->offset)) { in check_csum_item()
421 if (unlikely(key->objectid != 0 || key->type != 0 || in check_inode_key()
427 if (unlikely((key->objectid < BTRFS_FIRST_FREE_OBJECTID || in check_inode_key()
448 if (unlikely(key->offset != 0)) { in check_inode_key()
477 if (unlikely(is_root_item && key->objectid == BTRFS_TREE_RELOC_OBJECTID && in check_root_key()
486 if (unlikely(key->objectid == 0)) { in check_root_key()
496 if (unlikely(!is_fstree(key->objectid) && !is_root_item)) { in check_root_key()
512 if (unlikely(key->objectid == BTRFS_TREE_RELOC_OBJECTID && in check_root_key()
529 if (unlikely(!check_prev_ino(leaf, key, slot, prev_key))) in check_dir_item()
544 if (unlikely(cur + sizeof(*di) > item_size)) { in check_dir_item()
555 if (unlikely(ret < 0)) in check_dir_item()
560 if (unlikely(ret < 0)) in check_dir_item()
572 if (unlikely(dir_type <= BTRFS_FT_UNKNOWN || in check_dir_item()
580 if (unlikely(key->type == BTRFS_XATTR_ITEM_KEY && in check_dir_item()
587 if (unlikely(dir_type == BTRFS_FT_XATTR && in check_dir_item()
601 if (unlikely(name_len > max_name_len)) { in check_dir_item()
607 if (unlikely(name_len + data_len > BTRFS_MAX_XATTR_SIZE(fs_info))) { in check_dir_item()
615 if (unlikely(data_len && dir_type != BTRFS_FT_XATTR)) { in check_dir_item()
625 if (unlikely(cur + total_size > item_size)) { in check_dir_item()
643 if (unlikely(key->offset != name_hash)) { in check_dir_item()
695 if (unlikely(key->offset == 0)) { in check_block_group_item()
701 if (unlikely(item_size != sizeof(bgi))) { in check_block_group_item()
718 if (unlikely(fs_info->nr_global_roots && in check_block_group_item()
726 } else if (unlikely(chunk_objectid != BTRFS_FIRST_CHUNK_TREE_OBJECTID)) { in check_block_group_item()
734 if (unlikely(btrfs_stack_block_group_used(&bgi) > key->offset)) { in check_block_group_item()
742 if (unlikely(hweight64(flags & BTRFS_BLOCK_GROUP_PROFILE_MASK) > 1)) { in check_block_group_item()
751 if (unlikely(type != BTRFS_BLOCK_GROUP_DATA && in check_block_group_item()
843 if (unlikely(!num_stripes)) { in btrfs_check_chunk_valid()
848 if (unlikely(num_stripes < ncopies)) { in btrfs_check_chunk_valid()
854 if (unlikely(nparity && num_stripes == nparity)) { in btrfs_check_chunk_valid()
860 if (unlikely(!IS_ALIGNED(logical, fs_info->sectorsize))) { in btrfs_check_chunk_valid()
866 if (unlikely(btrfs_chunk_sector_size(leaf, chunk) != fs_info->sectorsize)) { in btrfs_check_chunk_valid()
873 if (unlikely(!length || !IS_ALIGNED(length, fs_info->sectorsize))) { in btrfs_check_chunk_valid()
878 if (unlikely(check_add_overflow(logical, length, &chunk_end))) { in btrfs_check_chunk_valid()
884 if (unlikely(!is_power_of_2(stripe_len) || stripe_len != BTRFS_STRIPE_LEN)) { in btrfs_check_chunk_valid()
898 if (unlikely(length >= btrfs_stripe_nr_to_offset(U32_MAX))) { in btrfs_check_chunk_valid()
904 if (unlikely(type & ~(BTRFS_BLOCK_GROUP_TYPE_MASK | in btrfs_check_chunk_valid()
914 if (unlikely(!has_single_bit_set(type & BTRFS_BLOCK_GROUP_PROFILE_MASK) && in btrfs_check_chunk_valid()
921 if (unlikely((type & BTRFS_BLOCK_GROUP_TYPE_MASK) == 0)) { in btrfs_check_chunk_valid()
928 if (unlikely((type & BTRFS_BLOCK_GROUP_SYSTEM) && in btrfs_check_chunk_valid()
942 if (unlikely((type & BTRFS_BLOCK_GROUP_METADATA) && in btrfs_check_chunk_valid()
950 if (unlikely((type & BTRFS_BLOCK_GROUP_RAID10 && in btrfs_check_chunk_valid()
988 if (unlikely(btrfs_item_size(leaf, slot) < sizeof(struct btrfs_chunk))) { in check_leaf_chunk_item()
1002 if (unlikely(btrfs_chunk_item_size(num_stripes) != in check_leaf_chunk_item()
1044 if (unlikely(key->objectid != BTRFS_DEV_ITEMS_OBJECTID)) { in check_dev_item()
1051 if (unlikely(item_size != sizeof(*ditem))) { in check_dev_item()
1058 if (unlikely(btrfs_device_id(leaf, ditem) != key->offset)) { in check_dev_item()
1070 if (unlikely(btrfs_device_bytes_used(leaf, ditem) > in check_dev_item()
1099 if (unlikely(ret < 0)) in check_inode_item()
1102 if (unlikely(item_size != sizeof(*iitem))) { in check_inode_item()
1111 if (unlikely(btrfs_inode_generation(leaf, iitem) > super_gen + 1)) { in check_inode_item()
1119 if (unlikely(btrfs_inode_transid(leaf, iitem) > super_gen + 1)) { in check_inode_item()
1132 if (unlikely(mode & ~valid_mask)) { in check_inode_item()
1145 if (unlikely(!S_ISLNK(mode) && !S_ISBLK(mode) && !S_ISSOCK(mode))) { in check_inode_item()
1152 if (unlikely(S_ISDIR(mode) && btrfs_inode_nlink(leaf, iitem) > 1)) { in check_inode_item()
1159 if (unlikely(flags & ~BTRFS_INODE_FLAG_MASK)) { in check_inode_item()
1164 if (unlikely(!sb_rdonly(fs_info->sb) && in check_inode_item()
1184 if (unlikely(ret < 0)) in check_root_item()
1187 if (unlikely(btrfs_item_size(leaf, slot) != sizeof(ri) && in check_root_item()
1206 if (unlikely(btrfs_root_generation(&ri) > in check_root_item()
1214 if (unlikely(btrfs_root_generation_v2(&ri) > in check_root_item()
1222 if (unlikely(btrfs_root_last_snapshot(&ri) > in check_root_item()
1232 if (unlikely(!IS_ALIGNED(btrfs_root_bytenr(&ri), fs_info->sectorsize))) { in check_root_item()
1238 if (unlikely(btrfs_root_level(&ri) >= BTRFS_MAX_LEVEL)) { in check_root_item()
1244 if (unlikely(btrfs_root_drop_level(&ri) >= BTRFS_MAX_LEVEL)) { in check_root_item()
1252 if (unlikely(btrfs_root_flags(&ri) & ~valid_root_flags)) { in check_root_item()
1323 if (unlikely(key->type == BTRFS_METADATA_ITEM_KEY && in check_extent_item()
1330 if (unlikely(!IS_ALIGNED(key->objectid, fs_info->sectorsize))) { in check_extent_item()
1338 if (unlikely(key->type == BTRFS_METADATA_ITEM_KEY && in check_extent_item()
1377 if (unlikely(item_size < sizeof(*ei))) { in check_extent_item()
1391 if (unlikely(generation > in check_extent_item()
1399 if (unlikely(!has_single_bit_set(flags & (BTRFS_EXTENT_FLAG_DATA | in check_extent_item()
1409 if (unlikely(key->type == BTRFS_EXTENT_ITEM_KEY && in check_extent_item()
1417 if (unlikely(key->type != BTRFS_EXTENT_ITEM_KEY)) { in check_extent_item()
1423 if (unlikely(!IS_ALIGNED(key->offset, fs_info->sectorsize))) { in check_extent_item()
1429 if (unlikely(flags & BTRFS_BLOCK_FLAG_FULL_BACKREF)) { in check_extent_item()
1442 if (unlikely(btrfs_tree_block_level(leaf, info) >= BTRFS_MAX_LEVEL)) { in check_extent_item()
1464 if (unlikely(ptr + sizeof(*iref) > end)) { in check_extent_item()
1474 if (unlikely(ptr + btrfs_extent_inline_ref_size(inline_type) > end)) { in check_extent_item()
1488 if (unlikely(!IS_ALIGNED(inline_offset, in check_extent_item()
1510 if (unlikely(!is_valid_dref_root(dref_root))) { in check_extent_item()
1516 if (unlikely(dref_objectid < BTRFS_FIRST_FREE_OBJECTID || in check_extent_item()
1523 if (unlikely(!IS_ALIGNED(dref_offset, in check_extent_item()
1535 if (unlikely(!IS_ALIGNED(inline_offset, in check_extent_item()
1573 if (unlikely(ptr != end)) { in check_extent_item()
1580 if (unlikely(inline_refs > total_refs)) { in check_extent_item()
1596 if (unlikely(prev_end > key->objectid)) { in check_extent_item()
1617 if (unlikely(btrfs_item_size(leaf, slot) != expect_item_size)) { in check_simple_keyed_refs()
1624 if (unlikely(!IS_ALIGNED(key->objectid, leaf->fs_info->sectorsize))) { in check_simple_keyed_refs()
1630 if (unlikely(key->type != BTRFS_TREE_BLOCK_REF_KEY && in check_simple_keyed_refs()
1647 if (unlikely(btrfs_item_size(leaf, slot) % sizeof(*dref) != 0)) { in check_extent_data_ref()
1654 if (unlikely(!IS_ALIGNED(key->objectid, leaf->fs_info->sectorsize))) { in check_extent_data_ref()
1673 if (unlikely(!is_valid_dref_root(root))) { in check_extent_data_ref()
1679 if (unlikely(objectid < BTRFS_FIRST_FREE_OBJECTID || in check_extent_data_ref()
1686 if (unlikely(!IS_ALIGNED(offset, leaf->fs_info->sectorsize))) { in check_extent_data_ref()
1706 if (unlikely(!check_prev_ino(leaf, key, slot, prev_key))) in check_inode_ref()
1709 if (unlikely(btrfs_item_size(leaf, slot) <= sizeof(*iref))) { in check_inode_ref()
1722 if (unlikely(ptr + sizeof(iref) > end)) { in check_inode_ref()
1731 if (unlikely(ptr + sizeof(*iref) + namelen > end)) { in check_inode_ref()
1751 if (unlikely(!IS_ALIGNED(key->objectid, leaf->fs_info->sectorsize))) { in check_raid_stripe_extent()
1758 if (unlikely(!btrfs_fs_incompat(leaf->fs_info, RAID_STRIPE_TREE))) { in check_raid_stripe_extent()
1777 if (unlikely(btrfs_dev_extent_chunk_tree(leaf, de) != in check_dev_extent_item()
1785 if (unlikely(btrfs_dev_extent_chunk_objectid(leaf, de) != in check_dev_extent_item()
1794 if (unlikely(!IS_ALIGNED(key->offset, sectorsize))) { in check_dev_extent_item()
1800 if (unlikely(!IS_ALIGNED(btrfs_dev_extent_chunk_offset(leaf, de), in check_dev_extent_item()
1808 if (unlikely(!IS_ALIGNED(btrfs_dev_extent_length(leaf, de), in check_dev_extent_item()
1823 if (unlikely(prev_key->offset + prev_len > key->offset)) { in check_dev_extent_item()
1909 if (unlikely(btrfs_header_level(leaf) != 0)) { in __btrfs_check_leaf()
1916 if (unlikely(!btrfs_header_flag(leaf, BTRFS_HEADER_FLAG_WRITTEN))) { in __btrfs_check_leaf()
1933 if (unlikely(owner == BTRFS_ROOT_TREE_OBJECTID || in __btrfs_check_leaf()
1945 if (unlikely(owner == 0)) { in __btrfs_check_leaf()
1955 if (unlikely(owner == BTRFS_EXTENT_TREE_OBJECTID)) { in __btrfs_check_leaf()
1965 if (unlikely(nritems == 0)) in __btrfs_check_leaf()
1987 if (unlikely(btrfs_comp_cpu_keys(&prev_key, &key) >= 0)) { in __btrfs_check_leaf()
2008 if (unlikely(item_data_end != item_end_expected)) { in __btrfs_check_leaf()
2020 if (unlikely(item_data_end > BTRFS_LEAF_DATA_SIZE(fs_info))) { in __btrfs_check_leaf()
2028 if (unlikely(btrfs_item_ptr_offset(leaf, slot) < in __btrfs_check_leaf()
2040 if (unlikely(ret != BTRFS_TREE_BLOCK_CLEAN)) in __btrfs_check_leaf()
2056 if (unlikely(ret != BTRFS_TREE_BLOCK_CLEAN)) in btrfs_check_leaf()
2071 if (unlikely(!btrfs_header_flag(node, BTRFS_HEADER_FLAG_WRITTEN))) { in __btrfs_check_node()
2076 if (unlikely(level <= 0 || level >= BTRFS_MAX_LEVEL)) { in __btrfs_check_node()
2082 if (unlikely(nr == 0 || nr > BTRFS_NODEPTRS_PER_BLOCK(fs_info))) { in __btrfs_check_node()
2096 if (unlikely(!bytenr)) { in __btrfs_check_node()
2101 if (unlikely(!IS_ALIGNED(bytenr, fs_info->sectorsize))) { in __btrfs_check_node()
2108 if (unlikely(btrfs_comp_cpu_keys(&key, &next_key) >= 0)) { in __btrfs_check_node()
2125 if (unlikely(ret != BTRFS_TREE_BLOCK_CLEAN)) in btrfs_check_node()
2160 if (unlikely(root_owner != eb_owner)) { in btrfs_check_eb_owner()
2175 if (unlikely(is_subvol != is_fstree(eb_owner))) { in btrfs_check_eb_owner()