target/ppc: Emulate LL/SC using cmpxchg helpers
commit253ce7b2cfc0bccc3470335b0d7282457926087d
authorNikunj A Dadhania <nikunj@linux.vnet.ibm.com>
Thu, 27 Apr 2017 05:18:19 +0000 (27 10:48 +0530)
committerDavid Gibson <david@gibson.dropbear.id.au>
Wed, 10 May 2017 23:45:14 +0000 (11 09:45 +1000)
treedd65f81195f155f2819acfbfa42f8d17f8651e36
parenta1a636b8b444acacf8c4299923c907ed2475811f
target/ppc: Emulate LL/SC using cmpxchg helpers

Emulating LL/SC with cmpxchg is not correct, since it can suffer from
the ABA problem. However, portable parallel code is written assuming
only cmpxchg which means that in practice this is a viable alternative.

Signed-off-by: Nikunj A Dadhania <nikunj@linux.vnet.ibm.com>
Reviewed-by: Richard Henderson <rth@twiddle.net>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
target/ppc/translate.c