* [PATCH] xen/arm: Panic if we can't copy the DTB to dom0 memory
@ 2013-09-04 15:11 Julien Grall
2013-09-09 14:07 ` Ian Campbell
0 siblings, 1 reply; 2+ messages in thread
From: Julien Grall @ 2013-09-04 15:11 UTC (permalink / raw)
To: xen-devel; +Cc: patches, ian.campbell, Julien Grall, stefano.stabellini
Signed-off-by: Julien Grall <julien.grall@linaro.org>
---
xen/arch/arm/domain_build.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/xen/arch/arm/domain_build.c b/xen/arch/arm/domain_build.c
index 516d0df..0909996 100644
--- a/xen/arch/arm/domain_build.c
+++ b/xen/arch/arm/domain_build.c
@@ -824,11 +824,14 @@ static int prepare_dtb(struct domain *d, struct kernel_info *kinfo)
static void dtb_load(struct kernel_info *kinfo)
{
void * __user dtb_virt = (void * __user)(register_t)kinfo->dtb_paddr;
+ unsigned long rc;
printk("Loading dom0 DTB to 0x%"PRIpaddr"-0x%"PRIpaddr"\n",
kinfo->dtb_paddr, kinfo->dtb_paddr + fdt_totalsize(kinfo->fdt));
- raw_copy_to_guest(dtb_virt, kinfo->fdt, fdt_totalsize(kinfo->fdt));
+ rc = raw_copy_to_guest(dtb_virt, kinfo->fdt, fdt_totalsize(kinfo->fdt));
+ if ( rc != 0 )
+ panic("Unable to copy the DTB to dom0 memory (rc = %lu)\n", rc);
xfree(kinfo->fdt);
}
--
1.7.10.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] xen/arm: Panic if we can't copy the DTB to dom0 memory
2013-09-04 15:11 [PATCH] xen/arm: Panic if we can't copy the DTB to dom0 memory Julien Grall
@ 2013-09-09 14:07 ` Ian Campbell
0 siblings, 0 replies; 2+ messages in thread
From: Ian Campbell @ 2013-09-09 14:07 UTC (permalink / raw)
To: Julien Grall; +Cc: stefano.stabellini, patches, xen-devel
On Wed, 2013-09-04 at 16:11 +0100, Julien Grall wrote:
> Signed-off-by: Julien Grall <julien.grall@linaro.org>
Acked + Applied.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-09-09 14:07 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-09-04 15:11 [PATCH] xen/arm: Panic if we can't copy the DTB to dom0 memory Julien Grall
2013-09-09 14:07 ` Ian Campbell
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.