From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55407) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YSoqg-0007xb-Nt for qemu-devel@nongnu.org; Tue, 03 Mar 2015 10:35:11 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YSoqa-00072q-St for qemu-devel@nongnu.org; Tue, 03 Mar 2015 10:35:06 -0500 Received: from mx1.redhat.com ([209.132.183.28]:53176) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YSoqa-00072d-L4 for qemu-devel@nongnu.org; Tue, 03 Mar 2015 10:35:00 -0500 Message-ID: <54F5D49A.6020003@redhat.com> Date: Tue, 03 Mar 2015 16:34:50 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <1421428797-23697-1-git-send-email-fred.konrad@greensocs.com> <1421428797-23697-2-git-send-email-fred.konrad@greensocs.com> <54EF614B.1010607@greensocs.com> <73E10212-3603-4B64-BA61-66607C12A16A@greensocs.com> <711BBCAD-9514-4523-A456-AD4F397C41CD@greensocs.com> <54F5D3F4.40705@redhat.com> <19B4F8D2-B464-4B00-900C-A057DCCD54B3@greensocs.com> In-Reply-To: <19B4F8D2-B464-4B00-900C-A057DCCD54B3@greensocs.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [RFC 01/10] target-arm: protect cpu_exclusive_*. List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Mark Burton Cc: mttcg@greensocs.com, Peter Maydell , "J. Kiszka" , Alexander Graf , QEMU Developers , =?UTF-8?B?S09OUkFEIEZyw6lkw6k=?= =?UTF-8?B?cmlj?= On 03/03/2015 16:33, Mark Burton wrote: >=20 >> On 3 Mar 2015, at 16:32, Paolo Bonzini wrote: >> >> >> >> On 03/03/2015 16:29, Mark Burton wrote: >>> >>> ps. on our bug - we believe somehow the STREX is being marked as >>> failed, but actually succeeds to write something. There are only 3 >>> ways the strex can fail: 1/ the address doesn't match - in which case >>> no ST will be attempted 2/ the value doesn't match - which means - no >>> ST attempted 3/ the store starts, but causes a TLB fill/exception=E2=80= =A6 >>> >>> The 3rd has 2 possibilities - the TLB is filled, and the store goes >>> ahead totally normally - there should be no =E2=80=98fail=E2=80=99 - = or an exception >>> is generated in which case we will long jump away and never return. >> >> When do you release the lock? >> > (Thanks Paolo!) >=20 > We release the lock in either > a) the end of the strex > or > b) in the =E2=80=98raise_exception=E2=80=99 That seems right... Can you post the patch? Paolo