diff options
Diffstat (limited to 'target/linux/generic/pending-4.19/551-ubifs-fix-default-compression-selection.patch')
-rw-r--r-- | target/linux/generic/pending-4.19/551-ubifs-fix-default-compression-selection.patch | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/target/linux/generic/pending-4.19/551-ubifs-fix-default-compression-selection.patch b/target/linux/generic/pending-4.19/551-ubifs-fix-default-compression-selection.patch index 4782fc9ed8..60d5619989 100644 --- a/target/linux/generic/pending-4.19/551-ubifs-fix-default-compression-selection.patch +++ b/target/linux/generic/pending-4.19/551-ubifs-fix-default-compression-selection.patch @@ -12,12 +12,12 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org> /* Default time granularity in nanoseconds */ #define DEFAULT_TIME_GRAN 1000000000 -+static int get_default_compressor(void) ++static int get_default_compressor(struct ubifs_info *c) +{ -+ if (ubifs_compr_present(UBIFS_COMPR_LZO)) ++ if (ubifs_compr_present(c, UBIFS_COMPR_LZO)) + return UBIFS_COMPR_LZO; + -+ if (ubifs_compr_present(UBIFS_COMPR_ZLIB)) ++ if (ubifs_compr_present(c, UBIFS_COMPR_ZLIB)) + return UBIFS_COMPR_ZLIB; + + return UBIFS_COMPR_NONE; @@ -31,7 +31,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org> sup->default_compr = cpu_to_le16(c->mount_opts.compr_type); else - sup->default_compr = cpu_to_le16(UBIFS_COMPR_LZO); -+ sup->default_compr = cpu_to_le16(get_default_compressor()); ++ sup->default_compr = cpu_to_le16(get_default_compressor(c)); generate_random_uuid(sup->uuid); |