Skip to contentSkip to conversation

arm: constify atomic_read parameter

PATCH In review Wei Liu 3 participants 4 messages Aug 15, 2018

lore
Share & tools
lore

Wei Liu

author
#0 lore raw

PATCH 1/1 arm: constify atomic_read parameter

ded2a37d63 added const to atomic_read. Do the same for Arm counterpart.

---
Cc: Stefano Stabellini <[email protected]>
Cc: Julien Grall <[email protected]>
Cc: Jan Beulich <[email protected]>
Cc: Andrew Cooper <[email protected]>

Breakage due to XSA-273 changes.

---
 xen/include/asm-arm/atomic.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
xen/include/asm-arm/atomic.h +1 -1
index 29ab265f00..de22fd55d7 100644
@@ -110,7 +110,7 @@ typedef struct { int counter; } atomic_t;
  * strex/ldrex monitor on some implementations. The reason we can use it for
  * atomic_set() is the clrex or dummy strex done on every exception return.
  */
-static inline int atomic_read(atomic_t *v)
+static inline int atomic_read(const atomic_t *v)
 {
     return *(volatile int *)&v->counter;
 }
Signature · 7 lines
2.11.0


_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel
Acked-by
#2 lore raw
Quoted 9 lines · Andrew Cooper
Quoted 4 lines · Wei Liu

ded2a37d63 added const to atomic_read. Do the same for Arm counterpart.

Most likely needed for 4.6 as well.

Feel free to add my ack on 4.6 patch as well:

Quoted 3 lines

~Andrew

Signature · 6 lines
Julien Grall

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel
author
#3 lore raw
Quoted 9 lines · Julien Grall
Quoted 6 lines · Andrew Cooper
Quoted 4 lines · Wei Liu

ded2a37d63 added const to atomic_read. Do the same for Arm counterpart.

Quoted 7 lines
Quoted 3 lines

Most likely needed for 4.6 as well.

Feel free to add my ack on 4.6 patch as well:

Thanks. I will commit both patches shortly.

Quoted 7 lines
Quoted 4 lines

~Andrew

Signature · 1 line
Julien Grall

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel