[PATCH 2/2] ARM: include: asm: use 'int' instead of 'unsigned long' for normal register variables within atomic.h

Will Deacon will.deacon at arm.com
Fri Oct 4 11:37:42 EDT 2013


On Fri, Oct 04, 2013 at 10:51:56AM +0100, Chen Gang wrote:
> On 10/04/2013 12:32 AM, Will Deacon wrote:
> > The problem with arm64 is that we're using *unsigned long* for 32-bit
> > clear_mask, which is definitely wrong because it's 64-bit (another patch to
> > fix this!).
> > 
> 
> At least, that is not a bug.

Sure it is. What if the adjacent 32-bit value was being accessed by another
CPU under a spinlock?

Will



More information about the linux-arm-kernel mailing list