WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] x86: deny access to the ACPI PM timer I/O

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] x86: deny access to the ACPI PM timer I/O port range for Dom0
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 28 Oct 2009 04:05:32 -0700
Delivery-date: Wed, 28 Oct 2009 04:06:02 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1256727353 0
# Node ID de4b6b7f55db934e45f74c84953ac28efcb96803
# Parent  ae942a3117bb776a7822d1d0a5c55d6c8a3aa2a7
x86: deny access to the ACPI PM timer I/O port range for Dom0

Also move the declaration of pmtmr_ioport to a suitable header file.

Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>
---
 xen/arch/x86/acpi/boot.c     |    4 ----
 xen/arch/x86/acpi/cpu_idle.c |    1 -
 xen/arch/x86/domain_build.c  |    4 ++++
 xen/arch/x86/time.c          |    1 +
 xen/include/asm-x86/acpi.h   |    2 ++
 5 files changed, 7 insertions(+), 5 deletions(-)

diff -r ae942a3117bb -r de4b6b7f55db xen/arch/x86/acpi/boot.c
--- a/xen/arch/x86/acpi/boot.c  Wed Oct 28 10:55:17 2009 +0000
+++ b/xen/arch/x86/acpi/boot.c  Wed Oct 28 10:55:53 2009 +0000
@@ -330,10 +330,6 @@ static int __init acpi_parse_hpet(struct
 }
 #else
 #define        acpi_parse_hpet NULL
-#endif
-
-#ifdef CONFIG_X86_PM_TIMER
-extern u32 pmtmr_ioport;
 #endif
 
 #ifdef CONFIG_ACPI_SLEEP
diff -r ae942a3117bb -r de4b6b7f55db xen/arch/x86/acpi/cpu_idle.c
--- a/xen/arch/x86/acpi/cpu_idle.c      Wed Oct 28 10:55:17 2009 +0000
+++ b/xen/arch/x86/acpi/cpu_idle.c      Wed Oct 28 10:55:53 2009 +0000
@@ -56,7 +56,6 @@ static void (*lapic_timer_off)(void);
 static void (*lapic_timer_off)(void);
 static void (*lapic_timer_on)(void);
 
-extern u32 pmtmr_ioport;
 extern void (*pm_idle) (void);
 extern void (*dead_idle) (void);
 extern void menu_get_trace_data(u32 *expected, u32 *pred);
diff -r ae942a3117bb -r de4b6b7f55db xen/arch/x86/domain_build.c
--- a/xen/arch/x86/domain_build.c       Wed Oct 28 10:55:17 2009 +0000
+++ b/xen/arch/x86/domain_build.c       Wed Oct 28 10:55:53 2009 +0000
@@ -29,6 +29,7 @@
 #include <asm/paging.h>
 #include <asm/p2m.h>
 #include <asm/e820.h>
+#include <asm/acpi.h>
 #include <asm/bzimage.h> /* for bzimage_parse */
 
 #include <public/version.h>
@@ -1064,6 +1065,9 @@ int __init construct_dom0(
     rc |= ioports_deny_access(dom0, 0x40, 0x43);
     /* PIT Channel 2 / PC Speaker Control. */
     rc |= ioports_deny_access(dom0, 0x61, 0x61);
+    /* ACPI PM Timer. */
+    if ( pmtmr_ioport )
+        rc |= ioports_deny_access(dom0, pmtmr_ioport, pmtmr_ioport + 3);
     /* PCI configuration space (NB. 0xcf8 has special treatment). */
     rc |= ioports_deny_access(dom0, 0xcfc, 0xcff);
     /* Command-line I/O ranges. */
diff -r ae942a3117bb -r de4b6b7f55db xen/arch/x86/time.c
--- a/xen/arch/x86/time.c       Wed Oct 28 10:55:17 2009 +0000
+++ b/xen/arch/x86/time.c       Wed Oct 28 10:55:53 2009 +0000
@@ -30,6 +30,7 @@
 #include <asm/fixmap.h>
 #include <asm/mc146818rtc.h>
 #include <asm/div64.h>
+#include <asm/acpi.h>
 #include <asm/hpet.h>
 #include <io_ports.h>
 #include <asm/setup.h> /* for early_time_init */
diff -r ae942a3117bb -r de4b6b7f55db xen/include/asm-x86/acpi.h
--- a/xen/include/asm-x86/acpi.h        Wed Oct 28 10:55:17 2009 +0000
+++ b/xen/include/asm-x86/acpi.h        Wed Oct 28 10:55:53 2009 +0000
@@ -153,6 +153,8 @@ extern u8 x86_acpiid_to_apicid[];
 extern u8 x86_acpiid_to_apicid[];
 #define MAX_LOCAL_APIC 256
 
+extern u32 pmtmr_ioport;
+
 int acpi_dmar_init(void);
 void acpi_mmcfg_init(void);
 

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] x86: deny access to the ACPI PM timer I/O port range for Dom0, Xen patchbot-unstable <=