Lines Matching refs:btrfs_test_dir_fd
72 static int btrfs_test_dir_fd; variable
507 btrfs_test_dir_fd, ioc(BTRFS_IOC_SUBVOL_CREATE_V2)); in btrfs_test_subvol_ioctls()
509 ret = ioctl(btrfs_test_dir_fd, BTRFS_IOC_SUBVOL_CREATE_V2, in btrfs_test_subvol_ioctls()
517 subvolfd = openat(btrfs_test_dir_fd, subvol_name, in btrfs_test_subvol_ioctls()
526 btrfs_test_dir_fd, ioc(BTRFS_IOC_SNAP_CREATE_V2)); in btrfs_test_subvol_ioctls()
528 ioctl(btrfs_test_dir_fd, BTRFS_IOC_SNAP_CREATE_V2, in btrfs_test_subvol_ioctls()
536 ioctl(btrfs_test_dir_fd, BTRFS_IOC_SNAP_DESTROY, &vol_args); in btrfs_test_subvol_ioctls()
538 btrfs_test_dir_fd, ioc(BTRFS_IOC_SNAP_DESTROY), in btrfs_test_subvol_ioctls()
542 ioctl(btrfs_test_dir_fd, BTRFS_IOC_SNAP_DESTROY, &vol_args); in btrfs_test_subvol_ioctls()
544 btrfs_test_dir_fd, ioc(BTRFS_IOC_SNAP_DESTROY), in btrfs_test_subvol_ioctls()
661 btrfs_test_dir_fd, ioc(BTRFS_IOC_BALANCE_V2)); in btrfs_test_balance_ioctls()
671 ret = ioctl(btrfs_test_dir_fd, BTRFS_IOC_BALANCE_V2, &args); in btrfs_test_balance_ioctls()
1054 btrfs_test_dir_fd, ioc(BTRFS_IOC_TREE_SEARCH)); in btrfs_test_search_ioctls()
1056 ioctl(btrfs_test_dir_fd, BTRFS_IOC_TREE_SEARCH, &search_args); in btrfs_test_search_ioctls()
1070 btrfs_test_dir_fd, ioc(BTRFS_IOC_TREE_SEARCH_V2)); in btrfs_test_search_ioctls()
1073 ioctl(btrfs_test_dir_fd, BTRFS_IOC_TREE_SEARCH_V2, args); in btrfs_test_search_ioctls()
1083 btrfs_test_dir_fd, ioc(BTRFS_IOC_TREE_SEARCH_V2)); in btrfs_test_search_ioctls()
1086 ioctl(btrfs_test_dir_fd, BTRFS_IOC_TREE_SEARCH_V2, args); in btrfs_test_search_ioctls()
1118 btrfs_test_dir_fd, ioc(BTRFS_IOC_INO_LOOKUP)); in btrfs_test_ino_lookup_ioctl()
1122 ioctl(btrfs_test_dir_fd, BTRFS_IOC_INO_LOOKUP, &args); in btrfs_test_ino_lookup_ioctl()
1149 btrfs_test_dir_fd, ioc(BTRFS_IOC_SPACE_INFO), in btrfs_test_space_info_ioctl()
1151 ioctl(btrfs_test_dir_fd, BTRFS_IOC_SPACE_INFO, &args_passed); in btrfs_test_space_info_ioctl()
1163 btrfs_test_dir_fd, ioc(BTRFS_IOC_SPACE_INFO), in btrfs_test_space_info_ioctl()
1165 ioctl(btrfs_test_dir_fd, BTRFS_IOC_SPACE_INFO, argsp); in btrfs_test_space_info_ioctl()
1355 ret = fstat(btrfs_test_dir_fd, &si); in btrfs_test_ino_path_ioctls()
1362 btrfs_test_dir_fd, ioc(BTRFS_IOC_INO_PATHS), in btrfs_test_ino_path_ioctls()
1364 ioctl(btrfs_test_dir_fd, BTRFS_IOC_INO_PATHS, &args); in btrfs_test_ino_path_ioctls()
1374 fd = openat(btrfs_test_dir_fd, "file1", O_RDWR|O_CREAT, 0600); in btrfs_test_ino_path_ioctls()
1680 ioctl(btrfs_test_dir_fd, FS_IOC_SETFSLABEL, label); in btrfs_test_label_ioctls()
1682 btrfs_test_dir_fd, ioc(FS_IOC_SETFSLABEL), label); in btrfs_test_label_ioctls()
1684 ioctl(btrfs_test_dir_fd, FS_IOC_GETFSLABEL, label); in btrfs_test_label_ioctls()
1686 btrfs_test_dir_fd, ioc(FS_IOC_GETFSLABEL), label); in btrfs_test_label_ioctls()
1720 btrfs_test_dir_fd, ioc(BTRFS_IOC_GET_DEV_STATS), in btrfs_test_get_dev_stats_ioctl()
1724 ioctl(btrfs_test_dir_fd, BTRFS_IOC_GET_DEV_STATS, &args); in btrfs_test_get_dev_stats_ioctl()
1872 fd1 = openat(btrfs_test_dir_fd, "file1", O_RDWR|O_CREAT, 0600); in btrfs_test_extent_same_ioctl()
1876 fd2 = openat(btrfs_test_dir_fd, "file2", O_RDWR|O_CREAT, 0600); in btrfs_test_extent_same_ioctl()
1890 fd2 = openat(btrfs_test_dir_fd, "file2", O_RDONLY); in btrfs_test_extent_same_ioctl()
1945 unlinkat(btrfs_test_dir_fd, "file1", 0); in btrfs_test_extent_same_ioctl()
1946 unlinkat(btrfs_test_dir_fd, "file2", 0); in btrfs_test_extent_same_ioctl()
2008 btrfs_test_dir_fd, ioc(BTRFS_IOC_GET_FEATURES)); in btrfs_test_features_ioctls()
2009 ioctl(btrfs_test_dir_fd, BTRFS_IOC_GET_FEATURES, in btrfs_test_features_ioctls()
2014 ioctl(btrfs_test_dir_fd, BTRFS_IOC_GET_SUPPORTED_FEATURES, in btrfs_test_features_ioctls()
2017 btrfs_test_dir_fd, in btrfs_test_features_ioctls()
2121 btrfs_test_dir_fd = openat(rootfd, dir_name, in main()
2123 if (btrfs_test_dir_fd < 0) in main()