[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20241125133755.14417-D-hca@linux.ibm.com>
Date: Mon, 25 Nov 2024 14:37:55 +0100
From: Heiko Carstens <hca@...ux.ibm.com>
To: Claudio Imbrenda <imbrenda@...ux.ibm.com>
Cc: Christian Borntraeger <borntraeger@...ux.ibm.com>,
Janosch Frank <frankja@...ux.ibm.com>,
David Hildenbrand <david@...hat.com>, kvm@...r.kernel.org,
linux-s390@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/3] KVM: s390: Remove one byte cmpxchg() usage
On Mon, Nov 25, 2024 at 01:16:17PM +0100, Claudio Imbrenda wrote:
> On Mon, 25 Nov 2024 12:50:38 +0100
> Heiko Carstens <hca@...ux.ibm.com> wrote:
> > @@ -128,23 +126,16 @@ static void sca_clear_ext_call(struct kvm_vcpu *vcpu)
> > struct esca_block *sca = vcpu->kvm->arch.sca;
> > union esca_sigp_ctrl *sigp_ctrl =
> > &(sca->cpu[vcpu->vcpu_id].sigp_ctrl);
> > - union esca_sigp_ctrl old;
> >
> > - old = READ_ONCE(*sigp_ctrl);
> > - expect = old.value;
> > - rc = cmpxchg(&sigp_ctrl->value, old.value, 0);
> > + WRITE_ONCE(sigp_ctrl->value, 9);
>
> that's supposed to be a 0, right?
Duh... yes, of course. I added the "9" to better find the corresponding
code in assembly, and obviously forgot to replace it with 0 again.
Thanks for pointing this out!
Strange enough this still worked. Hmm.
Powered by blists - more mailing lists