/fs/iomap/ |
D | seek.c | 74 page_cache_seek_hole_data(struct inode *inode, loff_t offset, loff_t length, in page_cache_seek_hole_data() argument 77 pgoff_t index = offset >> PAGE_SHIFT; in page_cache_seek_hole_data() 78 pgoff_t end = DIV_ROUND_UP(offset + length, PAGE_SIZE); in page_cache_seek_hole_data() 79 loff_t lastoff = offset; in page_cache_seek_hole_data() 110 if (lastoff < offset + length) in page_cache_seek_hole_data() 121 iomap_seek_hole_actor(struct inode *inode, loff_t offset, loff_t length, in iomap_seek_hole_actor() argument 126 offset = page_cache_seek_hole_data(inode, offset, length, in iomap_seek_hole_actor() 128 if (offset < 0) in iomap_seek_hole_actor() 132 *(loff_t *)data = offset; in iomap_seek_hole_actor() 140 iomap_seek_hole(struct inode *inode, loff_t offset, const struct iomap_ops *ops) in iomap_seek_hole() argument [all …]
|
/fs/btrfs/tests/ |
D | inode-tests.c | 16 u64 ram_bytes, u64 offset, u64 disk_bytenr, in insert_extent() argument 34 key.offset = start; in insert_extent() 42 btrfs_set_file_extent_offset(leaf, fi, offset); in insert_extent() 64 key.offset = 0; in insert_inode_item_key() 91 u64 offset = 0; in setup_file_extents() local 94 insert_extent(root, offset, 5, 5, 0, 0, 0, BTRFS_FILE_EXTENT_REG, 0, in setup_file_extents() 97 offset += 5; in setup_file_extents() 105 insert_extent(root, offset, 1, 1, 0, 0, 0, BTRFS_FILE_EXTENT_INLINE, 0, in setup_file_extents() 108 offset = sectorsize; in setup_file_extents() 111 insert_extent(root, offset, 4, 4, 0, 0, 0, BTRFS_FILE_EXTENT_REG, 0, in setup_file_extents() [all …]
|
/fs/udf/ |
D | directory.c | 26 sector_t *offset) in udf_fileident_read() argument 55 uint32_t lextoffset = epos->offset; in udf_fileident_read() 62 block = udf_get_lb_pblock(dir->i_sb, eloc, *offset); in udf_fileident_read() 64 (*offset)++; in udf_fileident_read() 66 if ((*offset << blocksize_bits) >= *elen) in udf_fileident_read() 67 *offset = 0; in udf_fileident_read() 69 epos->offset = lextoffset; in udf_fileident_read() 77 if (!(*offset & ((16 >> (blocksize_bits - 9)) - 1))) { in udf_fileident_read() 79 if (i + *offset > (*elen >> blocksize_bits)) in udf_fileident_read() 80 i = (*elen >> blocksize_bits)-*offset; in udf_fileident_read() [all …]
|
D | misc.c | 51 int offset; in udf_add_extendedattr() local 63 offset = inode->i_sb->s_blocksize - udf_file_entry_alloc_offset(inode) - in udf_add_extendedattr() 68 if (loc & 0x01 && offset >= size) { in udf_add_extendedattr() 101 offset = iinfo->i_lenEAttr; in udf_add_extendedattr() 107 memmove(&ea[offset - aal + size], in udf_add_extendedattr() 108 &ea[aal], offset - aal); in udf_add_extendedattr() 109 offset -= aal; in udf_add_extendedattr() 117 memmove(&ea[offset - ial + size], in udf_add_extendedattr() 118 &ea[ial], offset - ial); in udf_add_extendedattr() 119 offset -= ial; in udf_add_extendedattr() [all …]
|
D | udftime.c | 49 int16_t offset; in udf_disk_stamp_to_time() local 52 offset = typeAndTimezone << 4; in udf_disk_stamp_to_time() 54 offset = (offset >> 4); in udf_disk_stamp_to_time() 55 if (offset == -2047) /* unspecified offset */ in udf_disk_stamp_to_time() 56 offset = 0; in udf_disk_stamp_to_time() 58 offset = 0; in udf_disk_stamp_to_time() 62 dest->tv_sec -= offset * 60; in udf_disk_stamp_to_time() 76 int16_t offset; in udf_time_to_disk_stamp() local 79 offset = -sys_tz.tz_minuteswest; in udf_time_to_disk_stamp() 81 dest->typeAndTimezone = cpu_to_le16(0x1000 | (offset & 0x0FFF)); in udf_time_to_disk_stamp() [all …]
|
/fs/squashfs/ |
D | file.c | 47 static struct meta_index *locate_meta_index(struct inode *inode, int offset, in locate_meta_index() argument 56 TRACE("locate_meta_index: index %d, offset %d\n", index, offset); in locate_meta_index() 63 msblk->meta_index[i].offset >= offset && in locate_meta_index() 64 msblk->meta_index[i].offset <= index && in locate_meta_index() 67 msblk->meta_index[i].offset); in locate_meta_index() 69 offset = meta->offset; in locate_meta_index() 86 static struct meta_index *empty_meta_index(struct inode *inode, int offset, in empty_meta_index() argument 95 TRACE("empty_meta_index: offset %d, skip %d\n", offset, skip); in empty_meta_index() 136 meta->offset = offset; in empty_meta_index() 161 u64 *start_block, int *offset) in read_indexes() argument [all …]
|
D | inode.c | 105 int err, type, offset = SQUASHFS_INODE_OFFSET(ino); in squashfs_read_inode() local 116 &offset, sizeof(*sqshb_ino)); in squashfs_read_inode() 125 offset = SQUASHFS_INODE_OFFSET(ino); in squashfs_read_inode() 135 err = squashfs_read_metadata(sb, sqsh_ino, &block, &offset, in squashfs_read_inode() 142 frag_offset = le32_to_cpu(sqsh_ino->offset); in squashfs_read_inode() 164 squashfs_i(inode)->offset = offset; in squashfs_read_inode() 169 offset, squashfs_i(inode)->start, block, offset); in squashfs_read_inode() 178 err = squashfs_read_metadata(sb, sqsh_ino, &block, &offset, in squashfs_read_inode() 185 frag_offset = le32_to_cpu(sqsh_ino->offset); in squashfs_read_inode() 211 squashfs_i(inode)->offset = offset; in squashfs_read_inode() [all …]
|
D | block.c | 35 int offset, int req_length) in copy_bio_to_actor() argument 47 int bytes_to_copy = min_t(int, bvec->bv_len - offset, in copy_bio_to_actor() 53 page_address(bvec->bv_page) + bvec->bv_offset + offset, in copy_bio_to_actor() 58 offset += bytes_to_copy; in copy_bio_to_actor() 66 if (offset >= bvec->bv_len) { in copy_bio_to_actor() 69 offset = 0; in copy_bio_to_actor() 84 int offset = read_start - round_down(index, PAGE_SIZE); in squashfs_bio_read() local 86 const int page_count = DIV_ROUND_UP(total_len + offset, PAGE_SIZE); in squashfs_bio_read() 104 min_t(unsigned int, PAGE_SIZE - offset, total_len); in squashfs_bio_read() 111 if (!bio_add_page(bio, page, len, offset)) { in squashfs_bio_read() [all …]
|
D | xattr.c | 34 int offset = SQUASHFS_XATTR_OFFSET(squashfs_i(inode)->xattr); in squashfs_listxattr() local 50 err = squashfs_read_metadata(sb, &entry, &start, &offset, in squashfs_listxattr() 70 &offset, name_size); in squashfs_listxattr() 81 &offset, name_size); in squashfs_listxattr() 88 err = squashfs_read_metadata(sb, &val, &start, &offset, in squashfs_listxattr() 93 err = squashfs_read_metadata(sb, NULL, &start, &offset, in squashfs_listxattr() 112 int offset = SQUASHFS_XATTR_OFFSET(squashfs_i(inode)->xattr); in squashfs_xattr_get() local 127 err = squashfs_read_metadata(sb, &entry, &start, &offset, in squashfs_xattr_get() 138 &offset, name_size); in squashfs_xattr_get() 141 &offset, name_size); in squashfs_xattr_get() [all …]
|
/fs/btrfs/ |
D | free-space-cache.c | 49 u64 offset) in __lookup_free_space_inode() argument 62 key.offset = offset; in __lookup_free_space_inode() 137 u64 ino, u64 offset) in __create_free_space_inode() argument 170 btrfs_set_inode_block_group(leaf, inode_item, offset); in __create_free_space_inode() 175 key.offset = offset; in __create_free_space_inode() 467 unsigned offset = 0; in io_ctl_set_crc() local 475 offset = sizeof(u32) * io_ctl->num_pages; in io_ctl_set_crc() 477 crc = btrfs_crc32c(crc, io_ctl->orig + offset, PAGE_SIZE - offset); in io_ctl_set_crc() 489 unsigned offset = 0; in io_ctl_check_crc() local 497 offset = sizeof(u32) * io_ctl->num_pages; in io_ctl_check_crc() [all …]
|
D | file-item.c | 129 u64 num_bytes, u64 offset, u64 ram_bytes, in btrfs_insert_file_extent() argument 142 file_key.offset = pos; in btrfs_insert_file_extent() 156 btrfs_set_file_extent_offset(leaf, item, offset); in btrfs_insert_file_extent() 188 file_key.offset = bytenr; in btrfs_lookup_csum() 203 csum_offset = (bytenr - found_key.offset) >> in btrfs_lookup_csum() 228 u64 offset, int mod) in btrfs_lookup_file_extent() argument 236 file_key.offset = offset; in btrfs_lookup_file_extent() 256 u64 offset, u8 *dst) in btrfs_lookup_bio_sums() argument 264 const bool page_offsets = (offset == (u64)-1); in btrfs_lookup_bio_sums() 320 offset = page_offset(bvec.bv_page) + bvec.bv_offset; in btrfs_lookup_bio_sums() [all …]
|
D | uuid-tree.c | 18 key->offset = get_unaligned_le64(uuid + sizeof(u64)); in btrfs_uuid_to_key() 30 unsigned long offset; in btrfs_uuid_tree_lookup() local 56 offset = btrfs_item_ptr_offset(eb, slot); in btrfs_uuid_tree_lookup() 68 read_extent_buffer(eb, &data, offset, sizeof(data)); in btrfs_uuid_tree_lookup() 73 offset += sizeof(data); in btrfs_uuid_tree_lookup() 92 unsigned long offset; in btrfs_uuid_tree_add() local 118 offset = btrfs_item_ptr_offset(eb, slot); in btrfs_uuid_tree_add() 127 offset = btrfs_item_ptr_offset(eb, slot); in btrfs_uuid_tree_add() 128 offset += btrfs_item_size_nr(eb, slot) - sizeof(subid_le); in btrfs_uuid_tree_add() 133 (unsigned long long)key.offset, type); in btrfs_uuid_tree_add() [all …]
|
D | file.c | 392 int offset = offset_in_page(pos); in btrfs_copy_from_user() local 396 PAGE_SIZE - offset, write_bytes); in btrfs_copy_from_user() 401 copied = iov_iter_copy_from_user_atomic(page, i, offset, count); in btrfs_copy_from_user() 426 if (copied < PAGE_SIZE - offset) { in btrfs_copy_from_user() 427 offset += copied; in btrfs_copy_from_user() 430 offset = 0; in btrfs_copy_from_user() 755 if (key.type > BTRFS_EXTENT_DATA_KEY || key.offset >= end) in __btrfs_drop_extents() 767 extent_end = key.offset + in __btrfs_drop_extents() 770 extent_end = key.offset + in __btrfs_drop_extents() 786 if (extent_end == key.offset && extent_end >= search_start) { in __btrfs_drop_extents() [all …]
|
/fs/verity/ |
D | read_metadata.c | 17 void __user *buf, u64 offset, int length) in fsverity_read_merkle_tree() argument 26 end_offset = min(offset + length, vi->tree_params.tree_size); in fsverity_read_merkle_tree() 27 if (offset >= end_offset) in fsverity_read_merkle_tree() 29 offs_in_page = offset_in_page(offset); in fsverity_read_merkle_tree() 38 for (index = offset >> PAGE_SHIFT; index <= last_index; index++) { in fsverity_read_merkle_tree() 42 unsigned int bytes_to_copy = min_t(u64, end_offset - offset, in fsverity_read_merkle_tree() 68 offset += bytes_to_copy; in fsverity_read_merkle_tree() 81 static int fsverity_read_buffer(void __user *dst, u64 offset, int length, in fsverity_read_buffer() argument 84 if (offset >= src_length) in fsverity_read_buffer() 86 src += offset; in fsverity_read_buffer() [all …]
|
/fs/ecryptfs/ |
D | read_write.c | 28 loff_t offset, size_t size) in ecryptfs_write_lower() argument 36 rc = kernel_write(lower_file, data, size, &offset); in ecryptfs_write_lower() 62 loff_t offset; in ecryptfs_write_lower_page_segment() local 65 offset = ((((loff_t)page_for_lower->index) << PAGE_SHIFT) in ecryptfs_write_lower_page_segment() 68 rc = ecryptfs_write_lower(ecryptfs_inode, virt, offset, size); in ecryptfs_write_lower_page_segment() 93 int ecryptfs_write(struct inode *ecryptfs_inode, char *data, loff_t offset, in ecryptfs_write() argument 109 if (offset > ecryptfs_file_size) in ecryptfs_write() 112 pos = offset; in ecryptfs_write() 113 while (pos < (offset + size)) { in ecryptfs_write() 117 loff_t total_remaining_bytes = ((offset + size) - pos); in ecryptfs_write() [all …]
|
/fs/jffs2/ |
D | read.c | 56 je32_to_cpu(ri->offset), buf); in jffs2_read_dnode() 158 unsigned char *buf, uint32_t offset, uint32_t len) in jffs2_read_inode_range() argument 160 uint32_t end = offset + len; in jffs2_read_inode_range() 165 __func__, f->inocache->ino, offset, offset + len); in jffs2_read_inode_range() 167 frag = jffs2_lookup_node_frag(&f->fragtree, offset); in jffs2_read_inode_range() 174 while(offset < end) { in jffs2_read_inode_range() 176 __func__, offset, end); in jffs2_read_inode_range() 177 if (unlikely(!frag || frag->ofs > offset || in jffs2_read_inode_range() 178 frag->ofs + frag->size <= offset)) { in jffs2_read_inode_range() 179 uint32_t holesize = end - offset; in jffs2_read_inode_range() [all …]
|
D | erase.c | 39 bad_offset = jeb->offset; in jffs2_erase_block() 45 jeb->offset, jeb->offset, jeb->offset + c->sector_size); in jffs2_erase_block() 62 instr->addr = jeb->offset; in jffs2_erase_block() 79 jeb->offset, ret); in jffs2_erase_block() 93 jeb->offset); in jffs2_erase_block() 96 jeb->offset, ret); in jffs2_erase_block() 129 jeb->offset); in jffs2_erase_pending_blocks() 163 jffs2_dbg(1, "Erase completed successfully at 0x%08x\n", jeb->offset); in jffs2_erase_succeeded() 227 if (SECTOR_ADDR((*prev)->flash_offset) == jeb->offset) { in jffs2_remove_node_refs_from_ino_list() 252 jeb->offset, jeb->offset + c->sector_size, ic->ino); in jffs2_remove_node_refs_from_ino_list() [all …]
|
D | summary.c | 126 temp->offset = cpu_to_je32(ofs); /* relative offset from the beginning of the jeb */ in jffs2_sum_add_inode_mem() 144 temp->offset = cpu_to_je32(ofs); /* relative from the beginning of the jeb */ in jffs2_sum_add_dirent_mem() 169 temp->offset = cpu_to_je32(ofs); in jffs2_sum_add_xattr_mem() 185 temp->offset = cpu_to_je32(ofs); in jffs2_sum_add_xref_mem() 261 ofs -= jeb->offset; in jffs2_sum_add_kvec() 274 temp->offset = cpu_to_je32(ofs); in jffs2_sum_add_kvec() 290 temp->offset = cpu_to_je32(ofs); in jffs2_sum_add_kvec() 325 temp->offset = cpu_to_je32(ofs); in jffs2_sum_add_kvec() 336 temp->offset = cpu_to_je32(ofs); in jffs2_sum_add_kvec() 381 return jffs2_link_node_ref(c, jeb, jeb->offset + ofs, len, ic); in sum_link_node_ref() [all …]
|
/fs/coda/ |
D | upcall.c | 137 int offset; in venus_lookup() local 139 offset = INSIZE(lookup); in venus_lookup() 140 insize = max_t(unsigned int, offset + length +1, OUTSIZE(lookup)); in venus_lookup() 144 inp->coda_lookup.name = offset; in venus_lookup() 147 memcpy((char *)(inp) + offset, name, length); in venus_lookup() 148 *((char *)inp + offset + length) = '\0'; in venus_lookup() 208 int offset; in venus_mkdir() local 210 offset = INSIZE(mkdir); in venus_mkdir() 211 insize = max_t(unsigned int, offset + length + 1, OUTSIZE(mkdir)); in venus_mkdir() 216 inp->coda_mkdir.name = offset; in venus_mkdir() [all …]
|
/fs/hfsplus/ |
D | bitmap.c | 20 u32 offset, u32 *max) in hfsplus_block_allocate() argument 34 hfs_dbg(BITMAP, "block_allocate: %u,%u,%u\n", size, offset, len); in hfsplus_block_allocate() 37 page = read_mapping_page(mapping, offset / PAGE_CACHE_BITS, NULL); in hfsplus_block_allocate() 43 curr = pptr + (offset & (PAGE_CACHE_BITS - 1)) / 32; in hfsplus_block_allocate() 44 i = offset % 32; in hfsplus_block_allocate() 45 offset &= ~(PAGE_CACHE_BITS - 1); in hfsplus_block_allocate() 46 if ((size ^ offset) / PAGE_CACHE_BITS) in hfsplus_block_allocate() 78 offset += PAGE_CACHE_BITS; in hfsplus_block_allocate() 79 if (offset >= size) in hfsplus_block_allocate() 81 page = read_mapping_page(mapping, offset / PAGE_CACHE_BITS, in hfsplus_block_allocate() [all …]
|
/fs/xfs/ |
D | xfs_aops.c | 49 xfs_off_t offset, in __xfs_setfilesize() argument 55 isize = xfs_new_eof(ip, offset + size); in __xfs_setfilesize() 62 trace_xfs_setfilesize(ip, offset, size); in __xfs_setfilesize() 74 xfs_off_t offset, in xfs_setfilesize() argument 85 return __xfs_setfilesize(ip, tp, offset, size); in xfs_setfilesize() 122 xfs_off_t offset = ioend->io_offset; in xfs_end_ioend() local 152 xfs_reflink_cancel_cow_range(ip, offset, size, true); in xfs_end_ioend() 154 XFS_B_TO_FSBT(mp, offset), in xfs_end_ioend() 164 error = xfs_reflink_end_cow(ip, offset, size); in xfs_end_ioend() 166 error = xfs_iomap_write_unwritten(ip, offset, size, false); in xfs_end_ioend() [all …]
|
D | xfs_iomap.c | 79 iomap->offset = XFS_FSB_TO_B(mp, imap->br_startoff); in xfs_bmbt_to_iomap() 102 iomap->offset = XFS_FSB_TO_B(ip->i_mount, offset_fsb); in xfs_hole_to_iomap() 111 loff_t offset, in xfs_iomap_end_fsb() argument 114 ASSERT(offset <= mp->m_super->s_maxbytes); in xfs_iomap_end_fsb() 115 return min(XFS_B_TO_FSB(mp, offset + count), in xfs_iomap_end_fsb() 364 loff_t offset, in xfs_iomap_prealloc_size() argument 372 xfs_fileoff_t offset_fsb = XFS_B_TO_FSBT(mp, offset); in xfs_iomap_prealloc_size() 423 alloc_blocks = XFS_B_TO_FSB(mp, offset); in xfs_iomap_prealloc_size() 502 xfs_off_t offset, in xfs_iomap_write_unwritten() argument 518 trace_xfs_unwritten_convert(ip, offset, count); in xfs_iomap_write_unwritten() [all …]
|
/fs/romfs/ |
D | super.c | 105 loff_t offset, size; in romfs_readpage() local 115 offset = page_offset(page); in romfs_readpage() 119 if (offset < size) { in romfs_readpage() 120 size -= offset; in romfs_readpage() 123 pos = ROMFS_I(inode)->i_dataoffset + offset; in romfs_readpage() 155 unsigned long offset, maxoff; in romfs_readdir() local 162 offset = ctx->pos; in romfs_readdir() 163 if (!offset) { in romfs_readdir() 164 offset = i->i_ino & ROMFH_MASK; in romfs_readdir() 165 ret = romfs_dev_read(i->i_sb, offset, &ri, ROMFH_SIZE); in romfs_readdir() [all …]
|
/fs/xfs/libxfs/ |
D | xfs_dir2_data.c | 116 unsigned int offset; in __xfs_dir3_data_check() local 127 offset = geo->data_entry_offset; in __xfs_dir3_data_check() 155 if (bf[0].offset) in __xfs_dir3_data_check() 160 if (bf[1].offset) in __xfs_dir3_data_check() 165 if (bf[2].offset) in __xfs_dir3_data_check() 177 while (offset < end) { in __xfs_dir3_data_check() 178 struct xfs_dir2_data_unused *dup = bp->b_addr + offset; in __xfs_dir3_data_check() 179 struct xfs_dir2_data_entry *dep = bp->b_addr + offset; in __xfs_dir3_data_check() 191 if (offset + be16_to_cpu(dup->length) > end) in __xfs_dir3_data_check() 194 offset) in __xfs_dir3_data_check() [all …]
|
D | xfs_rmap.h | 27 xfs_fileoff_t offset) in xfs_rmap_ino_owner() argument 30 oi->oi_offset = offset; in xfs_rmap_ino_owner() 65 __u64 offset, in xfs_rmap_irec_offset_unpack() argument 68 if (offset & ~(XFS_RMAP_OFF_MASK | XFS_RMAP_OFF_FLAGS)) in xfs_rmap_irec_offset_unpack() 70 irec->rm_offset = XFS_RMAP_OFF(offset); in xfs_rmap_irec_offset_unpack() 72 if (offset & XFS_RMAP_OFF_ATTR_FORK) in xfs_rmap_irec_offset_unpack() 74 if (offset & XFS_RMAP_OFF_BMBT_BLOCK) in xfs_rmap_irec_offset_unpack() 76 if (offset & XFS_RMAP_OFF_UNWRITTEN) in xfs_rmap_irec_offset_unpack() 85 uint64_t *offset, in xfs_owner_info_unpack() argument 91 *offset = oinfo->oi_offset; in xfs_owner_info_unpack() [all …]
|