aboutsummaryrefslogtreecommitdiff
path: root/lib/ucs2_string.c
diff options
context:
space:
mode:
authorUros Bizjak <[email protected]>2024-05-22 10:26:47 +0200
committerJoerg Roedel <[email protected]>2024-06-25 14:20:41 +0200
commit9a448e453151ec4e4b98a914b463539e790dd198 (patch)
tree6b5a4f4360f0613d299b2a8c9f49371e6a6c0188 /lib/ucs2_string.c
parent83a7eefedc9b56fe7bfeff13b6c7356688ffa670 (diff)
iommu/amd: Use try_cmpxchg64() in v2_alloc_pte()
Use try_cmpxchg64() instead of cmpxchg64 (*ptr, old, new) != old in v2_alloc_pte(). cmpxchg returns success in ZF flag, so this change saves a compare after cmpxchg (and related move instruction in front of cmpxchg). This is the same improvement as implemented for alloc_pte() in: commit 0d10fe759117 ("iommu/amd: Use try_cmpxchg64 in alloc_pte and free_clear_pte") Signed-off-by: Uros Bizjak <[email protected]> Cc: Joerg Roedel <[email protected]> Cc: Suravee Suthikulpanit <[email protected]> Cc: Will Deacon <[email protected]> Cc: Robin Murphy <[email protected]> Reviewed-by: Vasant Hegde <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Joerg Roedel <[email protected]>
Diffstat (limited to 'lib/ucs2_string.c')
0 files changed, 0 insertions, 0 deletions