PERFORCE change 154400 for review

Nathan Whitehorn nwhitehorn at FreeBSD.org
Tue Dec 9 08:12:11 PST 2008


http://perforce.freebsd.org/chv.cgi?CH=154400

Change 154400 by nwhitehorn at nwhitehorn_trantor on 2008/12/09 16:11:49

	We don't do anything useful with HID0 on G5 systems, so ignore it.

Affected files ...

.. //depot/projects/ppc-g5/sys/powerpc/powerpc/cpu.c#4 edit

Differences ...

==== //depot/projects/ppc-g5/sys/powerpc/powerpc/cpu.c#4 (text+ko) ====

@@ -93,6 +93,8 @@
         { "IBM PowerPC 750FX",		IBM750FX,	REVFMT_MAJMIN },
         { "IBM PowerPC 970",		IBM970,		REVFMT_MAJMIN },
         { "IBM PowerPC 970FX",		IBM970FX,	REVFMT_MAJMIN },
+        { "IBM PowerPC 970GX",		IBM970GX,	REVFMT_MAJMIN },
+        { "IBM PowerPC 970MP",		IBM970MP,	REVFMT_MAJMIN },
         { "Motorola PowerPC 7400",	MPC7400,	REVFMT_MAJMIN },
         { "Motorola PowerPC 7410",	MPC7410,	REVFMT_MAJMIN },
         { "Motorola PowerPC 7450",	MPC7450,	REVFMT_MAJMIN },
@@ -118,7 +120,7 @@
 void
 cpu_setup(u_int cpuid)
 {
-	u_int		pvr, maj, min, msr, hid0, hid0lower;
+	u_int		pvr, maj, min, msr, hid0;
 	uint16_t	vers, rev, revfmt;
 	const struct	cputab *cp;
 	const char	*name;
@@ -170,26 +172,6 @@
 	}
 
 	/*
-	 * Read HID0. On 64-bit machines, the bits we care about
-	 * are (irritatingly) in the upper word of the register.
-	 */
-
-	if (ppc64) {
-		hid0 = mfspr64upper(SPR_HID0,msr);
-		hid0lower = mfspr(SPR_HID0);
-	} else {
-		hid0 = mfspr(SPR_HID0);
-		hid0lower = 0;
-	}
-
-	/*
-	 * Set PMC granularity for 64 bit systems (architectural).
-	 */
-
-	if (ppc64)
-		hid0 &= ~HID0_TG;
-
-	/*
 	 * Configure power-saving mode.
 	 */
 	switch (vers) {
@@ -251,11 +233,6 @@
 			break;
 	}
 
-	if (ppc64)
-		mtspr64(SPR_HID0, hid0, hid0lower, msr);
-	else
-		mtspr(SPR_HID0, hid0);
-
 	switch (vers) {
 		case MPC7447A:
 		case MPC7448:


More information about the p4-projects mailing list