Commit 661fb4e6 authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'for-6.11/dm-changes' of...

Merge tag 'for-6.11/dm-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm

Pull device mapper updates from Mikulas Patocka:

 - Optimize processing of flush bios in the dm-linear and dm-stripe
   targets

 - Dm-io cleansups and refactoring

 - Remove unused 'struct thunk' in dm-cache

 - Handle minor device numbers > 255 in dm-init

 - Dm-verity refactoring & enabling platform keyring

 - Fix warning in dm-raid

 - Improve dm-crypt performance - split bios to smaller pieces, so that
   They could be processed concurrently

 - Stop using blk_limits_io_{min,opt}

 - Dm-vdo cleanup and refactoring

 - Remove max_write_zeroes_granularity and max_secure_erase_granularity

 - Dm-multipath cleanup & refactoring

 - Add dm-crypt and dm-integrity support for non-power-of-2 sector size

 - Fix reshape in dm-raid

 - Make dm_block_validator const

* tag 'for-6.11/dm-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm: (33 commits)
  dm vdo: fix a minor formatting issue in vdo.rst
  dm vdo int-map: fix kerneldoc formatting
  dm vdo repair: add missing kerneldoc fields
  dm: Constify struct dm_block_validator
  dm-integrity: introduce the Inline mode
  dm: introduce the target flag mempool_needs_integrity
  dm raid: fix stripes adding reshape size issues
  dm raid: move _get_reshape_sectors() as prerequisite to fixing reshape size issues
  dm-crypt: support for per-sector NVMe metadata
  dm mpath: don't call dm_get_device in multipath_message
  dm: factor out helper function from dm_get_device
  dm-verity: fix dm_is_verity_target() when dm-verity is builtin
  dm: Remove max_secure_erase_granularity
  dm: Remove max_write_zeroes_granularity
  dm vdo indexer: use swap() instead of open coding it
  dm vdo: remove unused struct 'uds_attribute'
  dm: stop using blk_limits_io_{min,opt}
  dm-crypt: limit the size of encryption requests
  dm verity: add support for signature verification with platform keyring
  dm-raid: Fix WARN_ON_ONCE check for sync_thread in raid_resume
  ...
parents afd81d91 7f1c4909
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -160,6 +160,17 @@ iv_large_sectors
   The <iv_offset> must be multiple of <sector_size> (in 512 bytes units)
   if this flag is specified.


Module parameters::
max_read_size
max_write_size
   Maximum size of read or write requests. When a request larger than this size
   is received, dm-crypt will split the request. The splitting improves
   concurrency (the split requests could be encrypted in parallel by multiple
   cores), but it also causes overhead. The user should tune these parameters to
   fit the actual workload.


Example scripts
===============
LUKS (Linux Unified Key Setup) is now the preferred way to set up disk
+1 −0
Original line number Diff line number Diff line
@@ -241,6 +241,7 @@ Messages
All vdo devices accept messages in the form:

::

        dmsetup message <target-name> 0 <message-name> <message-parameters>

The messages are:
+10 −0
Original line number Diff line number Diff line
@@ -540,6 +540,16 @@ config DM_VERITY_VERIFY_ROOTHASH_SIG_SECONDARY_KEYRING

	  If unsure, say N.

config DM_VERITY_VERIFY_ROOTHASH_SIG_PLATFORM_KEYRING
	bool "Verity data device root hash signature verification with platform keyring"
	default DM_VERITY_VERIFY_ROOTHASH_SIG_SECONDARY_KEYRING
	depends on DM_VERITY_VERIFY_ROOTHASH_SIG
	depends on INTEGRITY_PLATFORM_KEYRING
	help
	  Rely also on the platform keyring to verify dm-verity signatures.

	  If unsure, say N.

config DM_VERITY_FEC
	bool "Verity forward error correction support"
	depends on DM_VERITY
+3 −12
Original line number Diff line number Diff line
@@ -170,7 +170,7 @@ struct dm_cache_metadata {
 */
#define SUPERBLOCK_CSUM_XOR 9031977

static void sb_prepare_for_write(struct dm_block_validator *v,
static void sb_prepare_for_write(const struct dm_block_validator *v,
				 struct dm_block *b,
				 size_t sb_block_size)
{
@@ -195,7 +195,7 @@ static int check_metadata_version(struct cache_disk_superblock *disk_super)
	return 0;
}

static int sb_check(struct dm_block_validator *v,
static int sb_check(const struct dm_block_validator *v,
		    struct dm_block *b,
		    size_t sb_block_size)
{
@@ -228,7 +228,7 @@ static int sb_check(struct dm_block_validator *v,
	return check_metadata_version(disk_super);
}

static struct dm_block_validator sb_validator = {
static const struct dm_block_validator sb_validator = {
	.name = "superblock",
	.prepare_for_write = sb_prepare_for_write,
	.check = sb_check
@@ -1282,15 +1282,6 @@ int dm_cache_insert_mapping(struct dm_cache_metadata *cmd,
	return r;
}

struct thunk {
	load_mapping_fn fn;
	void *context;

	struct dm_cache_metadata *cmd;
	bool respect_dirty_flags;
	bool hints_valid;
};

static bool policy_unchanged(struct dm_cache_metadata *cmd,
			     struct dm_cache_policy *policy)
{
+2 −2
Original line number Diff line number Diff line
@@ -3416,8 +3416,8 @@ static void cache_io_hints(struct dm_target *ti, struct queue_limits *limits)
	 */
	if (io_opt_sectors < cache->sectors_per_block ||
	    do_div(io_opt_sectors, cache->sectors_per_block)) {
		blk_limits_io_min(limits, cache->sectors_per_block << SECTOR_SHIFT);
		blk_limits_io_opt(limits, cache->sectors_per_block << SECTOR_SHIFT);
		limits->io_min = cache->sectors_per_block << SECTOR_SHIFT;
		limits->io_opt = cache->sectors_per_block << SECTOR_SHIFT;
	}

	disable_passdown_if_not_supported(cache);
Loading