On Fri, Dec 09, 2016 at 09:56:45AM -0800, Darrick J. Wong wrote:
> Since a zero-length dedupe operation is guaranteed to succeed, use that
> to test whether or not this filesystem supports dedupe.
>
> Signed-off-by: Darrick J. Wong <darrick.wong@xxxxxxxxxx>
> ---
> file_scan.c | 47 +++++++++++++++++++++++++++++++++++++----------
> 1 file changed, 37 insertions(+), 10 deletions(-)
>
> diff --git a/file_scan.c b/file_scan.c
> index 617f166..a34453e 100644
> --- a/file_scan.c
> +++ b/file_scan.c
> @@ -45,11 +45,7 @@
> #include "file_scan.h"
> #include "dbfile.h"
> #include "util.h"
> -
> -/* This is not in linux/magic.h */
> -#ifndef XFS_SB_MAGIC
> -#define XFS_SB_MAGIC 0x58465342 /* 'XFSB' */
> -#endif
> +#include "btrfs-ioctl.h"
>
> static char path[PATH_MAX] = { 0, };
> static char *pathp = path;
> @@ -189,6 +185,39 @@ static int walk_dir(const char *name)
> return ret;
> }
>
> +struct fake_btrfs_ioctl_same_args {
> + struct btrfs_ioctl_same_args args;
> + struct btrfs_ioctl_same_extent_info info;
> +};
Why does this need a fake structure here?
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html