From: "Blue Swirl" <blauwirbel@gmail.com>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH]: add leon target
Date: Wed, 7 Jan 2009 19:03:08 +0200 [thread overview]
Message-ID: <f43fc5580901070903r9b2a09i475cb86d2a6e5618@mail.gmail.com> (raw)
In-Reply-To: <20090107102439.GA15209@ulanbator.act-europe.fr>
On 1/7/09, Tristan Gingold <gingold@adacore.com> wrote:
> Hi,
>
> this patch adds a new target: leon which is an open source sparc v8 variant.
Thanks for the patch. Is there any way to test the system, rom images
etc? Any system level docs?
Do you think it would be useful to port OpenBIOS to the system?
> The cpu itself implements the v8 architecture so there is nothing to change.
> However the devices are different and in particular the interrupt controller.
>
> To handle different interrupt controllers, I added a new field in
> CPUSPARCState like it is done on PowerPC.
I have a feeling that this should be handled some other way but I
don't know how yet. CPU emulation should not know about boards.
> Comments are welcome,
> Tristan.
Maybe the leon.c should be split, each device in a separate file.
Though I guess the devices are so unique that they won't be used
elsewhere.
> +++ target-sparc/op_helper.c (working copy)
> @@ -2995,6 +2995,21 @@
> env->pc = env->tbr;
> env->npc = env->pc + 4;
> env->exception_index = 0;
> +
> + switch (env->intctl) {
> + case intctl_sun4c:
> + case intctl_sun4m:
> +#if !defined(CONFIG_USER_ONLY)
> + cpu_check_irqs(env);
> +#endif
> + break;
> + case intctl_leon2:
> + if ((intno & ~15) == TT_EXTINT)
> + leon2_intctl_ack (env, intno);
This breaks linux-user compilation, the whole switch should be enclosed in
#if !defined(CONFIG_USER_ONLY)
#endif
For extra bonus, you could implement the following:
- register device reset methods
- savevm/loadvm support
- pic_info, irq_info support
next prev parent reply other threads:[~2009-01-07 17:07 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-07 10:24 [Qemu-devel] [PATCH]: add leon target Tristan Gingold
2009-01-07 10:32 ` Jean-Christophe PLAGNIOL-VILLARD
2009-01-07 11:17 ` Tristan Gingold
2009-01-07 17:03 ` Blue Swirl [this message]
2009-01-08 8:53 ` Tristan Gingold
2009-01-08 10:01 ` Edgar E. Iglesias
2009-01-08 10:09 ` Tristan Gingold
2009-01-08 10:33 ` Edgar E. Iglesias
2009-01-08 10:43 ` Tristan Gingold
2009-01-08 11:10 ` Edgar E. Iglesias
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=f43fc5580901070903r9b2a09i475cb86d2a6e5618@mail.gmail.com \
--to=blauwirbel@gmail.com \
--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).