Re: [PATCH 5/5] um: Add 4 level page table support

2024-05-29 Thread Tiwei Bie
On 5/28/24 4:54 PM, benja...@sipsolutions.net wrote: [...] > diff --git a/arch/um/Kconfig b/arch/um/Kconfig > index 93a5a8999b07..5d111fc8ccb7 100644 > --- a/arch/um/Kconfig > +++ b/arch/um/Kconfig > @@ -208,6 +208,7 @@ config MMAPPER > > config PGTABLE_LEVELS > int > + default 4 if 4_

Re: [PATCH 3/5] um: Do a double clone to disable rseq

2024-05-29 Thread Tiwei Bie
On 5/28/24 10:13 PM, Tiwei Bie wrote: > On 5/28/24 7:57 PM, Johannes Berg wrote: >> On Tue, 2024-05-28 at 18:16 +0800, Tiwei Bie wrote: >>> On 5/28/24 4:54 PM, benja...@sipsolutions.net wrote: From: Benjamin Berg Newer glibc versions are enabling rseq support by default. This remain

Re: [PATCH 07/12] sd: factor out a sd_discard_mode helper

2024-05-29 Thread Bart Van Assche
On 5/28/24 22:04, Christoph Hellwig wrote: Split the logic to pick the right discard mode into a little helper to prepare for further changes. Reviewed-by: Bart Van Assche

[PATCH] arch: um: rust: Use the generated target.json again

2024-05-29 Thread David Gow
The Rust compiler can take a target config from 'target.json', which is generated by scripts/generate_rust_target.rs. It used to be that all Linux architectures used this to generate a target.json, but now architectures must opt-in to this, or they will default to the Rust compiler's built-in targe

Re: [PATCH 12/12] block: add special APIs for run-time disabling of discard and friends

2024-05-29 Thread Damien Le Moal
On 5/29/24 14:04, Christoph Hellwig wrote: > A few drivers optimistically try to support discard, write zeroes and > secure erase and disable the features from the I/O completion handler > if the hardware can't support them. This disable can't be done using > the atomic queue limits API because th

Re: [PATCH 11/12] block: remove unused queue limits API

2024-05-29 Thread Damien Le Moal
On 5/29/24 14:04, Christoph Hellwig wrote: > Remove all APIs that are unused now that sd and sr have been converted > to the atomic queue limits API. > > Signed-off-by: Christoph Hellwig I think that disk_set_max_open_zones() and disk_set_max_active_zones() can also go away. -- Damien Le Moal

Re: [PATCH 10/12] sr: convert to the atomic queue limits API

2024-05-29 Thread Damien Le Moal
On 5/29/24 14:04, Christoph Hellwig wrote: > Assign all queue limits through a local queue_limits variable and > queue_limits_commit_update so that we can't race updating them from > multiple places, and free the queue when updating them so that > in-progress I/O submissions don't see half-updated

Re: [PATCH 09/12] sd: convert to the atomic queue limits API

2024-05-29 Thread Damien Le Moal
On 5/29/24 14:04, Christoph Hellwig wrote: > Assign all queue limits through a local queue_limits variable and > queue_limits_commit_update so that we can't race updating them from > multiple places, and free the queue when updating them so that s/free/freeze > in-progress I/O submissions don't s

Re: [PATCH 08/12] sd: cleanup zoned queue limits initialization

2024-05-29 Thread Damien Le Moal
On 5/29/24 14:04, Christoph Hellwig wrote: > Consolidate setting zone-related queue limits in sd_zbc_read_zones > instead of splitting them between sd_zbc_revalidate_zones and > sd_zbc_read_zones, and move the early_zone_information initialization > in sd_zbc_read_zones above setting up the queue l

Re: [PATCH 07/12] sd: factor out a sd_discard_mode helper

2024-05-29 Thread Damien Le Moal
On 5/29/24 14:04, Christoph Hellwig wrote: > Split the logic to pick the right discard mode into a little helper > to prepare for further changes. > > Signed-off-by: Christoph Hellwig Looks good. Reviewed-by: Damien Le Moal -- Damien Le Moal Western Digital Research

Re: [PATCH 06/12] sd: simplify the disable case in sd_config_discard

2024-05-29 Thread Damien Le Moal
On 5/29/24 14:04, Christoph Hellwig wrote: > Fall through to the main call to blk_queue_max_discard_sectors given that > max_blocks has been initialized to zero above instead of duplicating the > call. > > Signed-off-by: Christoph Hellwig Looks good. Reviewed-by: Damien Le Moal -- Damien Le

Re: [PATCH 05/12] sd: add a sd_disable_write_same helper

2024-05-29 Thread Damien Le Moal
On 5/29/24 14:04, Christoph Hellwig wrote: > Add helper to disable WRITE SAME when it is not supported and use it > instead of sd_config_write_same in the I/O completion handler. This > avoids touching more fields than required in the I/O completion handler > and prepares for converting sd to use

Re: [PATCH 04/12] sd: add a sd_disable_discard helper

2024-05-29 Thread Damien Le Moal
On 5/29/24 14:04, Christoph Hellwig wrote: > Add helper to disable discard when it is not supported and use it > instead of sd_config_discard in the I/O completion handler. This avoids > touching more fields than required in the I/O completion handler and > prepares for converting sd to use the at

Re: [PATCH 03/12] sd: simplify the ZBC case in provisioning_mode_store

2024-05-29 Thread Damien Le Moal
On 5/29/24 14:04, Christoph Hellwig wrote: > Don't reset the discard settings to no-op over and over when a user > writes to the provisioning attribute as that is already the default > mode for ZBC devices. In hindsight we should have made writing to > the attribute fail for ZBC devices, but the c

Re: [PATCH 02/12] block: take io_opt and io_min into account for max_sectors

2024-05-29 Thread Damien Le Moal
On 5/29/24 14:04, Christoph Hellwig wrote: > The soft max_sectors limit is normally capped by the hardware limits and > an arbitrary upper limit enforced by the kernel, but can be modified by > the user. A few drivers want to increase this limit (nbd, rbd) or > adjust it up or down based on hardwa

Re: [PATCH 01/12] ubd: untagle discard vs write zeroes not support handling

2024-05-29 Thread Damien Le Moal
On 5/29/24 14:04, Christoph Hellwig wrote: > Discard and Write Zeroes are different operation and implemented > by different fallocate opcodes for ubd. If one fails the other one > can work and vice versa. > > Split the code to disable the operations in ubd_handler to only > disable the operation