Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/x86/acpi add support for Family 14h (AMD Fusion)



details:   https://anonhg.NetBSD.org/src/rev/0dedca8e3d6a
branches:  trunk
changeset: 762622:0dedca8e3d6a
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Thu Feb 24 13:19:36 2011 +0000

description:
add support for Family 14h (AMD Fusion)

diffstat:

 sys/arch/x86/acpi/acpi_cpu_md.c |  12 ++++++++----
 1 files changed, 8 insertions(+), 4 deletions(-)

diffs (54 lines):

diff -r 75643a6468f5 -r 0dedca8e3d6a sys/arch/x86/acpi/acpi_cpu_md.c
--- a/sys/arch/x86/acpi/acpi_cpu_md.c   Thu Feb 24 12:25:44 2011 +0000
+++ b/sys/arch/x86/acpi/acpi_cpu_md.c   Thu Feb 24 13:19:36 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: acpi_cpu_md.c,v 1.39 2011/02/15 17:50:46 jruoho Exp $ */
+/* $NetBSD: acpi_cpu_md.c,v 1.40 2011/02/24 13:19:36 jmcneill Exp $ */
 
 /*-
  * Copyright (c) 2010 Jukka Ruohonen <jruohonen%iki.fi@localhost>
@@ -27,7 +27,7 @@
  * SUCH DAMAGE.
  */
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: acpi_cpu_md.c,v 1.39 2011/02/15 17:50:46 jruoho Exp $");
+__KERNEL_RCSID(0, "$NetBSD: acpi_cpu_md.c,v 1.40 2011/02/24 13:19:36 jmcneill Exp $");
 
 #include <sys/param.h>
 #include <sys/bus.h>
@@ -60,7 +60,7 @@
 #define MSR_CMPHALT_BMSTS      __BIT(29)
 
 /*
- * AMD families 10h and 11h.
+ * AMD families 10h, 11h, and 14h
  */
 #define MSR_10H_LIMIT          0xc0010061
 #define MSR_10H_CONTROL                0xc0010062
@@ -271,6 +271,10 @@
 
                case 0x10:
                case 0x11:
+                       val |= ACPICPU_FLAG_C_C1E;
+                       /* FALLTHROUGH */
+
+               case 0x14: /* AMD Fusion */
 
                        if ((regs[3] & CPUID_APM_TSC) != 0)
                                val &= ~ACPICPU_FLAG_C_TSC;
@@ -281,7 +285,6 @@
                        if ((regs[3] & CPUID_APM_CPB) != 0)
                                val |= ACPICPU_FLAG_P_TURBO;
 
-                       val |= ACPICPU_FLAG_C_C1E;
                        break;
                }
 
@@ -495,6 +498,7 @@
 
                case 0x10:
                case 0x11:
+               case 0x14: /* AMD Fusion */
                        msr.ps_control_addr = MSR_10H_CONTROL;
                        msr.ps_control_mask = __BITS(0, 2);
 



Home | Main Index | Thread Index | Old Index