Home
last modified time | relevance | path

Searched refs:new_size (Results 1 – 25 of 47) sorted by relevance

12

/fs/xfs/libxfs/
Dxfs_inode_fork.c357 size_t new_size; in xfs_iroot_realloc() local
375 new_size = XFS_BMAP_BROOT_SPACE_CALC(mp, rec_diff); in xfs_iroot_realloc()
376 ifp->if_broot = kmem_alloc(new_size, KM_NOFS); in xfs_iroot_realloc()
377 ifp->if_broot_bytes = (int)new_size; in xfs_iroot_realloc()
389 new_size = XFS_BMAP_BROOT_SPACE_CALC(mp, new_max); in xfs_iroot_realloc()
390 ifp->if_broot = kmem_realloc(ifp->if_broot, new_size, in xfs_iroot_realloc()
395 (int)new_size); in xfs_iroot_realloc()
396 ifp->if_broot_bytes = (int)new_size; in xfs_iroot_realloc()
413 new_size = XFS_BMAP_BROOT_SPACE_CALC(mp, new_max); in xfs_iroot_realloc()
415 new_size = 0; in xfs_iroot_realloc()
[all …]
Dxfs_iext_tree.c599 int64_t new_size = ifp->if_bytes + sizeof(struct xfs_iext_rec); in xfs_iext_realloc_root() local
603 if (new_size / sizeof(struct xfs_iext_rec) == RECS_PER_LEAF) in xfs_iext_realloc_root()
604 new_size = NODE_SIZE; in xfs_iext_realloc_root()
606 new = kmem_realloc(ifp->if_u1.if_root, new_size, KM_NOFS); in xfs_iext_realloc_root()
607 memset(new + ifp->if_bytes, 0, new_size - ifp->if_bytes); in xfs_iext_realloc_root()
/fs/reiserfs/
Dobjectid.c183 int new_size = (s->s_blocksize - SB_SIZE) / sizeof(__u32) / 2 * 2; in reiserfs_convert_objectid_map_v1() local
193 if (cur_size > new_size) { in reiserfs_convert_objectid_map_v1()
198 objectid_map[new_size - 1] = objectid_map[cur_size - 1]; in reiserfs_convert_objectid_map_v1()
199 set_sb_oid_cursize(disk_sb, new_size); in reiserfs_convert_objectid_map_v1()
202 for (i = new_size - 1; i >= 0; i--) { in reiserfs_convert_objectid_map_v1()
203 objectid_map[i + (old_max - new_size)] = objectid_map[i]; in reiserfs_convert_objectid_map_v1()
207 set_sb_oid_maxsize(disk_sb, new_size); in reiserfs_convert_objectid_map_v1()
Dxattr.c529 size_t new_size; in reiserfs_xattr_set_handle() local
596 new_size = buffer_size + sizeof(struct reiserfs_xattr_header); in reiserfs_xattr_set_handle()
597 if (!err && new_size < i_size_read(d_inode(dentry))) { in reiserfs_xattr_set_handle()
600 .ia_size = new_size, in reiserfs_xattr_set_handle()
/fs/jfs/
Dxattr.c593 int new_size) in ea_put() argument
599 if (new_size == 0) { in ea_put()
603 assert(new_size <= sizeof (ji->i_inline_ea)); in ea_put()
606 DXDsize(&ea_buf->new_ea, new_size); in ea_put()
610 rc = ea_write(inode, ea_buf->xattr, new_size, &ea_buf->new_ea); in ea_put()
617 rc = ea_write(inode, ea_buf->xattr, new_size, &ea_buf->new_ea); in ea_put()
663 int new_size; in __jfs_setxattr() local
679 new_size = sizeof (struct jfs_ea_list); in __jfs_setxattr()
695 new_size += EA_SIZE(ea); in __jfs_setxattr()
710 new_size += sizeof (struct jfs_ea) + namelen + 1 + value_len; in __jfs_setxattr()
[all …]
Dnamei.c471 s64 new_size = 0; in jfs_unlink() local
526 if ((new_size = commitZeroLink(tid, ip)) < 0) { in jfs_unlink()
532 rc = new_size; in jfs_unlink()
545 if (new_size) in jfs_unlink()
561 while (new_size && (rc == 0)) { in jfs_unlink()
564 new_size = xtTruncate_pmap(tid, ip, new_size); in jfs_unlink()
565 if (new_size < 0) { in jfs_unlink()
567 rc = new_size; in jfs_unlink()
1084 s64 new_size = 0; in jfs_rename() local
1198 if ((new_size = commitZeroLink(tid, new_ip)) < 0) { in jfs_rename()
[all …]
/fs/xfs/
Dxfs_inode.h104 xfs_new_eof(struct xfs_inode *ip, xfs_fsize_t new_size) in xfs_new_eof() argument
108 if (new_size > i_size || new_size < 0) in xfs_new_eof()
109 new_size = i_size; in xfs_new_eof()
110 return new_size > ip->i_d.di_size ? new_size : 0; in xfs_new_eof()
445 xfs_fsize_t new_size) in xfs_itruncate_extents() argument
447 return xfs_itruncate_extents_flags(tpp, ip, whichfork, new_size, 0); in xfs_itruncate_extents()
Dxfs_file.c803 loff_t new_size = 0; in xfs_file_fallocate() local
867 new_size = i_size_read(inode) - len; in xfs_file_fallocate()
889 new_size = isize + len; in xfs_file_fallocate()
902 new_size = offset + len; in xfs_file_fallocate()
903 error = inode_newsize_ok(inode, new_size); in xfs_file_fallocate()
944 if (new_size) { in xfs_file_fallocate()
948 iattr.ia_size = new_size; in xfs_file_fallocate()
/fs/ubifs/
Dreplay.c58 loff_t new_size; member
187 min_blk = r->new_size / UBIFS_BLOCK_SIZE; in trun_remove_range()
188 if (r->new_size & (UBIFS_BLOCK_SIZE - 1)) in trun_remove_range()
286 r->new_size); in apply_replay_entry()
386 loff_t old_size, loff_t new_size) in insert_node() argument
409 r->new_size = new_size; in insert_node()
747 loff_t new_size = le64_to_cpu(ino->size); in replay_bud() local
753 &used, 0, new_size); in replay_bud()
759 loff_t new_size = le32_to_cpu(dn->size) + in replay_bud() local
765 &used, 0, new_size); in replay_bud()
[all …]
Dfile.c1114 loff_t old_size = inode->i_size, new_size = attr->ia_size; in do_truncation() local
1115 int offset = new_size & (UBIFS_BLOCK_SIZE - 1), budgeted = 1; in do_truncation()
1118 dbg_gen("ino %lu, size %lld -> %lld", inode->i_ino, old_size, new_size); in do_truncation()
1126 if (new_size & (UBIFS_BLOCK_SIZE - 1)) in do_truncation()
1138 if (new_size || err != -ENOSPC) in do_truncation()
1143 truncate_setsize(inode, new_size); in do_truncation()
1146 pgoff_t index = new_size >> PAGE_SHIFT; in do_truncation()
1164 offset = new_size & in do_truncation()
1192 err = ubifs_jnl_truncate(c, inode, old_size, new_size); in do_truncation()
1219 loff_t new_size = attr->ia_size; in do_setattr() local
[all …]
Drecovery.c1355 int deletion, loff_t new_size) in ubifs_recover_size_accum() argument
1368 e->i_size = new_size; in ubifs_recover_size_accum()
1371 err = add_ino(c, inum, new_size, 0, 1); in ubifs_recover_size_accum()
1380 if (new_size > e->d_size) in ubifs_recover_size_accum()
1381 e->d_size = new_size; in ubifs_recover_size_accum()
1383 err = add_ino(c, inum, 0, new_size, 0); in ubifs_recover_size_accum()
1391 e->d_size = new_size; in ubifs_recover_size_accum()
Djournal.c1509 loff_t old_size, loff_t new_size) in ubifs_jnl_truncate() argument
1523 (unsigned long)inum, old_size, new_size); in ubifs_jnl_truncate()
1541 trun->new_size = cpu_to_le64(new_size); in ubifs_jnl_truncate()
1544 dlen = new_size & (UBIFS_BLOCK_SIZE - 1); in ubifs_jnl_truncate()
1548 blk = new_size >> UBIFS_BLOCK_SHIFT; in ubifs_jnl_truncate()
1626 bit = new_size & (UBIFS_BLOCK_SIZE - 1); in ubifs_jnl_truncate()
1627 blk = (new_size >> UBIFS_BLOCK_SHIFT) + (bit ? 1 : 0); in ubifs_jnl_truncate()
/fs/ntfs/
Dattrib.c1445 int ntfs_attr_record_resize(MFT_RECORD *m, ATTR_RECORD *a, u32 new_size) in ntfs_attr_record_resize() argument
1447 ntfs_debug("Entering for new_size %u.", new_size); in ntfs_attr_record_resize()
1449 if (new_size & 7) in ntfs_attr_record_resize()
1450 new_size = (new_size + 7) & ~7; in ntfs_attr_record_resize()
1452 if (new_size != le32_to_cpu(a->length)) { in ntfs_attr_record_resize()
1454 le32_to_cpu(a->length) + new_size; in ntfs_attr_record_resize()
1459 memmove((u8*)a + new_size, (u8*)a + le32_to_cpu(a->length), in ntfs_attr_record_resize()
1465 if (new_size >= offsetof(ATTR_REC, length) + sizeof(a->length)) in ntfs_attr_record_resize()
1466 a->length = cpu_to_le32(new_size); in ntfs_attr_record_resize()
1490 const u32 new_size) in ntfs_resident_attr_value_resize() argument
[all …]
Drunlist.c61 int old_size, int new_size) in ntfs_rl_realloc() argument
66 new_size = PAGE_ALIGN(new_size * sizeof(*rl)); in ntfs_rl_realloc()
67 if (old_size == new_size) in ntfs_rl_realloc()
70 new_rl = ntfs_malloc_nofs(new_size); in ntfs_rl_realloc()
75 if (unlikely(old_size > new_size)) in ntfs_rl_realloc()
76 old_size = new_size; in ntfs_rl_realloc()
107 int old_size, int new_size) in ntfs_rl_realloc_nofail() argument
112 new_size = PAGE_ALIGN(new_size * sizeof(*rl)); in ntfs_rl_realloc_nofail()
113 if (old_size == new_size) in ntfs_rl_realloc_nofail()
116 new_rl = ntfs_malloc_nofs_nofail(new_size); in ntfs_rl_realloc_nofail()
[all …]
Dattrib.h88 extern int ntfs_attr_record_resize(MFT_RECORD *m, ATTR_RECORD *a, u32 new_size);
90 const u32 new_size);
Dinode.c2357 s64 new_size, old_size, nr_freed, new_alloc_size, old_alloc_size; in ntfs_truncate() local
2420 new_size = i_size_read(vi); in ntfs_truncate()
2425 new_alloc_size = (new_size + vol->cluster_size - 1) & in ntfs_truncate()
2428 new_alloc_size = (new_size + 7) & ~7; in ntfs_truncate()
2438 if (new_size - old_size >= 0) { in ntfs_truncate()
2440 if (new_size == old_size) in ntfs_truncate()
2458 err = ntfs_attr_size_bounds_check(vol, ni->type, new_size); in ntfs_truncate()
2466 new_size > old_size ? "exceed " in ntfs_truncate()
2495 if (new_size < vol->mft_record_size && in ntfs_truncate()
2496 !ntfs_resident_attr_value_resize(m, a, new_size)) { in ntfs_truncate()
[all …]
/fs/f2fs/
Dfile.c1211 size_t new_size; in __clone_blkaddrs() local
1244 new_size = (loff_t)(dst + i) << PAGE_SHIFT; in __clone_blkaddrs()
1245 if (dst_inode->i_size < new_size) in __clone_blkaddrs()
1246 f2fs_i_size_write(dst_inode, new_size); in __clone_blkaddrs()
1357 loff_t new_size; in f2fs_collapse_range() local
1385 new_size = i_size_read(inode) - len; in f2fs_collapse_range()
1386 truncate_pagecache(inode, new_size); in f2fs_collapse_range()
1388 ret = f2fs_truncate_blocks(inode, new_size, true); in f2fs_collapse_range()
1391 f2fs_i_size_write(inode, new_size); in f2fs_collapse_range()
1451 loff_t new_size = i_size_read(inode); in f2fs_zero_range() local
[all …]
/fs/gfs2/
Dlock_dlm.c1023 uint32_t old_size, new_size; in set_recover_size() local
1039 new_size = old_size; in set_recover_size()
1040 while (new_size < max_jid + 1) in set_recover_size()
1041 new_size += RECOVER_SIZE_INC; in set_recover_size()
1042 if (new_size == old_size) in set_recover_size()
1045 submit = kcalloc(new_size, sizeof(uint32_t), GFP_NOFS); in set_recover_size()
1046 result = kcalloc(new_size, sizeof(uint32_t), GFP_NOFS); in set_recover_size()
1060 ls->ls_recover_size = new_size; in set_recover_size()
/fs/nfsd/
Dblocklayout.c123 loff_t new_size = lcp->lc_last_wr + 1; in nfsd4_block_commit_blocks() local
133 if (new_size > i_size_read(inode)) { in nfsd4_block_commit_blocks()
135 iattr.ia_size = new_size; in nfsd4_block_commit_blocks()
/fs/btrfs/
Dfile-item.c568 u32 new_size = (bytenr - key->offset) >> blocksize_bits; in truncate_one_csum() local
569 new_size *= csum_size; in truncate_one_csum()
570 btrfs_truncate_item(path, new_size, 1); in truncate_one_csum()
579 u32 new_size = (csum_end - end_byte) >> blocksize_bits; in truncate_one_csum() local
580 new_size *= csum_size; in truncate_one_csum()
582 btrfs_truncate_item(path, new_size, 0); in truncate_one_csum()
/fs/ext4/
Dxattr.c1587 size_t old_size, new_size; in ext4_xattr_set_entry() local
1593 new_size = (i->value && !in_inode) ? EXT4_XATTR_SIZE(i->value_len) : 0; in ext4_xattr_set_entry()
1599 if (new_size && new_size == old_size) { in ext4_xattr_set_entry()
1605 memset(val, 0, new_size); in ext4_xattr_set_entry()
1609 memset(val + i->value_len, 0, new_size - i->value_len); in ext4_xattr_set_entry()
1638 if (free < EXT4_XATTR_LEN(name_len) + new_size) { in ext4_xattr_set_entry()
1650 new_size && is_block && in ext4_xattr_set_entry()
1651 (min_offs + old_size - new_size) < in ext4_xattr_set_entry()
1781 void *val = s->base + min_offs - new_size; in ext4_xattr_set_entry()
1783 here->e_value_offs = cpu_to_le16(min_offs - new_size); in ext4_xattr_set_entry()
[all …]
Dinline.c1098 static void ext4_update_final_de(void *de_buf, int old_size, int new_size) in ext4_update_final_de() argument
1114 prev_de->rec_len = ext4_rec_len_to_disk(de_len + new_size - in ext4_update_final_de()
1115 old_size, new_size); in ext4_update_final_de()
1119 de->rec_len = ext4_rec_len_to_disk(new_size, new_size); in ext4_update_final_de()
1128 int new_size = get_max_inline_xattr_value_size(dir, iloc); in ext4_update_inline_dir() local
1130 if (new_size - old_size <= ext4_dir_rec_len(1, NULL)) in ext4_update_inline_dir()
1134 new_size + EXT4_MIN_INLINE_DATA_SIZE); in ext4_update_inline_dir()
Dextents.c4654 ext4_lblk_t len, loff_t new_size, in ext4_alloc_file_blocks() argument
4714 if (new_size) { in ext4_alloc_file_blocks()
4715 if (epos > new_size) in ext4_alloc_file_blocks()
4716 epos = new_size; in ext4_alloc_file_blocks()
4745 loff_t new_size = 0; in ext4_zero_range() local
4800 new_size = offset + len; in ext4_zero_range()
4801 ret = inode_newsize_ok(inode, new_size); in ext4_zero_range()
4819 new_size, flags); in ext4_zero_range()
4851 ret = ext4_alloc_file_blocks(file, lblk, max_blocks, new_size, in ext4_zero_range()
4875 if (new_size) { in ext4_zero_range()
[all …]
/fs/ocfs2/
Djournal.h587 loff_t new_size) in ocfs2_begin_ordered_truncate() argument
592 new_size); in ocfs2_begin_ordered_truncate()
Daops.h48 int ocfs2_size_fits_inline_data(struct buffer_head *di_bh, u64 new_size);

12