Re: [PATCH v5 0/5] DMA mapping changes for SCSI core

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 7/9/22 01:17, John Garry wrote:
> On 07/07/2022 21:35, Martin K. Petersen wrote:
>> Christoph,
>>
>>> Yes, I've mostly been waiting for an ACK from Martin.
>> Sorry, I'm on vacation this week. The series looks OK to me although I
>> do agree that it would be great if the max was reflected in the queue's
>> hard limit and opt in the soft limit.
> 
> Ah, I think that I misunderstood Damien's question. I thought he was 
> asking why not keep shost max_sectors at dma_max_mapping_size() and then 
> init each sdev request queue max hw sectors at dma_opt_mapping_size().

I was suggesting the reverse :) Keep the device hard limit
(max_hw_sectors) to the max dma mapping and set the soft limit
(max_sectors) to the optimal dma mapping size.

> 
> But he seems that you want to know why not have the request queue max 
> sectors at dma_opt_mapping_size(). The answer is related to meaning of 
> dma_opt_mapping_size(). If we get any mappings which exceed this size 
> then it can have a big dma mapping performance hit. So I set max hw 
> sectors at this ‘opt’ mapping size to ensure that we get no mappings 
> which exceed this size. Indeed, I think max sectors is 128Kb today for 
> my host, which would be same as dma_opt_mapping_size() value with an 
> IOMMU enabled. And I find that only a small % of request size may exceed 
> this 128kb size, but it still has a big performance impact.
> 
>>
>> Acked-by: Martin K. Petersen<martin.petersen@xxxxxxxxxx>
> 
> Thanks,
> John


-- 
Damien Le Moal
Western Digital Research




[Index of Archives]     [Linux Filesystems]     [Linux SCSI]     [Linux RAID]     [Git]     [Kernel Newbies]     [Linux Newbie]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Samba]     [Device Mapper]

  Powered by Linux