summaryrefslogtreecommitdiff
path: root/fs/ubifs/super.c
diff options
context:
space:
mode:
authorMichele Dionisio <michele.dionisio@gmail.com>2019-05-15 23:02:02 +0200
committerRichard Weinberger <richard@nod.at>2019-07-08 19:43:53 +0200
commiteeabb9866e4ccce55d875cad140f9bf7c7ba1d66 (patch)
tree2cb31e7a2c643f8b03a9abadb27e6fef3509c485 /fs/ubifs/super.c
parent817aa094842dfc3a6b98c9582d4a647827f66201 (diff)
ubifs: Add support for zstd compression.
zstd shows a good compression rate and is faster than lzo, also on slow ARM cores. Cc: Sebastian Andrzej Siewior <sebastian@breakpoint.cc> Signed-off-by: Michele Dionisio <michele.dionisio@gmail.com> [rw: rewrote commit message] Signed-off-by: Richard Weinberger <richard@nod.at>
Diffstat (limited to 'fs/ubifs/super.c')
-rw-r--r--fs/ubifs/super.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/ubifs/super.c b/fs/ubifs/super.c
index 13b8f68f6c24..5c472cca3876 100644
--- a/fs/ubifs/super.c
+++ b/fs/ubifs/super.c
@@ -1045,6 +1045,8 @@ static int ubifs_parse_options(struct ubifs_info *c, char *options,
c->mount_opts.compr_type = UBIFS_COMPR_LZO;
else if (!strcmp(name, "zlib"))
c->mount_opts.compr_type = UBIFS_COMPR_ZLIB;
+ else if (!strcmp(name, "zstd"))
+ c->mount_opts.compr_type = UBIFS_COMPR_ZSTD;
else {
ubifs_err(c, "unknown compressor \"%s\"", name); //FIXME: is c ready?
kfree(name);