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] Fix I/O port address for first floppy controller on x86_

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Fix I/O port address for first floppy controller on x86_64.
From: Xen patchbot -unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Mon, 20 Feb 2006 20:26:08 +0000
Delivery-date: Mon, 20 Feb 2006 20:40:20 +0000
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/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/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 cl349@xxxxxxxxxxxxxxxxxxxx
# Node ID 57af6b1cfa3a9cf55fa71e6d3fc106b320a21ae5
# Parent  0e9a0a469c6bec37a5b510a6d39500b022a3f06f
Fix I/O port address for first floppy controller on x86_64.
As a consequence, some of the i386 changes over native code need to also be
added to x86-64.

From: Jan Beulich <JBeulich@xxxxxxxxxx>
Signed-off-by: Christian Limpach <Christian.Limpach@xxxxxxxxxxxx>

diff -r 0e9a0a469c6b -r 57af6b1cfa3a 
linux-2.6-xen-sparse/include/asm-x86_64/mach-xen/asm/floppy.h
--- a/linux-2.6-xen-sparse/include/asm-x86_64/mach-xen/asm/floppy.h     Mon Feb 
20 17:34:21 2006
+++ b/linux-2.6-xen-sparse/include/asm-x86_64/mach-xen/asm/floppy.h     Mon Feb 
20 17:59:41 2006
@@ -14,7 +14,6 @@
 
 #include <linux/vmalloc.h>
 
-
 /*
  * The DMA channel used by the floppy controller cannot access data at
  * addresses >= 16MB
@@ -25,8 +24,6 @@
  */
 #define _CROSS_64KB(a,s,vdma) \
 (!(vdma) && ((unsigned long)(a)/K_64 != ((unsigned long)(a) + (s) - 1) / K_64))
-
-#include <linux/vmalloc.h>
 
 /* XEN: Hit DMA paths on the head. This trick from asm-m68k/floppy.h. */
 #include <asm/dma.h>
@@ -43,8 +40,12 @@
 #define fd_disable_irq()        disable_irq(FLOPPY_IRQ)
 #define fd_free_irq()          free_irq(FLOPPY_IRQ, NULL)
 #define fd_get_dma_residue()    vdma_get_dma_residue(FLOPPY_DMA)
-#define fd_dma_mem_alloc(size) vdma_mem_alloc(size)
-#define fd_dma_mem_free(addr, size) vdma_mem_free(addr, size) 
+/*
+ * Do not use vmalloc/vfree: floppy_release_irq_and_dma() gets called from
+ * softirq context via motor_off_callback. A generic bug we happen to trigger.
+ */
+#define fd_dma_mem_alloc(size) __get_free_pages(GFP_KERNEL, get_order(size))
+#define fd_dma_mem_free(addr, size) free_pages(addr, get_order(size))
 #define fd_dma_setup(addr, size, mode, io) vdma_dma_setup(addr, size, mode, io)
 
 static int virtual_dma_count;
@@ -137,7 +138,7 @@
                                           "floppy", NULL);
 }
 
-
+#if 0
 static unsigned long vdma_mem_alloc(unsigned long size)
 {
        return (unsigned long) vmalloc(size);
@@ -148,6 +149,7 @@
 {
        vfree((void *)addr);
 }
+#endif
 
 static int vdma_dma_setup(char *addr, unsigned long size, int mode, int io)
 {
@@ -168,7 +170,7 @@
 {
        use_virtual_dma = 1;
        can_use_virtual_dma = 1;
-       return 0x340;
+       return 0x3f0;
 }
 
 /*

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Fix I/O port address for first floppy controller on x86_64., Xen patchbot -unstable <=