From: Leon Alrae <leon.alrae@imgtec.com>
To: Yongbok Kim <yongbok.kim@imgtec.com>, qemu-devel@nongnu.org
Cc: pbonzini@redhat.com, afaerber@suse.de, aurelien@aurel32.net
Subject: Re: [Qemu-devel] [PATCH 4/4] mips: add gic support to malta
Date: Wed, 21 Oct 2015 16:53:36 +0100 [thread overview]
Message-ID: <5627B500.5030006@imgtec.com> (raw)
In-Reply-To: <1444953129-35040-5-git-send-email-yongbok.kim@imgtec.com>
On 16/10/15 00:52, Yongbok Kim wrote:
> /*
> * We have a circular dependency problem: pci_bus depends on isa_irq,
> * isa_irq is provided by i8259, i8259 depends on ISA, ISA depends
> @@ -1155,7 +1218,11 @@ void mips_malta_init(MachineState *machine)
>
> /* Interrupt controller */
> /* The 8259 is attached to the MIPS CPU INT0 pin, ie interrupt 2 */
> - s->i8259 = i8259_init(isa_bus, env->irq[2]);
> + if (env->gic_irqs) {
> + s->i8259 = i8259_init(isa_bus, env->gic_irqs[3]);
Probably s->gic.gic_irqs[3].irq should be used here.
BTW I think "gic_irqs" can be replaced with a better name, something
like "irq_state".
> + } else {
> + s->i8259 = i8259_init(isa_bus, env->irq[2]);
> + }
>
> isa_bus_irqs(isa_bus, s->i8259);
> pci_piix4_ide_init(pci_bus, hd, piix4_devfn + 1);
> @@ -1209,7 +1276,7 @@ static void mips_malta_machine_init(MachineClass *mc)
> {
> mc->desc = "MIPS Malta Core LV";
> mc->init = mips_malta_init;
> - mc->max_cpus = 16;
> + mc->max_cpus = 32;
> mc->is_default = 1;
> }
>
> diff --git a/target-mips/cpu.h b/target-mips/cpu.h
> index 639ef37..fdd5643 100644
> --- a/target-mips/cpu.h
> +++ b/target-mips/cpu.h
> @@ -594,6 +594,7 @@ struct CPUMIPSState {
>
> const mips_def_t *cpu_model;
> void *irq[8];
> + void **gic_irqs;
I don't think CPUMIPSState need any information about gic external
interrupts.
Leon
> QEMUTimer *timer; /* Internal timer */
> };
>
>
next prev parent reply other threads:[~2015-10-21 15:53 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-15 23:52 [Qemu-devel] [PATCH 0/4] mips: add Global Interrupt Controller Yongbok Kim
2015-10-15 23:52 ` [Qemu-devel] [PATCH 1/4] target-mips: add CMGCRBase register Yongbok Kim
2015-10-19 15:07 ` Leon Alrae
2015-10-15 23:52 ` [Qemu-devel] [PATCH 2/4] mips: add Global Config Register block (part) Yongbok Kim
2015-10-15 23:52 ` [Qemu-devel] [PATCH 3/4] mips: add Global Interrupt Controller Yongbok Kim
2015-10-21 15:49 ` Leon Alrae
2015-10-15 23:52 ` [Qemu-devel] [PATCH 4/4] mips: add gic support to malta Yongbok Kim
2015-10-21 15:53 ` Leon Alrae [this message]
2015-10-19 14:36 ` [Qemu-devel] [PATCH 0/4] mips: add Global Interrupt Controller James Hogan
2015-10-19 14:58 ` Yongbok Kim
2015-10-21 16:01 ` Peter Maydell
2015-10-21 16:28 ` Yongbok Kim
2015-10-21 20:13 ` Peter Maydell
2015-10-21 16:36 ` Peter Crosthwaite
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=5627B500.5030006@imgtec.com \
--to=leon.alrae@imgtec.com \
--cc=afaerber@suse.de \
--cc=aurelien@aurel32.net \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=yongbok.kim@imgtec.com \
/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.