Re: [Xen-devel] [PATCH 02/16] x86: fix: make atomic_read() param const

2016-07-12 Thread Corneliu ZUZU
On 7/12/2016 3:49 PM, Andrew Cooper wrote: On 12/07/16 11:38, Corneliu ZUZU wrote: On 7/12/2016 1:22 PM, Andrew Cooper wrote: On 12/07/16 11:11, Corneliu ZUZU wrote: If you are really feeling up to it, having a common xen/atomic.h with typedef struct { int counter; } atomic_t; #define ATOMIC_

Re: [Xen-devel] [PATCH 02/16] x86: fix: make atomic_read() param const

2016-07-12 Thread Andrew Cooper
On 12/07/16 11:38, Corneliu ZUZU wrote: > On 7/12/2016 1:22 PM, Andrew Cooper wrote: >> On 12/07/16 11:11, Corneliu ZUZU wrote: >> If you are really feeling up to it, having a common xen/atomic.h >> with >> >> typedef struct { int counter; } atomic_t; >> #define ATOMIC_INIT(i) {

Re: [Xen-devel] [PATCH 02/16] x86: fix: make atomic_read() param const

2016-07-12 Thread Corneliu ZUZU
On 7/12/2016 1:22 PM, Andrew Cooper wrote: On 12/07/16 11:11, Corneliu ZUZU wrote: If you are really feeling up to it, having a common xen/atomic.h with typedef struct { int counter; } atomic_t; #define ATOMIC_INIT(i) { (i) } and some prototypes such as: static inline int atomic_read(const at

Re: [Xen-devel] [PATCH 02/16] x86: fix: make atomic_read() param const

2016-07-12 Thread Corneliu ZUZU
On 7/12/2016 1:22 PM, Andrew Cooper wrote: On 12/07/16 11:11, Corneliu ZUZU wrote: If you are really feeling up to it, having a common xen/atomic.h with typedef struct { int counter; } atomic_t; #define ATOMIC_INIT(i) { (i) } and some prototypes such as: static inline int atomic_read(const at

Re: [Xen-devel] [PATCH 02/16] x86: fix: make atomic_read() param const

2016-07-12 Thread Andrew Cooper
On 12/07/16 11:11, Corneliu ZUZU wrote: > >> If you are really feeling up to it, having a common xen/atomic.h with typedef struct { int counter; } atomic_t; #define ATOMIC_INIT(i) { (i) } and some prototypes such as: static inline int atomic_read(const atomic

Re: [Xen-devel] [PATCH 02/16] x86: fix: make atomic_read() param const

2016-07-12 Thread Corneliu ZUZU
On 7/12/2016 12:42 PM, Andrew Cooper wrote: On 12/07/16 06:11, Corneliu ZUZU wrote: Hi Andrew, On 7/11/2016 6:18 PM, Andrew Cooper wrote: On 09/07/16 05:12, Corneliu ZUZU wrote: This wouldn't let me make a param of a function that used atomic_read() const. Signed-off-by: Corneliu ZUZU This

Re: [Xen-devel] [PATCH 02/16] x86: fix: make atomic_read() param const

2016-07-12 Thread Andrew Cooper
On 12/07/16 06:11, Corneliu ZUZU wrote: > Hi Andrew, > > On 7/11/2016 6:18 PM, Andrew Cooper wrote: >> On 09/07/16 05:12, Corneliu ZUZU wrote: >>> This wouldn't let me make a param of a function that used >>> atomic_read() const. >>> >>> Signed-off-by: Corneliu ZUZU >> This is a good improvement,

Re: [Xen-devel] [PATCH 02/16] x86: fix: make atomic_read() param const

2016-07-11 Thread Corneliu ZUZU
Hi Andrew, On 7/11/2016 6:18 PM, Andrew Cooper wrote: On 09/07/16 05:12, Corneliu ZUZU wrote: This wouldn't let me make a param of a function that used atomic_read() const. Signed-off-by: Corneliu ZUZU This is a good improvement, but you must make an identical adjustment to the arm code, oth

Re: [Xen-devel] [PATCH 02/16] x86: fix: make atomic_read() param const

2016-07-11 Thread Andrew Cooper
On 09/07/16 05:12, Corneliu ZUZU wrote: > This wouldn't let me make a param of a function that used atomic_read() const. > > Signed-off-by: Corneliu ZUZU This is a good improvement, but you must make an identical adjustment to the arm code, otherwise you will end up with subtle build failures. I

[Xen-devel] [PATCH 02/16] x86: fix: make atomic_read() param const

2016-07-08 Thread Corneliu ZUZU
This wouldn't let me make a param of a function that used atomic_read() const. Signed-off-by: Corneliu ZUZU --- xen/include/asm-x86/atomic.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xen/include/asm-x86/atomic.h b/xen/include/asm-x86/atomic.h index d246b70..0b250c8