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-devel

[Xen-devel] [PATCH] x86: restrict keyboard io ports reservation to make

To: <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] [PATCH] x86: restrict keyboard io ports reservation to make ipmi driver work
From: Markus Armbruster <armbru@xxxxxxxxxx>
Date: Thu, 24 Jul 2008 15:41:00 -0400
Cc: Peter Martuccelli <peterm@xxxxxxxxxx>
Delivery-date: Thu, 24 Jul 2008 12:41:50 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <C4ADEAC5.1B805%keir.fraser@xxxxxxxxxxxxx> (Keir Fraser's message of "Thu\, 24 Jul 2008 08\:16\:05 +0100")
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <C4ADEAC5.1B805%keir.fraser@xxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux)
Straightforward port of 
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=9096bd7a66efbe406910365c5206a32eed3875af

Quoting its commit message:

    x86: restrict keyboard io ports reservation to make ipmi driver work
    
    On some of our (single board computer) boards (x86) we are using an
    IPMI controller that uses I/O ports 0x62 and 0x66 for a KCS (keyboard
    controller style) IPMI system interface.
    
    Trying to load the openipmi driver fails, because the ports
    (0x62/0x66) are reserved for keyboard. keyboard reserves the full
    range 0x60-0x6F while it doesn't need to.
    
    Reserve only ports 0x60 and 0x64 for the legacy PS/2 i8042 keyboad
    controller instead of 0x60-0x6F to allow the openipmi driver to work.
    
    [ tglx: added 64bit fixup ]
    
    Signed-off-by: Thomas Gleixner <tglx@xxxxxxxxxxxxx>
    Acked-by: H. Peter Anvin <hpa@xxxxxxxxx>
    Signed-off-by: Ingo Molnar <mingo@xxxxxxx>

Signed-off-by: Markus Armbruster <armbru@xxxxxxxxxx>


diff -r d25b46565529 arch/i386/kernel/setup-xen.c
--- a/arch/i386/kernel/setup-xen.c      Wed Jul 23 14:21:58 2008 +0100
+++ b/arch/i386/kernel/setup-xen.c      Thu Jul 24 10:43:04 2008 -0400
@@ -283,7 +283,12 @@
 }, {
        .name   = "keyboard",
        .start  = 0x0060,
-       .end    = 0x006f,
+       .end    = 0x0060,
+       .flags  = IORESOURCE_BUSY | IORESOURCE_IO
+}, {
+       .name   = "keyboard",
+       .start  = 0x0064,
+       .end    = 0x0064,
        .flags  = IORESOURCE_BUSY | IORESOURCE_IO
 }, {
        .name   = "dma page reg",
diff -r d25b46565529 arch/i386/kernel/setup.c
--- a/arch/i386/kernel/setup.c  Wed Jul 23 14:21:58 2008 +0100
+++ b/arch/i386/kernel/setup.c  Thu Jul 24 10:43:04 2008 -0400
@@ -261,7 +261,12 @@
 }, {
        .name   = "keyboard",
        .start  = 0x0060,
-       .end    = 0x006f,
+       .end    = 0x0060,
+       .flags  = IORESOURCE_BUSY | IORESOURCE_IO
+}, {
+       .name   = "keyboard",
+       .start  = 0x0064,
+       .end    = 0x0064,
        .flags  = IORESOURCE_BUSY | IORESOURCE_IO
 }, {
        .name   = "dma page reg",
diff -r d25b46565529 arch/x86_64/kernel/setup-xen.c
--- a/arch/x86_64/kernel/setup-xen.c    Wed Jul 23 14:21:58 2008 +0100
+++ b/arch/x86_64/kernel/setup-xen.c    Thu Jul 24 10:43:04 2008 -0400
@@ -169,7 +169,9 @@
                .flags = IORESOURCE_BUSY | IORESOURCE_IO },
        { .name = "timer1", .start = 0x50, .end = 0x53,
                .flags = IORESOURCE_BUSY | IORESOURCE_IO },
-       { .name = "keyboard", .start = 0x60, .end = 0x6f,
+       { .name = "keyboard", .start = 0x60, .end = 0x60,
+               .flags = IORESOURCE_BUSY | IORESOURCE_IO },
+       { .name = "keyboard", .start = 0x64, .end = 0x64,
                .flags = IORESOURCE_BUSY | IORESOURCE_IO },
        { .name = "dma page reg", .start = 0x80, .end = 0x8f,
                .flags = IORESOURCE_BUSY | IORESOURCE_IO },
diff -r d25b46565529 arch/x86_64/kernel/setup.c
--- a/arch/x86_64/kernel/setup.c        Wed Jul 23 14:21:58 2008 +0100
+++ b/arch/x86_64/kernel/setup.c        Thu Jul 24 10:43:04 2008 -0400
@@ -122,7 +122,9 @@
                .flags = IORESOURCE_BUSY | IORESOURCE_IO },
        { .name = "timer1", .start = 0x50, .end = 0x53,
                .flags = IORESOURCE_BUSY | IORESOURCE_IO },
-       { .name = "keyboard", .start = 0x60, .end = 0x6f,
+       { .name = "keyboard", .start = 0x60, .end = 0x60,
+               .flags = IORESOURCE_BUSY | IORESOURCE_IO },
+       { .name = "keyboard", .start = 0x64, .end = 0x64,
                .flags = IORESOURCE_BUSY | IORESOURCE_IO },
        { .name = "dma page reg", .start = 0x80, .end = 0x8f,
                .flags = IORESOURCE_BUSY | IORESOURCE_IO },

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

<Prev in Thread] Current Thread [Next in Thread>