Lines Matching defs:idx

2425 		INDEX_ALLOCATION **idx)
2561 *idx = ia_val;
2573 * Create space of @size bytes at position @pos inside the index block @idx.
2577 static int make_room_for_index_entry_in_index_block(INDEX_BLOCK *idx,
2594 if (!idx || !pos)
2596 if ((char*)pos < (char*)idx || (char*)pos + size < (char*)idx ||
2597 (char*)pos > (char*)idx + sizeof(INDEX_BLOCK) -
2599 le32_to_cpu(idx->index.allocated_size) ||
2600 (char*)pos + size > (char*)idx + sizeof(INDEX_BLOCK) -
2602 le32_to_cpu(idx->index.allocated_size))
2605 if ((char*)pos - (char*)&idx->index >
2606 (int)le32_to_cpu(idx->index.index_length)
2610 biu = le32_to_cpu(idx->index.index_length);
2612 if (biu + size > le32_to_cpu(idx->index.allocated_size))
2616 (char*)&idx->index));
2618 idx->index.index_length = cpu_to_le32(biu + size);
2703 static int insert_index_entry_in_res_dir_index(INDEX_ENTRY *idx, u32 idx_size,
2748 i = ntfs_file_values_compare(&idx->key.file_name,
2753 i = ntfs_names_full_collate(idx->key.file_name.file_name, idx->key.file_name.file_name_length,
2766 if (idx->key.file_name.file_name_type !=
2772 i = ntfs_file_values_compare(&idx->key.file_name,
2777 i = ntfs_names_full_collate(idx->key.file_name.file_name, idx->key.file_name.file_name_length,
2792 i = ntfs_index_keys_compare((u8*)idx + 0x10,
2794 le16_to_cpu(idx->key_length),
2809 memcpy((u8*)idx_entry, (u8*)idx, idx_size);
3015 * @idx (which belongs to @file_ref's parent directory).
3019 static int insert_file_link_in_dir_index(INDEX_BLOCK *idx, leMFT_REF file_ref,
3027 * Lookup dir entry @file_name in dir @idx to determine correct
3033 index_end = (char*)&idx->index + le32_to_cpu(idx->index.index_length);
3034 ie = (INDEX_ENTRY*)((char*)&idx->index +
3035 le32_to_cpu(idx->index.entries_offset));
3127 err = make_room_for_index_entry_in_index_block(idx, ie, i);
3150 * root @idx of the index_root attribute of the parent directory.
3232 /* Insert the index entry for file_name in @idx. */
3266 * block @idx of the index allocation attribute of the parent directory.
3272 static int create_hardlink(INDEX_BLOCK *idx, const leMFT_REF ref_parent,
3347 /* Insert the index entry for file_name in @idx. */
3348 i = insert_file_link_in_dir_index(idx, ref_file, fn, fn_size);
4229 static BOOL mkntfs_sync_index_record(INDEX_ALLOCATION* idx, MFT_RECORD* m,
4267 le32_to_cpu(idx->index.allocated_size);
4268 err = ntfs_mst_pre_write_fixup((NTFS_RECORD*)idx, i);
4275 lw = ntfs_rlwrite(g_vol->dev, rl_index, (u8*)idx, i, NULL,
4282 /* No more changes to @idx below here so no need for fixup: */
4283 /* ntfs_mst_post_write_fixup((NTFS_RECORD*)idx); */