linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] fix PMU initialization on pseries lpar
@ 2006-08-02  4:20 Sonny Rao
  2006-08-02  4:29 ` Michael Ellerman
  0 siblings, 1 reply; 2+ messages in thread
From: Sonny Rao @ 2006-08-02  4:20 UTC (permalink / raw)
  To: paulus; +Cc: linuxppc-dev

We should not be calling power4_enable_pmcs() in
pseries_lpar_enable_pmcs(); just doing the hypercall is sufficient. 
Prior to 2.6.15 we did not call power4_enable_pmcs() for an lpar.

power4_enable_pmcs() tries to read the hid0 register which is no
longer legal for an lpar in newer Power processors.

--- a/arch/powerpc/platforms/pseries/setup.c	2006-04-23 01:45:09.000000000 -0500
+++ b/arch/powerpc/platforms/pseries/setup.c~pmcfix	2006-08-01 23:12:39.000000000 -0500
@@ -182,8 +182,6 @@ static void pseries_lpar_enable_pmcs(voi
 {
 	unsigned long set, reset;
 
-	power4_enable_pmcs();
-
 	set = 1UL << 63;
 	reset = 0;
 	plpar_hcall_norets(H_PERFMON, set, reset);

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] fix PMU initialization on pseries lpar
  2006-08-02  4:20 [PATCH] fix PMU initialization on pseries lpar Sonny Rao
@ 2006-08-02  4:29 ` Michael Ellerman
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Ellerman @ 2006-08-02  4:29 UTC (permalink / raw)
  To: Sonny Rao; +Cc: linuxppc-dev, paulus

[-- Attachment #1: Type: text/plain, Size: 649 bytes --]

On Wed, 2006-08-02 at 00:20 -0400, Sonny Rao wrote:
> We should not be calling power4_enable_pmcs() in
> pseries_lpar_enable_pmcs(); just doing the hypercall is sufficient. 
> Prior to 2.6.15 we did not call power4_enable_pmcs() for an lpar.
> 
> power4_enable_pmcs() tries to read the hid0 register which is no
> longer legal for an lpar in newer Power processors.

Argh, how did I miss that. Mea culpa. 

cheers

-- 
Michael Ellerman
IBM OzLabs

wwweb: http://michael.ellerman.id.au
phone: +61 2 6212 1183 (tie line 70 21183)

We do not inherit the earth from our ancestors,
we borrow it from our children. - S.M.A.R.T Person

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 191 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2006-08-02  4:29 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-08-02  4:20 [PATCH] fix PMU initialization on pseries lpar Sonny Rao
2006-08-02  4:29 ` Michael Ellerman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).