From: Julien Grall <julien.grall@linaro.org>
To: xen-devel@lists.xenproject.org
Cc: Julien Grall <julien.grall@linaro.org>,
stefano.stabellini@citrix.com, ian.campbell@citrix.com,
time@xen.org, patches@linaro.org
Subject: [PATCH] xen/arm: gic: don't use dom0 variable in gicv_setup
Date: Tue, 19 Nov 2013 17:55:45 +0000 [thread overview]
Message-ID: <1384883745-28844-1-git-send-email-julien.grall@linaro.org> (raw)
The commit 99bf30a "xen: arm: define guest virtual platform in API headers"
modifies gicv_setup to either use harcoded addresses for guest or hardware
addresses for dom0. In the latter case, the variable dom0 is not yet
initialized. dom0 receives assignment by the return of domain_create which
calls gicv_setup.
Use the ID to know whether the domain is dom0 or not.
Signed-off-by: Julien Grall <julien.grall@linaro.org>
---
xen/arch/arm/gic.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/xen/arch/arm/gic.c b/xen/arch/arm/gic.c
index 3b1ef3a..d5ac770 100644
--- a/xen/arch/arm/gic.c
+++ b/xen/arch/arm/gic.c
@@ -881,7 +881,7 @@ int gicv_setup(struct domain *d)
* Domain 0 gets the hardware address.
* Guests get the virtual platform layout.
*/
- if ( d == dom0 )
+ if ( d->domain_id == 0 )
{
d->arch.vgic.dbase = gic.dbase;
d->arch.vgic.cbase = gic.cbase;
--
1.7.10.4
next reply other threads:[~2013-11-19 17:55 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-19 17:55 Julien Grall [this message]
2013-11-20 9:44 ` [PATCH] xen/arm: gic: don't use dom0 variable in gicv_setup Ian Campbell
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=1384883745-28844-1-git-send-email-julien.grall@linaro.org \
--to=julien.grall@linaro.org \
--cc=ian.campbell@citrix.com \
--cc=patches@linaro.org \
--cc=stefano.stabellini@citrix.com \
--cc=time@xen.org \
--cc=xen-devel@lists.xenproject.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).