Re: [PATCH 1/3] arm64: KVM: Move CPU ID reg trap setup off the world switch path

2017-12-06 Thread Dave Martin
On Wed, Dec 06, 2017 at 11:53:00AM +0100, Christoffer Dall wrote: > On Tue, Dec 05, 2017 at 12:31:51PM +, Dave Martin wrote: > > On Tue, Dec 05, 2017 at 10:09:15AM +0100, Christoffer Dall wrote: > > > On Fri, Dec 01, 2017 at 03:19:40PM +, Dave Martin wrote: > > > > The HCR_EL2.TID3 flag nee

Re: [PATCH 1/3] arm64: KVM: Move CPU ID reg trap setup off the world switch path

2017-12-06 Thread Christoffer Dall
On Tue, Dec 05, 2017 at 12:31:51PM +, Dave Martin wrote: > On Tue, Dec 05, 2017 at 10:09:15AM +0100, Christoffer Dall wrote: > > On Fri, Dec 01, 2017 at 03:19:40PM +, Dave Martin wrote: > > > The HCR_EL2.TID3 flag needs to be set when trapping guest access to > > > the CPU ID registers is r

Re: [PATCH 1/3] arm64: KVM: Move CPU ID reg trap setup off the world switch path

2017-12-05 Thread Dave Martin
On Tue, Dec 05, 2017 at 10:09:15AM +0100, Christoffer Dall wrote: > On Fri, Dec 01, 2017 at 03:19:40PM +, Dave Martin wrote: > > The HCR_EL2.TID3 flag needs to be set when trapping guest access to > > the CPU ID registers is required. However, the decision about > > whether to set this bit doe

Re: [PATCH 1/3] arm64: KVM: Move CPU ID reg trap setup off the world switch path

2017-12-05 Thread Christoffer Dall
On Fri, Dec 01, 2017 at 03:19:40PM +, Dave Martin wrote: > The HCR_EL2.TID3 flag needs to be set when trapping guest access to > the CPU ID registers is required. However, the decision about > whether to set this bit does not need to be repeated at every > switch to the guest. > > Instead, it

[PATCH 1/3] arm64: KVM: Move CPU ID reg trap setup off the world switch path

2017-12-01 Thread Dave Martin
The HCR_EL2.TID3 flag needs to be set when trapping guest access to the CPU ID registers is required. However, the decision about whether to set this bit does not need to be repeated at every switch to the guest. Instead, it's sufficient to make this decision once and record the outcome. This pa