From: Thiemo Seufer <ths@networkno.de>
To: "J. Mayer" <l_indien@magic.fr>
Cc: qemu-devel@nongnu.org
Subject: Re: IRQ handling (was [Qemu-devel] qemu Makefile.target vl.h hw/acpi.c hw/adlib.c ...)
Date: Sun, 8 Apr 2007 15:41:03 +0100 [thread overview]
Message-ID: <20070408144103.GM21953@networkno.de> (raw)
In-Reply-To: <1176018595.1516.115.camel@rapid>
J. Mayer wrote:
> On Sun, 2007-04-08 at 01:04 +0100, Thiemo Seufer wrote:
> > J. Mayer wrote:
> > [snip]
> > > To give you an real example why arbitrary limits are not acceptable AT
> > > ALL: I know an embedded Mips device (widely used !) with 2 CPU, 8 PIC
> > > and about 500 IRQ sources.
> >
> > Care to tell which one this is?
>
> I'm sorry, I'm no sure I can (NDA rules....).
> Let's say it's a chips used in some consumer electronics products.
>
> > > How can you even pretend add a limited
> > > structure in the CPUState structure when this is exactly the kind of
> > > device some people want to emulate in Qemu ? Your concept is completely
> > > broken, you have to admit it. You can never put peripheral informations
> > > in the CPUState structure.
> >
> > At least for MIPS it makes sense to put the CPU-internal controller
> > in exactly that place.
>
> It does not. If you look well, the IRQ controller is not in the CPU.
> Only the exception are managed in the CPU. The "internal" IRQ controller
> is a peripheral device located in the CP0.
It is not a peripheral but an integral part of any MIPS-compatible CPU.
The architecture allows since MIPS{32,64}R2 to optionally externalize
interupts (the so-called VEIC mode), but even those devices have to
implement the traditional "compatibility mode" interrupt handling.
This is spelt out e.g. in MD00091, page 32, as available from
http://www.mips.com/products/resource_library/product_materials/
> OK, the CP0 is tightly
> coupled to the CPU so it's easier to consider it as part of the CPU,
> when emulating it. But it seems like you could imagine a MIPS CPU
> without a CP0 coprocessor (even if it will never happen in the real
> world), no ?
No. Since MIPS{32,64}R2 the CP0 is standardized and a mandatory part of
a MIPS compatible CPU.
> The problem is also: what does this patch adds, but complexity and
> arbitrary limitations ?
For MIPS it adds an abstraction layer between the interrupt controller
and the CP0 registers which will be useful to implement support for
SMP devices.
> What do you need to route an IRQ ?
> -> A peripheral destination
> What we got now ?
> -> a callback with 3 parameters: an opaque, a PIN (the n_IRQ) and a
> state
A pin number doesn't look like a reasonable abstraction for a packetized
interrupt on an interconnection fabric (like it is used on e.g O2000).
It may do for the machines we currently emulate, though.
Thiemo
next prev parent reply other threads:[~2007-04-08 14:47 UTC|newest]
Thread overview: 50+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-07 18:14 [Qemu-devel] qemu Makefile.target vl.h hw/acpi.c hw/adlib.c Paul Brook
2007-04-07 18:32 ` J. Mayer
2007-04-07 19:10 ` Paul Brook
2007-04-07 19:32 ` Blue Swirl
2007-04-07 19:46 ` Paul Brook
2007-04-07 20:28 ` J. Mayer
2007-04-07 20:45 ` Paul Brook
2007-04-07 22:18 ` J. Mayer
2007-04-07 22:49 ` Thiemo Seufer
2007-04-07 23:13 ` Paul Brook
2007-04-07 23:54 ` J. Mayer
2007-04-08 0:04 ` Thiemo Seufer
2007-04-08 7:49 ` IRQ handling (was [Qemu-devel] qemu Makefile.target vl.h hw/acpi.c hw/adlib.c ...) J. Mayer
2007-04-08 8:38 ` J. Mayer
2007-04-08 14:41 ` Thiemo Seufer [this message]
2007-04-08 16:31 ` J. Mayer
2007-04-08 20:43 ` QEMU Automated Testing " Natalia Portillo
2007-04-08 22:07 ` Eduardo Felipe
2007-04-08 23:53 ` Natalia Portillo
2007-04-09 9:36 ` Eduardo Felipe
2007-04-09 21:19 ` Rob Landley
2007-04-10 11:24 ` Jamie Lokier
2007-04-10 12:00 ` Pierre d'Herbemont
2007-07-27 14:21 ` Dan Shearer
2007-07-27 14:29 ` Anthony Liguori
2007-07-27 14:34 ` Dan Shearer
2007-07-27 14:58 ` Sunil Amitkumar Janki
2007-07-27 15:12 ` Dan Shearer
2007-07-27 15:50 ` Sunil Amitkumar Janki
2007-07-27 16:04 ` Dan Shearer
2007-07-27 16:50 ` Jan Marten Simons
2007-07-27 18:51 ` Thiemo Seufer
2007-07-27 19:55 ` Sunil Amitkumar Janki
2007-07-28 10:17 ` Thiemo Seufer
2007-07-28 11:41 ` Sunil Amitkumar Janki
2007-07-28 12:43 ` [Qemu-devel] Re: QEMU Automated Testing Stefan Weil
2007-07-27 18:54 ` QEMU Automated Testing (was [Qemu-devel] qemu Makefile.target vl.h hw/acpi.c hw/adlib.c ...) Andreas Färber
2007-07-28 10:36 ` Thiemo Seufer
2007-07-29 15:31 ` Andreas Färber
2007-04-10 11:17 ` IRQ handling " Jamie Lokier
2007-04-09 0:41 ` [Qemu-devel] Re: IRQ handling Paul Brook
2007-04-09 11:11 ` J. Mayer
2007-04-09 13:58 ` Paul Brook
2007-04-09 14:56 ` J. Mayer
2007-04-09 16:57 ` Paul Brook
2007-04-07 23:26 ` [Qemu-devel] qemu Makefile.target vl.h hw/acpi.c hw/adlib.c Fabrice Bellard
2007-04-08 13:06 ` Wang Cheng Yeh
2007-04-08 13:56 ` Thiemo Seufer
2007-04-08 22:45 ` Paul Brook
2007-04-07 21:20 ` Thiemo Seufer
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=20070408144103.GM21953@networkno.de \
--to=ths@networkno.de \
--cc=l_indien@magic.fr \
--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).