All of lore.kernel.org
 help / color / mirror / Atom feed
From: Aurelien Jarno <aurelien@aurel32.net>
To: qemu-devel@nongnu.org
Cc: linux-mips@linux-mips.org
Subject: [PATCH] QEMU: IDE support for mips
Date: Tue, 24 Oct 2006 18:41:28 +0200	[thread overview]
Message-ID: <20061024164128.GA8249@bode.aurel32.net> (raw)

[-- Attachment #1: Type: text/plain, Size: 525 bytes --]

Hi,

The attached patch adds IDE support on the mips target. It has been
written by Daniel Jacobowitz, and posted on linux-mips@linux-mips.org,
along with another patch. He told me it is ok to submit it.

I am using it for a week, it works correctly. Could you apply it? 

Thanks,
Aurelien


-- 
  .''`.  Aurelien Jarno	            | GPG: 1024D/F1BCDB73
 : :' :  Debian developer           | Electrical Engineer
 `. `'   aurel32@debian.org         | aurelien@aurel32.net
   `-    people.debian.org/~aurel32 | www.aurel32.net

[-- Attachment #2: mips-qemu-ide.patch --]
[-- Type: text/plain, Size: 1758 bytes --]

Index: Makefile.target
===================================================================
RCS file: /sources/qemu/qemu/Makefile.target,v
retrieving revision 1.130
diff -u -d -p -r1.130 Makefile.target
--- Makefile.target	22 Oct 2006 00:18:54 -0000	1.130
+++ Makefile.target	24 Oct 2006 04:58:51 -0000
@@ -357,8 +357,8 @@ VL_OBJS+= grackle_pci.o prep_pci.o unin_
 DEFINES += -DHAS_AUDIO
 endif
 ifeq ($(TARGET_ARCH), mips)
-VL_OBJS+= mips_r4k.o dma.o vga.o serial.o i8254.o i8259.o
-#VL_OBJS+= #ide.o pckbd.o fdc.o m48t59.o
+VL_OBJS+= mips_r4k.o dma.o vga.o serial.o i8254.o i8259.o ide.o
+#VL_OBJS+= #pckbd.o fdc.o m48t59.o
 endif
 ifeq ($(TARGET_BASE_ARCH), sparc)
 ifeq ($(TARGET_ARCH), sparc64)
Index: hw/mips_r4k.c
===================================================================
RCS file: /sources/qemu/qemu/hw/mips_r4k.c,v
retrieving revision 1.20
diff -u -d -p -r1.20 mips_r4k.c
--- hw/mips_r4k.c	18 Sep 2006 01:15:29 -0000	1.20
+++ hw/mips_r4k.c	24 Oct 2006 04:58:51 -0000
@@ -7,6 +7,10 @@
 
 #define VIRT_TO_PHYS_ADDEND (-0x80000000LL)
 
+static const int ide_iobase[2] = { 0x1f0, 0x170 };
+static const int ide_iobase2[2] = { 0x3f6, 0x376 };
+static const int ide_irq[2] = { 14, 15 };
+
 extern FILE *logfile;
 
 static PITState *pit;
@@ -118,6 +122,7 @@ void mips_r4k_init (int ram_size, int vg
     int ret;
     CPUState *env;
     long kernel_size;
+    int i;
 
     env = cpu_init();
     register_savevm("cpu", 0, 3, cpu_save, cpu_load, env);
@@ -198,6 +203,10 @@ void mips_r4k_init (int ram_size, int vg
             exit (1);
         }
     }
+
+    for(i = 0; i < 2; i++)
+        isa_ide_init(ide_iobase[i], ide_iobase2[i], ide_irq[i],
+                     bs_table[2 * i], bs_table[2 * i + 1]);
 }
 
 QEMUMachine mips_machine = {

WARNING: multiple messages have this Message-ID (diff)
From: Aurelien Jarno <aurelien@aurel32.net>
To: qemu-devel@nongnu.org
Cc: linux-mips@linux-mips.org
Subject: [Qemu-devel] [PATCH] QEMU: IDE support for mips
Date: Tue, 24 Oct 2006 18:41:28 +0200	[thread overview]
Message-ID: <20061024164128.GA8249@bode.aurel32.net> (raw)

[-- Attachment #1: Type: text/plain, Size: 525 bytes --]

Hi,

The attached patch adds IDE support on the mips target. It has been
written by Daniel Jacobowitz, and posted on linux-mips@linux-mips.org,
along with another patch. He told me it is ok to submit it.

I am using it for a week, it works correctly. Could you apply it? 

Thanks,
Aurelien


-- 
  .''`.  Aurelien Jarno	            | GPG: 1024D/F1BCDB73
 : :' :  Debian developer           | Electrical Engineer
 `. `'   aurel32@debian.org         | aurelien@aurel32.net
   `-    people.debian.org/~aurel32 | www.aurel32.net

[-- Attachment #2: mips-qemu-ide.patch --]
[-- Type: text/plain, Size: 1758 bytes --]

Index: Makefile.target
===================================================================
RCS file: /sources/qemu/qemu/Makefile.target,v
retrieving revision 1.130
diff -u -d -p -r1.130 Makefile.target
--- Makefile.target	22 Oct 2006 00:18:54 -0000	1.130
+++ Makefile.target	24 Oct 2006 04:58:51 -0000
@@ -357,8 +357,8 @@ VL_OBJS+= grackle_pci.o prep_pci.o unin_
 DEFINES += -DHAS_AUDIO
 endif
 ifeq ($(TARGET_ARCH), mips)
-VL_OBJS+= mips_r4k.o dma.o vga.o serial.o i8254.o i8259.o
-#VL_OBJS+= #ide.o pckbd.o fdc.o m48t59.o
+VL_OBJS+= mips_r4k.o dma.o vga.o serial.o i8254.o i8259.o ide.o
+#VL_OBJS+= #pckbd.o fdc.o m48t59.o
 endif
 ifeq ($(TARGET_BASE_ARCH), sparc)
 ifeq ($(TARGET_ARCH), sparc64)
Index: hw/mips_r4k.c
===================================================================
RCS file: /sources/qemu/qemu/hw/mips_r4k.c,v
retrieving revision 1.20
diff -u -d -p -r1.20 mips_r4k.c
--- hw/mips_r4k.c	18 Sep 2006 01:15:29 -0000	1.20
+++ hw/mips_r4k.c	24 Oct 2006 04:58:51 -0000
@@ -7,6 +7,10 @@
 
 #define VIRT_TO_PHYS_ADDEND (-0x80000000LL)
 
+static const int ide_iobase[2] = { 0x1f0, 0x170 };
+static const int ide_iobase2[2] = { 0x3f6, 0x376 };
+static const int ide_irq[2] = { 14, 15 };
+
 extern FILE *logfile;
 
 static PITState *pit;
@@ -118,6 +122,7 @@ void mips_r4k_init (int ram_size, int vg
     int ret;
     CPUState *env;
     long kernel_size;
+    int i;
 
     env = cpu_init();
     register_savevm("cpu", 0, 3, cpu_save, cpu_load, env);
@@ -198,6 +203,10 @@ void mips_r4k_init (int ram_size, int vg
             exit (1);
         }
     }
+
+    for(i = 0; i < 2; i++)
+        isa_ide_init(ide_iobase[i], ide_iobase2[i], ide_irq[i],
+                     bs_table[2 * i], bs_table[2 * i + 1]);
 }
 
 QEMUMachine mips_machine = {

             reply	other threads:[~2006-10-24 16:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-10-24 16:41 Aurelien Jarno [this message]
2006-10-24 16:41 ` [Qemu-devel] [PATCH] QEMU: IDE support for mips Aurelien Jarno

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20061024164128.GA8249@bode.aurel32.net \
    --to=aurelien@aurel32.net \
    --cc=linux-mips@linux-mips.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.