Re: [PATCH 06/15] nvme: remove the hack to not update the discard limits in nvme_config_discard

2024-01-23 Thread Hannes Reinecke
On 1/22/24 18:36, Christoph Hellwig wrote: Now that the block layer tracks a separate user max discard limit, there is no need to prevent nvme from updating it on controller capability changes. Signed-off-by: Christoph Hellwig --- drivers/nvme/host/core.c | 10 -- 1 file changed, 10

Re: [PATCH 06/15] nvme: remove the hack to not update the discard limits in nvme_config_discard

2024-01-23 Thread Christoph Hellwig
On Tue, Jan 23, 2024 at 02:12:37PM +0900, Damien Le Moal wrote: > > blk_queue_max_discard_sectors(queue, max_discard_sectors); > > This function references max_user_discard_sectors but that access is done > without holding the queue limits mutex. Is that safe ? No. But fixing nvme will be do

Re: [PATCH 06/15] nvme: remove the hack to not update the discard limits in nvme_config_discard

2024-01-22 Thread Damien Le Moal
On 1/23/24 02:36, Christoph Hellwig wrote: > Now that the block layer tracks a separate user max discard limit, there > is no need to prevent nvme from updating it on controller capability > changes. > > Signed-off-by: Christoph Hellwig > --- > drivers/nvme/host/core.c | 10 -- > 1 file

[PATCH 06/15] nvme: remove the hack to not update the discard limits in nvme_config_discard

2024-01-22 Thread Christoph Hellwig
Now that the block layer tracks a separate user max discard limit, there is no need to prevent nvme from updating it on controller capability changes. Signed-off-by: Christoph Hellwig --- drivers/nvme/host/core.c | 10 -- 1 file changed, 10 deletions(-) diff --git a/drivers/nvme/host/co