]> 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)
commitabc044f97ce469ec22c5a0c0006fa0e6dd27b42d
tree93e9b46b4ceedcf6ebab977408e57a35e4901f5f
parentfef0c3735daff8de0a4fe14b3fc0f83d91b5a074
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 c795442c2de25, v3.14.

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