- Fix DM verity target's 'require_signatures' module_param permissions.

- Revert DM snapshot fix from v5.13-rc3 and then properly fix crash
  when an origin has no snapshots. This allows only the proper fix to
  go to stable@ (since the original fix was successfully dropped).
dm snapshot: properly fix a crash when an origin has no snapshots

If an origin target has no snapshots, o->split_boundary is set to 0.
This causes BUG_ON(sectors <= 0) in block/bio.c:bio_split().

Fix this by initializing chunk_size, and in turn split_boundary, to
rounddown_pow_of_two(UINT_MAX) -- the largest power of two that fits
into "unsigned" type.

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Cc: stable@vger.kernel.org
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
1 file changed