Re: [PATCH 7/7 v3] KVM: PPC: BOOKE: Emulate debug registers and exception
On Tue, 2014-08-12 at 02:36 -0500, Bhushan Bharat-R65777 wrote: > > > -Original Message- > > From: Wood Scott-B07421 > > Sent: Tuesday, August 12, 2014 5:30 AM > > To: Bhushan Bharat-R65777 > > Cc: ag...@suse.de; kvm-ppc@vger.kernel.org; k...@vger.kernel.org; Yoder > > Stuart- > > B08248 > > Subject: Re: [PATCH 7/7 v3] KVM: PPC: BOOKE: Emulate debug registers and > > exception > > > > On Wed, 2014-08-06 at 12:08 +0530, Bharat Bhushan wrote: > > > @@ -1249,6 +1284,7 @@ int kvmppc_subarch_vcpu_init(struct kvm_vcpu *vcpu) > > > setup_timer(&vcpu->arch.wdt_timer, kvmppc_watchdog_func, > > > (unsigned long)vcpu); > > > > > > + kvmppc_clear_dbsr(); > > > return 0; > > > > This could use a comment for why we're doing this. Also, I'm a bit uneasy > > about > > clearing the whole DBSR here, where we haven't yet switched the debug > > registers > > to guest context. > > I think we wanted MRR to not cause debug event to guest, So should we only > clear MRR ? > > > It shouldn't actually matter except for deferred debug > > exceptions which are not actually useful (in fact e6500 removed support for > > them), > > Exactly, that's why I was clearing complete DBSR. Probably we can have a > comment > " Do not let previously set debug events visible to guest. As deferred debug > events > are not supported, so it is ok to clear complete DBSR. > " This would be affecting host debugging of the host, not guest debugging of the guest. Still I don't think it's a huge deal, but clearing only MRR would be cleaner. -Scott -- To unsubscribe from this list: send the line "unsubscribe kvm-ppc" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
RE: [PATCH 7/7 v3] KVM: PPC: BOOKE: Emulate debug registers and exception
> -Original Message- > From: Wood Scott-B07421 > Sent: Tuesday, August 12, 2014 5:30 AM > To: Bhushan Bharat-R65777 > Cc: ag...@suse.de; kvm-ppc@vger.kernel.org; k...@vger.kernel.org; Yoder > Stuart- > B08248 > Subject: Re: [PATCH 7/7 v3] KVM: PPC: BOOKE: Emulate debug registers and > exception > > On Wed, 2014-08-06 at 12:08 +0530, Bharat Bhushan wrote: > > @@ -1249,6 +1284,7 @@ int kvmppc_subarch_vcpu_init(struct kvm_vcpu *vcpu) > > setup_timer(&vcpu->arch.wdt_timer, kvmppc_watchdog_func, > > (unsigned long)vcpu); > > > > + kvmppc_clear_dbsr(); > > return 0; > > This could use a comment for why we're doing this. Also, I'm a bit uneasy > about > clearing the whole DBSR here, where we haven't yet switched the debug > registers > to guest context. I think we wanted MRR to not cause debug event to guest, So should we only clear MRR ? > It shouldn't actually matter except for deferred debug > exceptions which are not actually useful (in fact e6500 removed support for > them), Exactly, that's why I was clearing complete DBSR. Probably we can have a comment " Do not let previously set debug events visible to guest. As deferred debug events are not supported, so it is ok to clear complete DBSR. " Thanks -Bharat > but still... > > -Scott > N�r��yb�X��ǧv�^�){.n�+jir)w*jg����ݢj/���z�ޖ��2�ޙ&�)ߡ�a�����G���h��j:+v���w��٥
Re: [PATCH 7/7 v3] KVM: PPC: BOOKE: Emulate debug registers and exception
On Wed, 2014-08-06 at 12:08 +0530, Bharat Bhushan wrote: > @@ -1249,6 +1284,7 @@ int kvmppc_subarch_vcpu_init(struct kvm_vcpu *vcpu) > setup_timer(&vcpu->arch.wdt_timer, kvmppc_watchdog_func, > (unsigned long)vcpu); > > + kvmppc_clear_dbsr(); > return 0; This could use a comment for why we're doing this. Also, I'm a bit uneasy about clearing the whole DBSR here, where we haven't yet switched the debug registers to guest context. It shouldn't actually matter except for deferred debug exceptions which are not actually useful (in fact e6500 removed support for them), but still... -Scott -- To unsubscribe from this list: send the line "unsubscribe kvm-ppc" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html