qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Ralf Baechle <ralf@linux-mips.org>
To: Fabrice Bellard <fabrice@bellard.org>, qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH 2/3] Add i8259 PIT to MIPS
Date: Mon, 15 Aug 2005 09:56:31 +0100	[thread overview]
Message-ID: <20050815085631.GA7516@linux-mips.org> (raw)

Add i8259 PIT to the MIPS configuration.  Not that the counter / compare
interrupt isn't nicer but the i8259 unfortunately a common peripheral in
MIPS systems and so it's probably a piece of code want just in case.

 Makefile.target |    4 ++--
 hw/mips_r4k.c   |    3 +++
 2 files changed, 5 insertions(+), 2 deletions(-)

Index: qemu-mips/hw/mips_r4k.c
===================================================================
--- qemu-mips.orig/hw/mips_r4k.c
+++ qemu-mips/hw/mips_r4k.c
@@ -7,6 +7,8 @@
 
 extern FILE *logfile;
 
+static PITState *pit;
+
 static void pic_irq_request(void *opaque, int level)
 {
     if (level) {
@@ -242,6 +244,7 @@ void mips_r4k_init (int ram_size, int vg
     isa_mem_base = 0x10000000;
 
     isa_pic = pic_init(pic_irq_request, cpu_single_env);
+    pit = pit_init(0x40, 0);
     serial_init(0x3f8, 4, serial_hds[0]);
     vga_initialize(NULL, ds, phys_ram_base + ram_size, ram_size, 
                    vga_ram_size, 0, 0);
Index: qemu-mips/Makefile.target
===================================================================
--- qemu-mips.orig/Makefile.target
+++ qemu-mips/Makefile.target
@@ -295,8 +295,8 @@ VL_OBJS+= mc146818rtc.o serial.o i8259.o
 VL_OBJS+= ppc_prep.o ppc_chrp.o cuda.o adb.o openpic.o heathrow_pic.o mixeng.o
 endif
 ifeq ($(TARGET_ARCH), mips)
-VL_OBJS+= mips_r4k.o dma.o vga.o serial.o ne2000.o i8259.o
-#VL_OBJS+= #ide.o pckbd.o i8254.o fdc.o m48t59.o
+VL_OBJS+= mips_r4k.o dma.o vga.o serial.o ne2000.o i8254.o i8259.o
+#VL_OBJS+= #ide.o pckbd.o fdc.o m48t59.o
 endif
 ifeq ($(TARGET_BASE_ARCH), sparc)
 ifeq ($(TARGET_ARCH), sparc64)

                 reply	other threads:[~2005-08-15  9:02 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20050815085631.GA7516@linux-mips.org \
    --to=ralf@linux-mips.org \
    --cc=fabrice@bellard.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).