"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "fs/btrfs/qgroup.c" between
linux-3.16.62.tar.xz and linux-3.16.63.tar.xz

About: The full source of the Linux kernel 3.16.x (longterm stable)

qgroup.c  (linux-3.16.62.tar.xz):qgroup.c  (linux-3.16.63.tar.xz)
skipping to change at line 2025 skipping to change at line 2025
* copy the acounting information between qgroups. This is necessary when a * copy the acounting information between qgroups. This is necessary when a
* snapshot or a subvolume is created * snapshot or a subvolume is created
*/ */
int btrfs_qgroup_inherit(struct btrfs_trans_handle *trans, int btrfs_qgroup_inherit(struct btrfs_trans_handle *trans,
struct btrfs_fs_info *fs_info, u64 srcid, u64 objectid, struct btrfs_fs_info *fs_info, u64 srcid, u64 objectid,
struct btrfs_qgroup_inherit *inherit) struct btrfs_qgroup_inherit *inherit)
{ {
int ret = 0; int ret = 0;
int i; int i;
u64 *i_qgroups; u64 *i_qgroups;
struct btrfs_root *quota_root = fs_info->quota_root; struct btrfs_root *quota_root;
struct btrfs_qgroup *srcgroup; struct btrfs_qgroup *srcgroup;
struct btrfs_qgroup *dstgroup; struct btrfs_qgroup *dstgroup;
u32 level_size = 0; u32 level_size = 0;
u64 nums; u64 nums;
mutex_lock(&fs_info->qgroup_ioctl_lock); mutex_lock(&fs_info->qgroup_ioctl_lock);
if (!fs_info->quota_enabled) if (!fs_info->quota_enabled)
goto out; goto out;
quota_root = fs_info->quota_root;
if (!quota_root) { if (!quota_root) {
ret = -EINVAL; ret = -EINVAL;
goto out; goto out;
} }
if (inherit) { if (inherit) {
i_qgroups = (u64 *)(inherit + 1); i_qgroups = (u64 *)(inherit + 1);
nums = inherit->num_qgroups + 2 * inherit->num_ref_copies + nums = inherit->num_qgroups + 2 * inherit->num_ref_copies +
2 * inherit->num_excl_copies; 2 * inherit->num_excl_copies;
for (i = 0; i < nums; ++i) { for (i = 0; i < nums; ++i) {
 End of changes. 2 change blocks. 
1 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)