lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <2c2428e9-230a-91f2-84bb-01804ce10c04@huawei.com>
Date:   Fri, 21 Jul 2023 09:52:21 +0800
From:   "zhangzekun (A)" <zhangzekun11@...wei.com>
To:     <robin.murphy@....com>, <joro@...tes.org>, <will@...nel.org>,
        <iommu@...ts.linux.dev>, <linux-kernel@...r.kernel.org>
CC:     <guohanjun@...wei.com>, <xuqiang36@...wei.com>,
        <chenweilong@...wei.com>, <thunder.leizhen@...wei.com>
Subject: Re: [PATCH -next 0/2] iommu/iova: optimize the iova rcache

Hi all, does anyone has suggestions for these two patches?

在 2023/7/11 10:54, Zhang Zekun 写道:
> The struct of iova rcache has diffcult in dealing with machine with
> lots of cpus, because every cpu has a cpu_rcache and they need to
> exchange iova in a fixed length buffer rcache->depot, this buffer
> can sometimes become a bottle neck of allocating iova from iova_rcache.
> The number of iova_cpu_rcache can grow with the number of cpus in
> iova_rcache, but the size of rcache->depot will not. The deeper of
> rcache->depot can help iova_rcache cache more iovas, and can help
> iova_rcache better dealing with senarios in which drivers allocating
> and free iovas on different cpu cores. We only let the size of rcache->depot
> to grow with the number of cpus which is larger than 32 to avoid potential
> performance decrease on machines which don't have much cpus.
>
> Also, it is unsafe to directly free cpu rcache magazines in free_iova_rcaches,
> add check before freeing it.
>
> Zhang Zekun (2):
>    iommu/iova: Add check for cpu_rcache in free_iova_rcaches
>    iommu/iova: allocate iova_rcache->depot dynamicly
>
>   drivers/iommu/iova.c | 36 +++++++++++++++++++++++++++++++-----
>   1 file changed, 31 insertions(+), 5 deletions(-)
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ