Lines Matching refs:block

54 	befs_blocknr_t block;	/* block coresponding to pos */
57 block = pos >> BEFS_SB(sb)->block_shift;
59 *off = pos - (block << BEFS_SB(sb)->block_shift);
61 if (befs_fblock2brun(sb, ds, block, &run) != BEFS_OK) {
62 befs_error(sb, "BeFS: Error finding disk addr of block %lu",
63 (unsigned long)block);
69 befs_error(sb, "BeFS: Error reading block %lu from datastream",
70 (unsigned long)block);
80 * befs_fblock2brun - give back block run for fblock
86 * Takes a file position and gives back a brun who's starting block
87 * is block number fblock of the file.
112 "befs_fblock2brun() was asked to find block %lu, "
142 befs_error(sb, "BeFS: Error reading datastream block "
185 metablocks = 1; /* Start with 1 block for inode */
187 /* Size of indirect block */
192 * Double indir block, plus all the indirect blocks it maps.
193 * In the double-indirect range, all block runs of data are
195 * how many data block runs are in the double-indirect region,
222 * befs_find_brun_direct - find a direct block run in the datastream
228 * Finds the block run that starts at file block number blockno
237 * contains the blockno-th filesystem block. This is necessary
238 * because the block runs map variable amounts of data. Simply
240 * incrementing this by the length of each block run as we come
245 * When/if blockno is found, if blockno is inside of a block
247 * of the block run, so that blockno is the start and len is
276 befs_error(sb, "%s failed to find file block %lu", __func__,
283 * befs_find_brun_indirect - find a block run in the datastream
289 * Finds the block run that starts at file block number blockno
297 * For each block in the indirect run of the datastream, read
331 "disk block %lu from the indirect brun",
353 "<--- %s found file block "
367 "file block %lu", __func__, (unsigned long)blockno);
374 * befs_find_brun_dblindirect - find a block run in the datastream
380 * Finds the block run that starts at file block number blockno
388 * The block runs in the double-indirect region are different.
390 * block run maps a constant amount of file data. This means
391 * that we can directly calculate how many block runs into the
393 * maps a particular filesystem block.
396 * inode addresses in the double-indirect block will point us
397 * to the indirect block that contains the mapping for the data,
399 * indirect block maps the data block we are after.
406 * the indirect block and perform a similar process to find
407 * the actual block run that maps the data block we are interested
439 * the indirect block pointed to by the double indirect block
444 * the double indirect block
454 * the indirect block contains pos.
461 /* Read double indirect block */
466 "of the double-indirect block", __func__,
476 "double-indirect block at blockno %lu", __func__,
489 /* Read indirect block */
494 "of the indirect block", __func__, indir_indx);
501 befs_error(sb, "%s couldn't read the indirect block "
520 befs_debug(sb, "Found file block %lu in double_indirect[%d][%d],"