Re: [PATCH v18 03/14] KVM: arm64: Manage GCS access and registers for guests

Yao Yuan <[email protected]>
Newsgroups gmane.linux.documentation,gmane.linux.ports.arm.kernel,gmane.linux.kernel
Message-ID <rduid57zbypxwiujgfez67walqgqkekhyktkbibtiqcjh5buge@jqqcu52yl5nc>
On Wed, Aug 05, 2026 at 01:32:26PM +0800, Mark Brown wrote:
> On Wed, Aug 05, 2026 at 05:48:04PM +0800, Yao Yuan wrote:
> > On Mon, Aug 03, 2026 at 11:56:48PM +0800, Mark Brown wrote:
>
> > >
> > >  		if (ctxt_has_s1poe(&vcpu->arch.ctxt))
> > >  			write_sysreg_el1(__vcpu_sys_reg(vcpu, POR_EL2), SYS_POR);
> > > +
> > > +		if (ctxt_has_gcs(&vcpu->arch.ctxt)) {
> > > +			write_sysreg_el1(__vcpu_sys_reg(vcpu, GCSCR_EL2), SYS_GCSCR);
> > > +			write_sysreg_el1(__vcpu_sys_reg(vcpu, GCSPR_EL2), SYS_GCSPR);
> > > +		}
>
> > Looks the s1pie checking for GCS vEL2 context switch is
> > necessary yet IIUC, KVM does vEL2 context switch for nested
> > L1's EL2, it should follow same rule as non-nested L1's EL1
> > context switch.
>
> Right, it's not really needed in either case but hopefully helps code
> generation a bit.  Thanks for spotting that.
>
> Please delete unneeded context from mails when replying.  Doing this
> makes it much easier to find your reply in the message, helping ensure
> it won't be missed by people scrolling through the irrelevant quoted
> material.

Sure. let me try delete more next time.
I delete some but decide to leave the whole context switch
diffs to help other guys to see the realted changes when
read my comment.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.