]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: prepare for extensions in compression options
authorDavid Sterba <dsterba@suse.com>
Mon, 17 Jul 2017 16:11:10 +0000 (18:11 +0200)
committerDavid Sterba <dsterba@suse.com>
Wed, 16 Aug 2017 14:12:05 +0000 (16:12 +0200)
commit01ba86175c2e654f9b0f960c922f1b4080c937eb
tree93e9b46b4ceedcf6ebab977408e57a35e4901f5f
parent837da405439335d88ed379c8f7dbc80968945781
btrfs: prepare for extensions in compression options

This is a minimal patch intended to be backported to older kernels.
We're going to extend the string specifying the compression method and
this would fail on kernels before that change (the string is compared
exactly).

Relax the string matching only to the prefix, ie. ignoring anything that
goes after "zlib" or "lzo", regardless of th format extension we decide
to use. This applies to the mount options and properties.

That way, patched old kernels could be booted on systems already
utilizing the new compression spec.

Applicable since commit de534d81018f0, v3.14.

Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/props.c
fs/btrfs/super.c