Lines Matching refs:fi_args
3675 struct btrfs_ioctl_fs_info_args *fi_args; in btrfs_ioctl_fs_info() local
3681 fi_args = memdup_user(arg, sizeof(*fi_args)); in btrfs_ioctl_fs_info()
3682 if (IS_ERR(fi_args)) in btrfs_ioctl_fs_info()
3683 return PTR_ERR(fi_args); in btrfs_ioctl_fs_info()
3685 flags_in = fi_args->flags; in btrfs_ioctl_fs_info()
3686 memset(fi_args, 0, sizeof(*fi_args)); in btrfs_ioctl_fs_info()
3689 fi_args->num_devices = fs_devices->num_devices; in btrfs_ioctl_fs_info()
3692 if (device->devid > fi_args->max_id) in btrfs_ioctl_fs_info()
3693 fi_args->max_id = device->devid; in btrfs_ioctl_fs_info()
3697 memcpy(&fi_args->fsid, fs_devices->fsid, sizeof(fi_args->fsid)); in btrfs_ioctl_fs_info()
3698 fi_args->nodesize = fs_info->nodesize; in btrfs_ioctl_fs_info()
3699 fi_args->sectorsize = fs_info->sectorsize; in btrfs_ioctl_fs_info()
3700 fi_args->clone_alignment = fs_info->sectorsize; in btrfs_ioctl_fs_info()
3703 fi_args->csum_type = btrfs_super_csum_type(fs_info->super_copy); in btrfs_ioctl_fs_info()
3704 fi_args->csum_size = btrfs_super_csum_size(fs_info->super_copy); in btrfs_ioctl_fs_info()
3705 fi_args->flags |= BTRFS_FS_INFO_FLAG_CSUM_INFO; in btrfs_ioctl_fs_info()
3709 fi_args->generation = fs_info->generation; in btrfs_ioctl_fs_info()
3710 fi_args->flags |= BTRFS_FS_INFO_FLAG_GENERATION; in btrfs_ioctl_fs_info()
3714 memcpy(&fi_args->metadata_uuid, fs_devices->metadata_uuid, in btrfs_ioctl_fs_info()
3715 sizeof(fi_args->metadata_uuid)); in btrfs_ioctl_fs_info()
3716 fi_args->flags |= BTRFS_FS_INFO_FLAG_METADATA_UUID; in btrfs_ioctl_fs_info()
3719 if (copy_to_user(arg, fi_args, sizeof(*fi_args))) in btrfs_ioctl_fs_info()
3722 kfree(fi_args); in btrfs_ioctl_fs_info()