Lines Matching full:length
53 struct squashfs_cache *cache, u64 block, int length)
110 entry->length = squashfs_read_data(sb, block, length,
115 if (entry->length < 0)
116 entry->error = entry->length;
293 * Copy up to length bytes from cache entry to buffer starting at offset bytes
294 * into the cache entry. If there's not length bytes then copy the number of
298 int offset, int length)
300 int remaining = length;
302 if (length == 0)
305 return min(length, entry->length - offset);
307 while (offset < entry->length) {
310 int bytes = min_t(int, entry->length - offset,
325 return length - remaining;
330 * Read length bytes from metadata position <block, offset> (block is the
333 * and length bytes may require reading more than one block.
336 u64 *block, int *offset, int length)
339 int bytes, res = length;
344 if (unlikely(length < 0))
347 while (length) {
352 } else if (*offset >= entry->length) {
357 bytes = squashfs_copy_data(buffer, entry, *offset, length);
360 length -= bytes;
363 if (*offset == entry->length) {
384 u64 start_block, int length)
389 length);
399 u64 start_block, int length)
403 return squashfs_cache_get(sb, msblk->read_page, start_block, length);
410 void *squashfs_read_table(struct super_block *sb, u64 block, int length)
412 int pages = (length + PAGE_SIZE - 1) >> PAGE_SHIFT;
417 table = buffer = kmalloc(length, GFP_KERNEL);
427 actor = squashfs_page_actor_init(data, pages, length);
436 res = squashfs_read_data(sb, block, length |