All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sebastian Ene <sebastianene@google.com>
To: Alexandru Elisei <alexandru.elisei@arm.com>
Cc: kvm@vger.kernel.org, qperret@google.com, will@kernel.org,
	julien.thierry.kdev@gmail.com, maz@kernel.org
Subject: Re: [PATCH kvmtool v8 1/3] aarch64: Populate the vCPU struct before target->init()
Date: Tue, 8 Mar 2022 13:17:38 +0000	[thread overview]
Message-ID: <YidXctiW9xUoJl80@google.com> (raw)
In-Reply-To: <YicvwRlojrgSSrdU@monolith.localdoman>

On Tue, Mar 08, 2022 at 10:28:17AM +0000, Alexandru Elisei wrote:
> Hi,
> 

Hi,

> On Mon, Mar 07, 2022 at 02:42:42PM +0000, Sebastian Ene wrote:
> > Move the vCPU structure initialisation before the target->init() call to
> >  keep a reference to the kvm structure during init().
> > This is required by the pvtime peripheral to reserve a memory region
> > while the vCPU is beeing initialised.
> > 
> > Signed-off-by: Sebastian Ene <sebastianene@google.com>
> 
> I think you're missing Marc's Reviewed-by tag.
>

I will add the Reviewed-by tag to the next iteration.

> Thanks,
> Alex
> 

Thanks,
Sebastian

> > ---
> >  arm/kvm-cpu.c | 14 +++++++-------
> >  1 file changed, 7 insertions(+), 7 deletions(-)
> > 
> > diff --git a/arm/kvm-cpu.c b/arm/kvm-cpu.c
> > index 6a2408c..84ac1e9 100644
> > --- a/arm/kvm-cpu.c
> > +++ b/arm/kvm-cpu.c
> > @@ -116,6 +116,13 @@ struct kvm_cpu *kvm_cpu__arch_init(struct kvm *kvm, unsigned long cpu_id)
> >  			die("Unable to find matching target");
> >  	}
> >  
> > +	/* Populate the vcpu structure. */
> > +	vcpu->kvm		= kvm;
> > +	vcpu->cpu_id		= cpu_id;
> > +	vcpu->cpu_type		= vcpu_init.target;
> > +	vcpu->cpu_compatible	= target->compatible;
> > +	vcpu->is_running	= true;
> > +
> >  	if (err || target->init(vcpu))
> >  		die("Unable to initialise vcpu");
> >  
> > @@ -125,13 +132,6 @@ struct kvm_cpu *kvm_cpu__arch_init(struct kvm *kvm, unsigned long cpu_id)
> >  		vcpu->ring = (void *)vcpu->kvm_run +
> >  			     (coalesced_offset * PAGE_SIZE);
> >  
> > -	/* Populate the vcpu structure. */
> > -	vcpu->kvm		= kvm;
> > -	vcpu->cpu_id		= cpu_id;
> > -	vcpu->cpu_type		= vcpu_init.target;
> > -	vcpu->cpu_compatible	= target->compatible;
> > -	vcpu->is_running	= true;
> > -
> >  	if (kvm_cpu__configure_features(vcpu))
> >  		die("Unable to configure requested vcpu features");
> >  
> > -- 
> > 2.35.1.616.g0bdcbb4464-goog
> > 
> > _______________________________________________
> > kvmarm mailing list
> > kvmarm@lists.cs.columbia.edu
> > https://lists.cs.columbia.edu/mailman/listinfo/kvmarm

  reply	other threads:[~2022-03-08 13:17 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-07 14:42 [PATCH kvmtool v8 0/3] aarch64: Add stolen time support Sebastian Ene
2022-03-07 14:42 ` Sebastian Ene
2022-03-07 14:42 ` [PATCH kvmtool v8 1/3] aarch64: Populate the vCPU struct before target->init() Sebastian Ene
2022-03-07 14:42   ` Sebastian Ene
2022-03-08 10:28   ` Alexandru Elisei
2022-03-08 10:28     ` Alexandru Elisei
2022-03-08 13:17     ` Sebastian Ene [this message]
2022-03-07 14:42 ` [PATCH kvmtool v8 2/3] aarch64: Add stolen time support Sebastian Ene
2022-03-07 14:42   ` Sebastian Ene
2022-03-08 10:44   ` Alexandru Elisei
2022-03-08 10:44     ` Alexandru Elisei
2022-03-08 13:14     ` Sebastian Ene
2022-03-07 14:42 ` [PATCH kvmtool v8 3/3] Add --no-pvtime command line argument Sebastian Ene
2022-03-07 14:42   ` Sebastian Ene
2022-03-08 10:46   ` Alexandru Elisei
2022-03-08 10:46     ` Alexandru Elisei

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YidXctiW9xUoJl80@google.com \
    --to=sebastianene@google.com \
    --cc=alexandru.elisei@arm.com \
    --cc=julien.thierry.kdev@gmail.com \
    --cc=kvm@vger.kernel.org \
    --cc=maz@kernel.org \
    --cc=qperret@google.com \
    --cc=will@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.