Ian Campbell
2013-Jul-23 17:06 UTC
[PATCH] xen: arm: panic if we cannot build dom0''s p2m.
From: Ian Campbell <ian.campbell@citrix.com> Signed-off-by: Ian Campbell <ian.campbell@citrix.com> --- xen/arch/arm/domain_build.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/xen/arch/arm/domain_build.c b/xen/arch/arm/domain_build.c index 155b436..056c9df 100644 --- a/xen/arch/arm/domain_build.c +++ b/xen/arch/arm/domain_build.c @@ -121,7 +121,8 @@ static int set_memory_reg(struct domain *d, struct kernel_info *kinfo, device_tree_set_reg(&new_cell, address_cells, size_cells, start, size); printk("Populate P2M %#"PRIx64"->%#"PRIx64"\n", start, start + size); - p2m_populate_ram(d, start, start + size); + if ( p2m_populate_ram(d, start, start + size) < 0 ) + panic("Failed to populate P2M\n"); kinfo->mem.bank[kinfo->mem.nr_banks].start = start; kinfo->mem.bank[kinfo->mem.nr_banks].size = size; kinfo->mem.nr_banks++; -- 1.8.3.2
Julien Grall
2013-Jul-23 17:12 UTC
Re: [PATCH] xen: arm: panic if we cannot build dom0''s p2m.
On 07/23/2013 06:06 PM, Ian Campbell wrote:> From: Ian Campbell <ian.campbell@citrix.com> > > Signed-off-by: Ian Campbell <ian.campbell@citrix.com>Acked-by: Julien Grall <julien.grall@linaro.org>> --- > xen/arch/arm/domain_build.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/xen/arch/arm/domain_build.c b/xen/arch/arm/domain_build.c > index 155b436..056c9df 100644 > --- a/xen/arch/arm/domain_build.c > +++ b/xen/arch/arm/domain_build.c > @@ -121,7 +121,8 @@ static int set_memory_reg(struct domain *d, struct kernel_info *kinfo, > device_tree_set_reg(&new_cell, address_cells, size_cells, start, size); > > printk("Populate P2M %#"PRIx64"->%#"PRIx64"\n", start, start + size); > - p2m_populate_ram(d, start, start + size); > + if ( p2m_populate_ram(d, start, start + size) < 0 ) > + panic("Failed to populate P2M\n"); > kinfo->mem.bank[kinfo->mem.nr_banks].start = start; > kinfo->mem.bank[kinfo->mem.nr_banks].size = size; > kinfo->mem.nr_banks++; >
Ian Campbell
2013-Jul-29 15:58 UTC
Re: [PATCH] xen: arm: panic if we cannot build dom0''s p2m.
On Tue, 2013-07-23 at 18:12 +0100, Julien Grall wrote:> On 07/23/2013 06:06 PM, Ian Campbell wrote: > > From: Ian Campbell <ian.campbell@citrix.com> > > > > Signed-off-by: Ian Campbell <ian.campbell@citrix.com> > Acked-by: Julien Grall <julien.grall@linaro.org>Thanks, applied.> > --- > > xen/arch/arm/domain_build.c | 3 ++- > > 1 file changed, 2 insertions(+), 1 deletion(-) > > > > diff --git a/xen/arch/arm/domain_build.c b/xen/arch/arm/domain_build.c > > index 155b436..056c9df 100644 > > --- a/xen/arch/arm/domain_build.c > > +++ b/xen/arch/arm/domain_build.c > > @@ -121,7 +121,8 @@ static int set_memory_reg(struct domain *d, struct kernel_info *kinfo, > > device_tree_set_reg(&new_cell, address_cells, size_cells, start, size); > > > > printk("Populate P2M %#"PRIx64"->%#"PRIx64"\n", start, start + size); > > - p2m_populate_ram(d, start, start + size); > > + if ( p2m_populate_ram(d, start, start + size) < 0 ) > > + panic("Failed to populate P2M\n"); > > kinfo->mem.bank[kinfo->mem.nr_banks].start = start; > > kinfo->mem.bank[kinfo->mem.nr_banks].size = size; > > kinfo->mem.nr_banks++; > > > > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xen.org > http://lists.xen.org/xen-devel