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: <4b3f6af7-d40e-4910-8e6d-449c59ab0dd2@linux.intel.com>
Date: Wed, 24 Apr 2024 11:44:55 +0800
From: Baolu Lu <baolu.lu@...ux.intel.com>
To: Uros Bizjak <ubizjak@...il.com>, iommu@...ts.linux.dev,
 linux-kernel@...r.kernel.org
Cc: baolu.lu@...ux.intel.com, David Woodhouse <dwmw2@...radead.org>,
 Joerg Roedel <joro@...tes.org>, Will Deacon <will@...nel.org>,
 Robin Murphy <robin.murphy@....com>
Subject: Re: [PATCH] iommu/intel: Use try_cmpxchg64{,_local}() in iommu.c

On 4/15/24 12:23 AM, Uros Bizjak wrote:
> Replace this pattern in iommu.c:
> 
>      cmpxchg64{,_local}(*ptr, 0, new) != 0
> 
> .. with the simpler and faster:
> 
>      !try_cmpxchg64{,_local}(*ptr, &tmp, new)
> 
> The x86 CMPXCHG instruction returns success in the ZF flag, so this change
> saves a compare after the CMPXCHG.
> 
> No functional change intended.
> 
> Signed-off-by: Uros Bizjak<ubizjak@...il.com>
> Cc: David Woodhouse<dwmw2@...radead.org>
> Cc: Lu Baolu<baolu.lu@...ux.intel.com>
> Cc: Joerg Roedel<joro@...tes.org>
> Cc: Will Deacon<will@...nel.org>
> Cc: Robin Murphy<robin.murphy@....com>
> ---
>   drivers/iommu/intel/iommu.c | 9 +++++----
>   1 file changed, 5 insertions(+), 4 deletions(-)

Patch has been queued for iommu/vt-d.

Best regards,
baolu

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ