diff options
author | Heiko Carstens <hca@linux.ibm.com> | 2024-11-25 14:54:30 +0300 |
---|---|---|
committer | Heiko Carstens <hca@linux.ibm.com> | 2024-11-27 14:55:15 +0300 |
commit | 7726b55b5d6c22dc0e66570597bf6e43d410d093 (patch) | |
tree | bd6e91b4775b1cb8da0912a85e38c0b76e1b6ee1 /drivers/s390 | |
parent | ff123eb7741638d55abf82fac090bb3a543c1e74 (diff) | |
download | linux-7726b55b5d6c22dc0e66570597bf6e43d410d093.tar.xz |
s390/ap: Replace xchg() with WRITE_ONCE()
The result of xchg() is not used, and in addition it is used on a one byte
memory area which leads to inefficient code.
Use WRITE_ONCE() instead to achieve the same result with much less
generated code.
Acked-by: Harald Freudenberger <freude@linux.ibm.com>
Acked-by: Alexander Gordeev <agordeev@linux.ibm.com>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
Diffstat (limited to 'drivers/s390')
-rw-r--r-- | drivers/s390/crypto/ap_bus.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/s390/crypto/ap_bus.c b/drivers/s390/crypto/ap_bus.c index e14638936de6..26e1ea1940ec 100644 --- a/drivers/s390/crypto/ap_bus.c +++ b/drivers/s390/crypto/ap_bus.c @@ -453,7 +453,7 @@ static void ap_tasklet_fn(unsigned long dummy) * important that no requests on any AP get lost. */ if (ap_irq_flag) - xchg(ap_airq.lsi_ptr, 0); + WRITE_ONCE(*ap_airq.lsi_ptr, 0); spin_lock_bh(&ap_queues_lock); hash_for_each(ap_queues, bkt, aq, hnode) { |