Re: [dm-devel] [PATCH v3 09/11] dm: support IO polling for bio-based dm device

2021-02-23 Thread JeffleXu
On 2/19/21 10:17 PM, Mikulas Patocka wrote: > > > On Mon, 8 Feb 2021, Jeffle Xu wrote: > >> diff --git a/drivers/md/dm.c b/drivers/md/dm.c >> index c2945c90745e..8423f1347bb8 100644 >> --- a/drivers/md/dm.c >> +++ b/drivers/md/dm.c >> @@ -1657,6 +1657,68 @@ static blk_qc_t

Re: [dm-devel] [PATCH v4 00/12] dm: support IO polling

2021-02-23 Thread JeffleXu
On 2/24/21 4:54 AM, Mike Snitzer wrote: > On Mon, Feb 22 2021 at 10:55pm -0500, > JeffleXu wrote: > >> >> >> On 2/20/21 7:06 PM, Jeffle Xu wrote: >>> [Changes since v3] >>> - newly add patch 7 and patch 11, as a new optimization improving >>> performance of multiple polling processes. Now

[dm-devel] [PATCH v2 1/3] libmultipath: cleanup code to strip wwid trailing spaces

2021-02-23 Thread Benjamin Marzinski
Signed-off-by: Benjamin Marzinski --- libmultipath/discovery.c | 11 --- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/libmultipath/discovery.c b/libmultipath/discovery.c index 9be94cd1..3a06f319 100644 --- a/libmultipath/discovery.c +++ b/libmultipath/discovery.c @@

[dm-devel] [PATCH v2 3/3] multipathd: add recheck_wwid option to verify the path wwid

2021-02-23 Thread Benjamin Marzinski
There are cases where the wwid of a path changes due to LUN remapping without triggering uevent for the changed path. Multipathd has no method for trying to catch these cases, and corruption has resulted because of it. In order to have a better chance at catching these cases, multipath now has a

[dm-devel] [PATCH v2 0/3] Handle remapped LUNs better

2021-02-23 Thread Benjamin Marzinski
This patchset adds a new config option, recheck_wwid, to help deal with devices getting remapped. It's based on Chongyun's patch. Unlike Chongyun's patch, it doesn't issue a remove uevent. I'm not actually sure what the purpose of the remove uevent was, since it doesn't cause the path to be

[dm-devel] [PATCH v2 2/3] libmultipath: cleanup uid_attribute checking code

2021-02-23 Thread Benjamin Marzinski
In get_uid(), if pp->getuid is NULL, multipath will check the pp->uid_attribute to get the wwid. If pp->uid_attribute is NULL, nothing will happen in that block of code, because both udev_available and has_uid_fallback() are false if pp->uid_attribute is NULL. So instead of multiple checks if

[dm-devel] [PATCH] kpartx: free loop device after listing partitions

2021-02-23 Thread Benjamin Marzinski
If "kpartx -l" is run on a file that doesn't already have a loop device associated with it, it will create a loop device to run the command. Starting with da59d15c6 ("Fix loopback file with kpartx -av"), it will not free the loop device when exitting. This is because it checks if the the file it

Re: [dm-devel] [PATCH v2] blk-settings: make sure that max_sectors is aligned on "logical_block_size" boundary

2021-02-23 Thread Jens Axboe
Applied, thanks. -- Jens Axboe -- dm-devel mailing list dm-devel@redhat.com https://listman.redhat.com/mailman/listinfo/dm-devel

Re: [dm-devel] [PATCH v3 0/2] IMA: Add test for dm-crypt measurement

2021-02-23 Thread Tushar Sugandhi
Hi Petr, On 2021-02-23 4:43 p.m., Mimi Zohar wrote: Hi Petr, On Tue, 2021-02-23 at 23:59 +0100, Petr Vorel wrote: Hi! I updated Tushar's patchset to speedup things. Thank you. :) Changes v2->v3 * rename function s/check_ima_ascii_log_for_policy/test_policy_measurement/ * move tst_res

Re: [dm-devel] [PATCH v3 0/2] IMA: Add test for dm-crypt measurement

2021-02-23 Thread Mimi Zohar
Hi Petr, On Tue, 2021-02-23 at 23:59 +0100, Petr Vorel wrote: > Hi! > > I updated Tushar's patchset to speedup things. > > Changes v2->v3 > * rename function s/check_ima_ascii_log_for_policy/test_policy_measurement/ > * move tst_res TPASS/TFAIL into test_policy_measurement() > * drop

Re: [dm-devel] [PATCH v2] blk-settings: make sure that max_sectors is aligned on "logical_block_size" boundary

2021-02-23 Thread Ming Lei
On Tue, Feb 23, 2021 at 11:28:27AM -0500, Mikulas Patocka wrote: > > > On Tue, 23 Feb 2021, Ming Lei wrote: > > > I'd suggest to add a helper(such as, blk_round_down_sectors()) to > > round_down each > > one. > > Yes - Here I'm sending the updated patch. > > > -- > > Ming > > From: Mikulas

[dm-devel] [PATCH v3 1/2] IMA: Generalize key measurement tests

2021-02-23 Thread Petr Vorel
From: Tushar Sugandhi Refactor check_keys_policy() and test1() implemented in ima_keys.sh to make it generic, and move the functionality to ima_setup.sh, to be used for measurements in other tests in the future. Suggested-by: Petr Vorel Reviewed-by: Petr Vorel Signed-off-by: Tushar Sugandhi

[dm-devel] [PATCH v3 0/2] IMA: Add test for dm-crypt measurement

2021-02-23 Thread Petr Vorel
Hi! I updated Tushar's patchset to speedup things. Changes v2->v3 * rename function s/check_ima_ascii_log_for_policy/test_policy_measurement/ * move tst_res TPASS/TFAIL into test_policy_measurement() * drop template=ima-buf (see Lakshmi's patch [1] and discussion about it, it will be removed

[dm-devel] [PATCH v3 2/2] IMA: Add test for dm-crypt measurement

2021-02-23 Thread Petr Vorel
From: Tushar Sugandhi New functionality is being added to IMA to measure data provided by kernel components. With this feature, IMA policy can be set to enable measuring data provided by device-mapper targets. Currently one such device-mapper target - dm-crypt, is being updated to use this

Re: [dm-devel] [PATCH v2 1/2] IMA: generalize key measurement tests

2021-02-23 Thread Petr Vorel
Hi Tushar, > Thanks for your review. > My sincere apologies for missing this email and not responding in time. > The device mapper measurement work is being revisited - to cover aspects > like more DM targets (not just dm-crypt), better memory management, > more relevant attributes from the DM

Re: [dm-devel] [PATCH v4 00/12] dm: support IO polling

2021-02-23 Thread Mike Snitzer
On Mon, Feb 22 2021 at 10:55pm -0500, JeffleXu wrote: > > > On 2/20/21 7:06 PM, Jeffle Xu wrote: > > [Changes since v3] > > - newly add patch 7 and patch 11, as a new optimization improving > > performance of multiple polling processes. Now performance of multiple > > polling processes can be

[dm-devel] [PATCH 2/2] dm-verity: Fix FEC for RS roots non-aligned to block size

2021-02-23 Thread Milan Broz
Optional Forward Error Correction (FEC) code in dm-verity uses Reed-Solomon code and should support roots from 2 to 24. The error correction parity bytes (of roots lengths per RS block) are stored on a separate device in sequence without any padding. Currently, to access FEC device, the

[dm-devel] [PATCH 1/2] dm-bufio: subtract the number of initial sectors in dm_bufio_get_device_size

2021-02-23 Thread Milan Broz
From: Mikulas Patocka dm_bufio_get_device_size returns returns the device size in blocks. Before returning the value, we must subtract the nubmer of starting sectors. The number of starting sectos may not be divisible by block size. Note that currently, no target is using

[dm-devel] [PATCH v2] blk-settings: make sure that max_sectors is aligned on "logical_block_size" boundary

2021-02-23 Thread Mikulas Patocka
On Tue, 23 Feb 2021, Ming Lei wrote: > I'd suggest to add a helper(such as, blk_round_down_sectors()) to round_down > each > one. Yes - Here I'm sending the updated patch. > -- > Ming From: Mikulas Patocka We get I/O errors when we run md-raid1 on the top of dm-integrity on the top of

[dm-devel] [PATCH] dm-bufio: subtract the number of initial sectors in dm_bufio_get_device_size

2021-02-23 Thread Mikulas Patocka
dm_bufio_get_device_size returns returns the device size in blocks. Before returning the value, we must subtract the nubmer of starting sectors. The number of starting sectos may not be divisible by block size. Note that currently, no target is using dm_bufio_set_sector_offset and

Re: [dm-devel] [PATCH] dm-verity: Fix FEC for RS roots non-aligned to block size

2021-02-23 Thread Milan Broz
On 23/02/2021 04:00, Jérôme Carretero wrote: > Tested-by: Jérôme Carretero > > > I smoke-tested by fuzzing contiguous ranges of user data (not hash > tree) and correction works up to the amount of added correction (since > erasures are identified by hashes). Thanks for testing! > Since the

Re: [dm-devel] [PATCH v4 00/12] dm: support IO polling

2021-02-23 Thread JeffleXu
On 2/20/21 7:06 PM, Jeffle Xu wrote: > [Changes since v3] > - newly add patch 7 and patch 11, as a new optimization improving > performance of multiple polling processes. Now performance of multiple > polling processes can be as scalable as single polling process (~30%). > Refer to the

Re: [dm-devel] [RFC PATCH v5 0/4] add simple copy support

2021-02-23 Thread Selva Jove
Dave, copy_file_range() is work under progress. FALLOC_FL_UNSHARE of fallocate() use case sounds interesting. I will try to address both of them in the next series. Adding SCSI_XCOPY() support is not in the scope of this patchset. However blkdev_issue_copy() interface is made generic so that it

Re: [dm-devel] [RFC PATCH v5 0/4] add simple copy support

2021-02-23 Thread Selva Jove
Thanks Su Yue. I'll update the link in the next series. On Mon, Feb 22, 2021 at 12:23 PM Su Yue wrote: > > > On Fri 19 Feb 2021 at 20:45, SelvaKumar S > wrote: > > > This patchset tries to add support for TP4065a ("Simple Copy > > Command"), > > v2020.05.04 ("Ratified") > > > > The