diff options
author | Dawid Niedzwiecki <dn@semihalf.com> | 2020-10-28 10:02:32 +0100 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2020-11-02 10:17:27 +0000 |
commit | 71069893536962157b3b25330851a1c2c7cd6da5 (patch) | |
tree | 22c6f60ff900b68871f81e44cfe01b7616561bb6 /driver/ppc | |
parent | 0438542f2690e958d47dd28636797acbd29fcd9d (diff) | |
download | chrome-ec-71069893536962157b3b25330851a1c2c7cd6da5.tar.gz |
atomic: rename atomic_read_clear to atomic_clear
Rename atomic_read_clear to atomic_clear to be consistent with the rest
of the atomic functions, which return the previous value of the
variable.
BUG=b:169151160
BRANCH=none
TEST=buildall
Signed-off-by: Dawid Niedzwiecki <dn@semihalf.com>
Change-Id: I2588971bd7687879a28ec637cf5f6c3d27d393f4
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2505143
Reviewed-by: Tom Hughes <tomhughes@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Diffstat (limited to 'driver/ppc')
-rw-r--r-- | driver/ppc/aoz1380.c | 2 | ||||
-rw-r--r-- | driver/ppc/nx20p348x.c | 2 | ||||
-rw-r--r-- | driver/ppc/sn5s330.c | 2 | ||||
-rw-r--r-- | driver/ppc/syv682x.c | 2 |
4 files changed, 4 insertions, 4 deletions
diff --git a/driver/ppc/aoz1380.c b/driver/ppc/aoz1380.c index 4936647f37..98605fe08b 100644 --- a/driver/ppc/aoz1380.c +++ b/driver/ppc/aoz1380.c @@ -143,7 +143,7 @@ static void aoz1380_handle_interrupt(int port) static void aoz1380_irq_deferred(void) { int i; - uint32_t pending = atomic_read_clear(&irq_pending); + uint32_t pending = atomic_clear(&irq_pending); for (i = 0; i < board_get_usb_pd_port_count(); i++) if (BIT(i) & pending) diff --git a/driver/ppc/nx20p348x.c b/driver/ppc/nx20p348x.c index 8142681bb4..40a7bb792a 100644 --- a/driver/ppc/nx20p348x.c +++ b/driver/ppc/nx20p348x.c @@ -384,7 +384,7 @@ static void nx20p348x_handle_interrupt(int port) static void nx20p348x_irq_deferred(void) { int i; - uint32_t pending = atomic_read_clear(&irq_pending); + uint32_t pending = atomic_clear(&irq_pending); for (i = 0; i < board_get_usb_pd_port_count(); i++) if (BIT(i) & pending) diff --git a/driver/ppc/sn5s330.c b/driver/ppc/sn5s330.c index f177efa10c..4d9a25d43b 100644 --- a/driver/ppc/sn5s330.c +++ b/driver/ppc/sn5s330.c @@ -712,7 +712,7 @@ static void sn5s330_handle_interrupt(int port) static void sn5s330_irq_deferred(void) { int i; - uint32_t pending = atomic_read_clear(&irq_pending); + uint32_t pending = atomic_clear(&irq_pending); for (i = 0; i < board_get_usb_pd_port_count(); i++) if (BIT(i) & pending) diff --git a/driver/ppc/syv682x.c b/driver/ppc/syv682x.c index aac9191999..bd20ecc1f1 100644 --- a/driver/ppc/syv682x.c +++ b/driver/ppc/syv682x.c @@ -508,7 +508,7 @@ static void syv682x_handle_interrupt(int port) static void syv682x_irq_deferred(void) { int i; - uint32_t pending = atomic_read_clear(&irq_pending); + uint32_t pending = atomic_clear(&irq_pending); for (i = 0; i < board_get_usb_pd_port_count(); i++) if (BIT(i) & pending) |