/fs/btrfs/ |
D | free-space-cache.c | 22 static int tree_insert_offset(struct rb_root *root, u64 offset, in tree_insert_offset() argument 33 if (offset < info->offset) in tree_insert_offset() 35 else if (offset > info->offset) in tree_insert_offset() 77 u64 offset, u64 bytes, in tree_search_offset() argument 86 if (offset < entry->offset) { in tree_search_offset() 88 (!ret || entry->offset < ret->offset) && in tree_search_offset() 92 } else if (offset > entry->offset) { in tree_search_offset() 93 if ((entry->offset + entry->bytes - 1) >= offset && in tree_search_offset() 116 u64 offset, u64 bytes) in tree_search_bytes() argument 132 if (offset <= entry->offset) { in tree_search_bytes() [all …]
|
D | file-item.c | 40 u64 num_bytes, u64 offset, u64 ram_bytes, in btrfs_insert_file_extent() argument 52 file_key.offset = pos; in btrfs_insert_file_extent() 65 btrfs_set_file_extent_offset(leaf, item, offset); in btrfs_insert_file_extent() 96 file_key.offset = bytenr; in btrfs_lookup_csum() 111 csum_offset = (bytenr - found_key.offset) >> in btrfs_lookup_csum() 135 u64 offset, int mod) in btrfs_lookup_file_extent() argument 143 file_key.offset = offset; in btrfs_lookup_file_extent() 156 u64 offset; in btrfs_lookup_bio_sums() local 176 offset = page_offset(bvec->bv_page) + bvec->bv_offset; in btrfs_lookup_bio_sums() 177 ret = btrfs_find_ordered_sum(inode, offset, disk_bytenr, &sum); in btrfs_lookup_bio_sums() [all …]
|
/fs/udf/ |
D | directory.c | 24 int *pos, int *offset, struct buffer_head **bh, 27 int loffset = *offset; 34 ad = (uint8_t *)(*bh)->b_data + *offset; 35 *offset += ad_size; 43 if (*offset == dir->i_sb->s_blocksize) { 51 } else if (*offset > dir->i_sb->s_blocksize) { 67 *offset = ad_size - remainder; 79 sector_t *offset) in udf_fileident_read() argument 107 int lextoffset = epos->offset; in udf_fileident_read() 114 block = udf_get_lb_pblock(dir->i_sb, *eloc, *offset); in udf_fileident_read() [all …]
|
D | misc.c | 52 int offset; in udf_add_extendedattr() local 64 offset = inode->i_sb->s_blocksize - udf_file_entry_alloc_offset(inode) - in udf_add_extendedattr() 69 if (loc & 0x01 && offset >= size) { in udf_add_extendedattr() 102 offset = iinfo->i_lenEAttr; in udf_add_extendedattr() 108 memmove(&ea[offset - aal + size], in udf_add_extendedattr() 109 &ea[aal], offset - aal); in udf_add_extendedattr() 110 offset -= aal; in udf_add_extendedattr() 118 memmove(&ea[offset - ial + size], in udf_add_extendedattr() 119 &ea[ial], offset - ial); in udf_add_extendedattr() 120 offset -= ial; in udf_add_extendedattr() [all …]
|
D | truncate.c | 108 epos.offset -= adsize; in udf_truncate_tail_extent() 110 epos.offset += adsize; in udf_truncate_tail_extent() 153 epos.offset -= adsize; in udf_discard_prealloc() 158 epos.offset - in udf_discard_prealloc() 165 cpu_to_le32(epos.offset - in udf_discard_prealloc() 169 udf_update_tag(epos.bh->b_data, epos.offset); in udf_discard_prealloc() 207 sector_t first_block = inode->i_size >> sb->s_blocksize_bits, offset; in udf_truncate_extents() local 219 etype = inode_bmap(inode, first_block, &epos, &eloc, &elen, &offset); in udf_truncate_extents() 220 byte_offset = (offset << sb->s_blocksize_bits) + in udf_truncate_extents() 223 epos.offset -= adsize; in udf_truncate_extents() [all …]
|
/fs/squashfs/ |
D | file.c | 61 static struct meta_index *locate_meta_index(struct inode *inode, int offset, in locate_meta_index() argument 70 TRACE("locate_meta_index: index %d, offset %d\n", index, offset); in locate_meta_index() 77 msblk->meta_index[i].offset >= offset && in locate_meta_index() 78 msblk->meta_index[i].offset <= index && in locate_meta_index() 81 msblk->meta_index[i].offset); in locate_meta_index() 83 offset = meta->offset; in locate_meta_index() 100 static struct meta_index *empty_meta_index(struct inode *inode, int offset, in empty_meta_index() argument 109 TRACE("empty_meta_index: offset %d, skip %d\n", offset, skip); in empty_meta_index() 150 meta->offset = offset; in empty_meta_index() 175 u64 *start_block, int *offset) in read_indexes() argument [all …]
|
D | inode.c | 112 int err, type, offset = SQUASHFS_INODE_OFFSET(ino); in squashfs_read_inode() local 122 &offset, sizeof(*sqshb_ino)); in squashfs_read_inode() 131 offset = SQUASHFS_INODE_OFFSET(ino); in squashfs_read_inode() 141 err = squashfs_read_metadata(sb, sqsh_ino, &block, &offset, in squashfs_read_inode() 148 frag_offset = le32_to_cpu(sqsh_ino->offset); in squashfs_read_inode() 170 squashfs_i(inode)->offset = offset; in squashfs_read_inode() 175 offset, squashfs_i(inode)->start, block, offset); in squashfs_read_inode() 184 err = squashfs_read_metadata(sb, sqsh_ino, &block, &offset, in squashfs_read_inode() 191 frag_offset = le32_to_cpu(sqsh_ino->offset); in squashfs_read_inode() 215 squashfs_i(inode)->offset = offset; in squashfs_read_inode() [all …]
|
D | block.c | 47 u64 *cur_index, int *offset, int *length) in get_block_length() argument 56 if (msblk->devblksize - *offset == 1) { in get_block_length() 57 *length = (unsigned char) bh->b_data[*offset]; in get_block_length() 63 *offset = 1; in get_block_length() 65 *length = (unsigned char) bh->b_data[*offset] | in get_block_length() 66 (unsigned char) bh->b_data[*offset + 1] << 8; in get_block_length() 67 *offset += 2; in get_block_length() 87 int offset = index & ((1 << msblk->devblksize_log2) - 1); in squashfs_read_data() local 101 bytes = -offset; in squashfs_read_data() 128 bh[0] = get_block_length(sb, &cur_index, &offset, &length); in squashfs_read_data() [all …]
|
/fs/romfs/ |
D | inode.c | 200 romfs_strnlen(struct inode *i, unsigned long offset, unsigned long count) in romfs_strnlen() argument 206 if (offset >= maxsize) in romfs_strnlen() 210 if (count > maxsize || offset+count > maxsize) in romfs_strnlen() 211 count = maxsize-offset; in romfs_strnlen() 213 bh = sb_bread(i->i_sb, offset>>ROMBSBITS); in romfs_strnlen() 217 avail = ROMBSIZE - (offset & ROMBMASK); in romfs_strnlen() 219 res = strnlen(((char *)bh->b_data)+(offset&ROMBMASK), maxsize); in romfs_strnlen() 226 offset += maxsize; in romfs_strnlen() 228 bh = sb_bread(i->i_sb, offset>>ROMBSBITS); in romfs_strnlen() 242 romfs_copyfrom(struct inode *i, void *dest, unsigned long offset, unsigned long count) in romfs_copyfrom() argument [all …]
|
/fs/ecryptfs/ |
D | read_write.c | 40 loff_t offset, size_t size) in ecryptfs_write_lower() argument 50 inode_info->lower_file->f_pos = offset; in ecryptfs_write_lower() 87 loff_t offset; in ecryptfs_write_lower_page_segment() local 90 offset = ((((loff_t)page_for_lower->index) << PAGE_CACHE_SHIFT) in ecryptfs_write_lower_page_segment() 93 rc = ecryptfs_write_lower(ecryptfs_inode, virt, offset, size); in ecryptfs_write_lower_page_segment() 116 int ecryptfs_write(struct file *ecryptfs_file, char *data, loff_t offset, in ecryptfs_write() argument 131 if (offset > ecryptfs_file_size) in ecryptfs_write() 134 pos = offset; in ecryptfs_write() 135 while (pos < (offset + size)) { in ecryptfs_write() 139 size_t total_remaining_bytes = ((offset + size) - pos); in ecryptfs_write() [all …]
|
/fs/coda/ |
D | upcall.c | 136 int offset; in venus_lookup() local 138 offset = INSIZE(lookup); in venus_lookup() 139 insize = max_t(unsigned int, offset + length +1, OUTSIZE(lookup)); in venus_lookup() 143 inp->coda_lookup.name = offset; in venus_lookup() 146 memcpy((char *)(inp) + offset, name, length); in venus_lookup() 147 *((char *)inp + offset + length) = '\0'; in venus_lookup() 207 int offset; in venus_mkdir() local 209 offset = INSIZE(mkdir); in venus_mkdir() 210 insize = max_t(unsigned int, offset + length + 1, OUTSIZE(mkdir)); in venus_mkdir() 215 inp->coda_mkdir.name = offset; in venus_mkdir() [all …]
|
/fs/hfsplus/ |
D | bitmap.c | 18 int hfsplus_block_allocate(struct super_block *sb, u32 size, u32 offset, u32 *max) in hfsplus_block_allocate() argument 31 dprint(DBG_BITMAP, "block_allocate: %u,%u,%u\n", size, offset, len); in hfsplus_block_allocate() 34 page = read_mapping_page(mapping, offset / PAGE_CACHE_BITS, NULL); in hfsplus_block_allocate() 40 curr = pptr + (offset & (PAGE_CACHE_BITS - 1)) / 32; in hfsplus_block_allocate() 41 i = offset % 32; in hfsplus_block_allocate() 42 offset &= ~(PAGE_CACHE_BITS - 1); in hfsplus_block_allocate() 43 if ((size ^ offset) / PAGE_CACHE_BITS) in hfsplus_block_allocate() 75 offset += PAGE_CACHE_BITS; in hfsplus_block_allocate() 76 if (offset >= size) in hfsplus_block_allocate() 78 page = read_mapping_page(mapping, offset / PAGE_CACHE_BITS, in hfsplus_block_allocate() [all …]
|
/fs/jffs2/ |
D | read.c | 53 je32_to_cpu(ri->offset), buf)); in jffs2_read_dnode() 154 unsigned char *buf, uint32_t offset, uint32_t len) in jffs2_read_inode_range() argument 156 uint32_t end = offset + len; in jffs2_read_inode_range() 161 f->inocache->ino, offset, offset+len)); in jffs2_read_inode_range() 163 frag = jffs2_lookup_node_frag(&f->fragtree, offset); in jffs2_read_inode_range() 168 while(offset < end) { in jffs2_read_inode_range() 169 D2(printk(KERN_DEBUG "jffs2_read_inode_range: offset %d, end %d\n", offset, end)); in jffs2_read_inode_range() 170 if (unlikely(!frag || frag->ofs > offset)) { in jffs2_read_inode_range() 171 uint32_t holesize = end - offset; in jffs2_read_inode_range() 173 …in ino #%u fraglist. frag->ofs = 0x%08x, offset = 0x%08x\n", f->inocache->ino, frag->ofs, offset)); in jffs2_read_inode_range() [all …]
|
D | summary.c | 124 temp->offset = cpu_to_je32(ofs); /* relative offset from the begining of the jeb */ in jffs2_sum_add_inode_mem() 142 temp->offset = cpu_to_je32(ofs); /* relative from the begining of the jeb */ in jffs2_sum_add_dirent_mem() 167 temp->offset = cpu_to_je32(ofs); in jffs2_sum_add_xattr_mem() 183 temp->offset = cpu_to_je32(ofs); in jffs2_sum_add_xref_mem() 259 ofs -= jeb->offset; in jffs2_sum_add_kvec() 272 temp->offset = cpu_to_je32(ofs); in jffs2_sum_add_kvec() 288 temp->offset = cpu_to_je32(ofs); in jffs2_sum_add_kvec() 323 temp->offset = cpu_to_je32(ofs); in jffs2_sum_add_kvec() 334 temp->offset = cpu_to_je32(ofs); in jffs2_sum_add_kvec() 379 return jffs2_link_node_ref(c, jeb, jeb->offset + ofs, len, ic); in sum_link_node_ref() [all …]
|
D | erase.c | 44 bad_offset = jeb->offset; in jffs2_erase_block() 49 jeb->offset, jeb->offset, jeb->offset + c->sector_size)); in jffs2_erase_block() 67 instr->addr = jeb->offset; in jffs2_erase_block() 86 …D1(printk(KERN_DEBUG "Erase at 0x%08x failed: %d. Refiling on erase_pending_list\n", jeb->offset, … in jffs2_erase_block() 99 …k(KERN_WARNING "Erase at 0x%08x failed immediately: -EROFS. Is the sector locked?\n", jeb->offset); in jffs2_erase_block() 101 printk(KERN_WARNING "Erase at 0x%08x failed immediately: errno %d\n", jeb->offset, ret); in jffs2_erase_block() 131 D1(printk(KERN_DEBUG "Starting erase of pending block 0x%08x\n", jeb->offset)); in jffs2_erase_pending_blocks() 164 D1(printk(KERN_DEBUG "Erase completed successfully at 0x%08x\n", jeb->offset)); in jffs2_erase_succeeded() 243 if (SECTOR_ADDR((*prev)->flash_offset) == jeb->offset) { in jffs2_remove_node_refs_from_ino_list() 268 jeb->offset, jeb->offset + c->sector_size, ic->ino)); in jffs2_remove_node_refs_from_ino_list() [all …]
|
/fs/xfs/ |
D | xfs_iomap.c | 57 xfs_off_t offset, in xfs_iomap_enter_trace() argument 68 (void *)((unsigned long)((offset >> 32) & 0xffffffff)), in xfs_iomap_enter_trace() 69 (void *)((unsigned long)(offset & 0xffffffff)), in xfs_iomap_enter_trace() 86 xfs_off_t offset, in xfs_iomap_map_trace() argument 100 (void *)((unsigned long)((offset >> 32) & 0xffffffff)), in xfs_iomap_map_trace() 101 (void *)((unsigned long)(offset & 0xffffffff)), in xfs_iomap_map_trace() 114 #define xfs_iomap_enter_trace(tag, io, offset, count) argument 115 #define xfs_iomap_map_trace(tag, io, offset, count, iomapp, imapp, flags) argument 126 xfs_off_t offset, in xfs_imap_to_bmap() argument 140 iomapp->iomap_delta = offset - iomapp->iomap_offset; in xfs_imap_to_bmap() [all …]
|
/fs/9p/ |
D | vfs_file.c | 134 u64 offset) in v9fs_file_readn() argument 140 (long long unsigned) offset, count); in v9fs_file_readn() 145 n = p9_client_read(fid, data, udata, offset, count); in v9fs_file_readn() 154 offset += n; in v9fs_file_readn() 176 loff_t * offset) in v9fs_file_read() argument 181 P9_DPRINTK(P9_DEBUG_VFS, "count %zu offset %lld\n", count, *offset); in v9fs_file_read() 185 ret = v9fs_file_readn(filp, NULL, udata, count, *offset); in v9fs_file_read() 187 ret = p9_client_read(fid, NULL, udata, *offset, count); in v9fs_file_read() 190 *offset += ret; in v9fs_file_read() 206 size_t count, loff_t * offset) in v9fs_file_write() argument [all …]
|
/fs/ |
D | sync.c | 204 SYSCALL_DEFINE(sync_file_range)(int fd, loff_t offset, loff_t nbytes, in SYSCALL_DEFINE() 217 endbyte = offset + nbytes; in SYSCALL_DEFINE() 219 if ((s64)offset < 0) in SYSCALL_DEFINE() 223 if (endbyte < offset) in SYSCALL_DEFINE() 227 if (offset >= (0x100000000ULL << PAGE_CACHE_SHIFT)) { in SYSCALL_DEFINE() 259 ret = do_sync_mapping_range(file->f_mapping, offset, endbyte, flags); in SYSCALL_DEFINE() 266 asmlinkage long SyS_sync_file_range(long fd, loff_t offset, loff_t nbytes, in SyS_sync_file_range() argument 269 return SYSC_sync_file_range((int) fd, offset, nbytes, in SyS_sync_file_range() 278 loff_t offset, loff_t nbytes) in SYSCALL_DEFINE() 280 return sys_sync_file_range(fd, offset, nbytes, flags); in SYSCALL_DEFINE() [all …]
|
/fs/xfs/linux-2.6/ |
D | xfs_lrw.c | 64 loff_t offset, in xfs_rw_enter_trace() argument 76 (void *)((unsigned long)((offset >> 32) & 0xffffffff)), in xfs_rw_enter_trace() 77 (void *)((unsigned long)(offset & 0xffffffff)), in xfs_rw_enter_trace() 91 xfs_off_t offset, in xfs_inval_cached_trace() argument 102 (void *)((unsigned long)((offset >> 32) & 0xffffffff)), in xfs_inval_cached_trace() 103 (void *)((unsigned long)(offset & 0xffffffff)), in xfs_inval_cached_trace() 141 unsigned offset, bytes; in xfs_iozero() local 144 offset = (pos & (PAGE_CACHE_SIZE -1)); /* Within page */ in xfs_iozero() 145 bytes = PAGE_CACHE_SIZE - offset; in xfs_iozero() 155 zero_user(page, offset, bytes); in xfs_iozero() [all …]
|
D | xfs_aops.c | 111 loff_t offset = page_offset(page); in xfs_page_trace() local 131 (void *)((unsigned long)((offset >> 32) & 0xffffffff)), in xfs_page_trace() 132 (void *)((unsigned long)(offset & 0xffffffff)), in xfs_page_trace() 284 xfs_off_t offset = ioend->io_offset; in xfs_end_bio_unwritten() local 290 error = xfs_iomap_write_unwritten(ip, offset, size); in xfs_end_bio_unwritten() 358 loff_t offset, in xfs_map_blocks() argument 365 return -xfs_iomap(XFS_I(inode), offset, count, flags, mapp, &nmaps); in xfs_map_blocks() 371 loff_t offset) in xfs_iomap_valid() argument 373 return offset >= iomapp->iomap_offset && in xfs_iomap_valid() 374 offset < iomapp->iomap_offset + iomapp->iomap_bsize; in xfs_iomap_valid() [all …]
|
/fs/adfs/ |
D | dir_fplus.c | 102 dir_memcpy(struct adfs_dir *dir, unsigned int offset, void *to, int len) in dir_memcpy() argument 107 buffer = offset >> sb->s_blocksize_bits; in dir_memcpy() 108 offset &= sb->s_blocksize - 1; in dir_memcpy() 110 partial = sb->s_blocksize - offset; in dir_memcpy() 113 memcpy(to, dir->bh[buffer]->b_data + offset, len); in dir_memcpy() 119 memcpy(c, dir->bh[buffer]->b_data + offset, partial); in dir_memcpy() 129 unsigned int offset; in adfs_fplus_getnext() local 135 offset = offsetof(struct adfs_bigdirheader, bigdirname); in adfs_fplus_getnext() 136 offset += ((le32_to_cpu(h->bigdirnamelen) + 4) & ~3); in adfs_fplus_getnext() 137 offset += dir->pos * sizeof(struct adfs_bigdirentry); in adfs_fplus_getnext() [all …]
|
/fs/isofs/ |
D | namei.c | 56 unsigned long block, f_pos, offset, block_saved, offset_saved; in isofs_find_entry() local 64 offset = 0; in isofs_find_entry() 78 de = (struct iso_directory_record *) (bh->b_data + offset); in isofs_find_entry() 86 offset = 0; in isofs_find_entry() 91 offset_saved = offset; in isofs_find_entry() 92 offset += de_len; in isofs_find_entry() 96 if (offset >= bufsize) { in isofs_find_entry() 97 int slop = bufsize - offset + de_len; in isofs_find_entry() 99 offset &= bufsize - 1; in isofs_find_entry() 103 if (offset) { in isofs_find_entry() [all …]
|
/fs/smbfs/ |
D | file.c | 58 loff_t offset = (loff_t)page->index << PAGE_CACHE_SHIFT; in smb_readpage_sync() local 65 DENTRY_PATH(dentry), count, offset, rsize); in smb_readpage_sync() 75 result = server->ops->read(dentry->d_inode,offset,rsize,buffer); in smb_readpage_sync() 80 offset += result; in smb_readpage_sync() 122 loff_t offset; in smb_writepage_sync() local 128 offset = ((loff_t)page->index << PAGE_CACHE_SHIFT) + pageoffset; in smb_writepage_sync() 130 inode->i_ino, SMB_I(inode)->fileid, count, offset, wsize); in smb_writepage_sync() 138 write_ret = server->ops->write(inode, offset, wsize, buffer); in smb_writepage_sync() 152 offset += wsize; in smb_writepage_sync() 159 if (offset > inode->i_size) in smb_writepage_sync() [all …]
|
/fs/fat/ |
D | fatent.c | 25 int *offset, sector_t *blocknr) in fat12_ent_blocknr() argument 30 *offset = bytes & (sb->s_blocksize - 1); in fat12_ent_blocknr() 35 int *offset, sector_t *blocknr) in fat_ent_blocknr() argument 40 *offset = bytes & (sb->s_blocksize - 1); in fat_ent_blocknr() 44 static void fat12_ent_set_ptr(struct fat_entry *fatent, int offset) in fat12_ent_set_ptr() argument 48 WARN_ON(offset >= (bhs[0]->b_size - 1)); in fat12_ent_set_ptr() 49 fatent->u.ent12_p[0] = bhs[0]->b_data + offset; in fat12_ent_set_ptr() 50 fatent->u.ent12_p[1] = bhs[0]->b_data + (offset + 1); in fat12_ent_set_ptr() 52 WARN_ON(offset != (bhs[0]->b_size - 1)); in fat12_ent_set_ptr() 53 fatent->u.ent12_p[0] = bhs[0]->b_data + offset; in fat12_ent_set_ptr() [all …]
|
/fs/dlm/ |
D | midcomms.c | 34 static void copy_from_cb(void *dst, const void *base, unsigned offset, in copy_from_cb() argument 39 if ((copy + offset) > limit) in copy_from_cb() 40 copy = limit - offset; in copy_from_cb() 41 memcpy(dst, base + offset, copy); in copy_from_cb() 59 unsigned offset, unsigned len, unsigned limit) in dlm_process_incoming_buffer() argument 78 copy_from_cb(p, base, offset, sizeof(struct dlm_header), in dlm_process_incoming_buffer() 120 copy_from_cb(p, base, offset, msglen, limit); in dlm_process_incoming_buffer() 125 offset += msglen; in dlm_process_incoming_buffer() 126 offset &= (limit - 1); in dlm_process_incoming_buffer()
|