Lines Matching refs:bfc

276 	struct backing_file_context *bfc = NULL;  in incfs_open_data_file()  local
288 bfc = incfs_alloc_bfc(mi, bf); in incfs_open_data_file()
289 if (IS_ERR(bfc)) in incfs_open_data_file()
290 return ERR_CAST(bfc); in incfs_open_data_file()
300 df->df_backing_file_context = bfc; in incfs_open_data_file()
305 error = incfs_read_file_header(bfc, &df->df_metadata_off, &df->df_id, in incfs_open_data_file()
328 incfs_free_bfc(bfc); in incfs_open_data_file()
349 struct backing_file_context *bfc = df->df_backing_file_context; in incfs_free_data_file() local
352 if (bfc && !mutex_lock_interruptible(&bfc->bc_mutex)) { in incfs_free_data_file()
358 mutex_unlock(&bfc->bc_mutex); in incfs_free_data_file()
668 static int validate_hash_tree(struct backing_file_context *bfc, struct file *f, in validate_hash_tree() argument
730 res = incfs_kread(bfc, buf, INCFS_DATA_FILE_BLOCK_SIZE, in validate_hash_tree()
819 struct backing_file_context *bfc = NULL; in get_data_file_block() local
827 bfc = df->df_backing_file_context; in get_data_file_block()
832 error = incfs_read_blockmap_entry(bfc, index, blockmap_off, &bme); in get_data_file_block()
1291 struct backing_file_context *bfc = NULL; in incfs_read_data_file_block() local
1302 bfc = df->df_backing_file_context; in incfs_read_data_file_block()
1311 result = incfs_kread(bfc, dst.data, bytes_to_read, pos); in incfs_read_data_file_block()
1318 result = incfs_kread(bfc, tmp.data, bytes_to_read, pos); in incfs_read_data_file_block()
1325 bfc->bc_file->f_path.dentry->d_name.name; in incfs_read_data_file_block()
1337 int err = validate_hash_tree(bfc, f, index, dst, tmp.data); in incfs_read_data_file_block()
1362 struct backing_file_context *bfc = NULL; in incfs_read_merkle_tree_blocks() local
1370 bfc = df->df_backing_file_context; in incfs_read_merkle_tree_blocks()
1378 return incfs_kread(bfc, dst.data, to_read, sig->hash_offset + offset); in incfs_read_merkle_tree_blocks()
1385 struct backing_file_context *bfc = NULL; in incfs_process_new_data_block() local
1394 bfc = df->df_backing_file_context; in incfs_process_new_data_block()
1430 error = mutex_lock_interruptible(&bfc->bc_mutex); in incfs_process_new_data_block()
1433 bfc, range(data, block->data_len), block->block_index, in incfs_process_new_data_block()
1435 mutex_unlock(&bfc->bc_mutex); in incfs_process_new_data_block()
1451 struct backing_file_context *bfc = df->df_backing_file_context; in incfs_read_file_signature() local
1465 read_res = incfs_kread(bfc, dst.data, sig->sig_size, sig->sig_offset); in incfs_read_file_signature()
1479 struct backing_file_context *bfc = NULL; in incfs_process_new_hash_block() local
1493 bfc = df->df_backing_file_context; in incfs_process_new_hash_block()
1512 error = mutex_lock_interruptible(&bfc->bc_mutex); in incfs_process_new_hash_block()
1515 bfc, range(data, block->data_len), block->block_index, in incfs_process_new_hash_block()
1517 mutex_unlock(&bfc->bc_mutex); in incfs_process_new_hash_block()
1669 struct backing_file_context *bfc = NULL; in incfs_scan_metadata_chain() local
1675 bfc = df->df_backing_file_context; in incfs_scan_metadata_chain()
1689 error = incfs_read_next_metadata_record(bfc, handler); in incfs_scan_metadata_chain()