Signed-off-by: Andrew Mahone <andrew.mahone@xxxxxxxxx>
---
fs/btrfs/compression.c | 2 ++
fs/btrfs/compression.h | 2 ++
fs/btrfs/super.c | 6 ------
3 files changed, 4 insertions(+), 6 deletions(-)
diff --git a/fs/btrfs/compression.c b/fs/btrfs/compression.c
index 86eff48..3ed7251 100644
--- a/fs/btrfs/compression.c
+++ b/fs/btrfs/compression.c
@@ -733,6 +733,8 @@ static wait_queue_head_t comp_workspace_wait[BTRFS_COMPRESS_TYPES];
struct btrfs_compress_op *btrfs_compress_op[] = {
&btrfs_zlib_compress,
&btrfs_lzo_compress,
+ &btrfs_lz4_compress,
+ &btrfs_lz4hc_compress,
};
void __init btrfs_init_compress(void)
diff --git a/fs/btrfs/compression.h b/fs/btrfs/compression.h
index 9afb0a6..2a43913 100644
--- a/fs/btrfs/compression.h
+++ b/fs/btrfs/compression.h
@@ -79,5 +79,7 @@ struct btrfs_compress_op {
extern struct btrfs_compress_op btrfs_zlib_compress;
extern struct btrfs_compress_op btrfs_lzo_compress;
+extern struct btrfs_compress_op btrfs_lz4_compress;
+extern struct btrfs_compress_op btrfs_lz4hc_compress;
#endif
diff --git a/fs/btrfs/super.c b/fs/btrfs/super.c
index 5824886..af6f429 100644
--- a/fs/btrfs/super.c
+++ b/fs/btrfs/super.c
@@ -405,16 +405,10 @@ int btrfs_parse_options(struct btrfs_root *root, char *options)
compress_type = "lz4";
info->compress_type = BTRFS_COMPRESS_LZ4;
btrfs_set_opt(info->mount_opt, COMPRESS);
- /* remove when implemented */
- ret = -EINVAL;
- goto out;
} else if (strcmp(args[0].from, "lz4hc") == 0) {
compress_type = "lz4hc";
info->compress_type = BTRFS_COMPRESS_LZ4HC;
btrfs_set_opt(info->mount_opt, COMPRESS);
- /* remove when implemented */
- ret = -EINVAL;
- goto out;
} else if (strncmp(args[0].from, "no", 2) == 0) {
compress_type = "no";
info->compress_type = BTRFS_COMPRESS_NONE;
--
1.7.11
--
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