On Mon, Dec 29, 2014 at 05:55:28PM +0100, Roger Pau Monné wrote:
> El 29/12/14 a les 12.41, Roger Pau Monné ha escrit:
> > Hello,
> > 
> > Sorry for not noticing this earlier, I've been without a computer for
> > some days. Do you get a panic message, or the system just freezes?
> > 
> > Can you please post the full boot output with boot_verbose enabled?
> 
> I'm not able to reproduce the problem with Qemu and OVMF, and I don't
> have any box right now that uses UEFI.
> 
> I'm guessing that this is due to some memory reservation conflict, so
> I'm attaching a patch that should help diagnose it.

You'll probably want to nuke RF_ACTIVE so the resources are marked
as taken but in case of vt_efifb(4), the memory isn't mapped twice.
I don't not know whether the latter actually is a problem for x86,
though, it'll likely at least replace the VM_MEMATTR_WRITE_COMBINING
mapping done in vt_efifb_remap(). Removing RF_ACTIVE in turn might
not be sufficient for the Xen bits to mark the resource as reserved,
this should be fixed in the FreeBSD/Xen code then, however.
Also end = size - 1, see the attached patch.

Marius

Index: dev/vt/hw/efifb/efifb.c
===================================================================
--- dev/vt/hw/efifb/efifb.c	(revision 276343)
+++ dev/vt/hw/efifb/efifb.c	(working copy)
@@ -211,8 +211,8 @@
 	res_id = 0;
 	pseudo_phys_res = bus_alloc_resource(dev, SYS_RES_MEMORY,
 	    &res_id, local_info.fb_pbase,
-	    local_info.fb_pbase + local_info.fb_size,
-	    local_info.fb_size, RF_ACTIVE);
+	    local_info.fb_pbase + local_info.fb_size - 1,
+	    local_info.fb_size, 0);
 	if (pseudo_phys_res == NULL)
 		panic("Unable to reserve vt_efifb memory");
 	return (0);
Index: dev/vt/hw/vga/vt_vga.c
===================================================================
--- dev/vt/hw/vga/vt_vga.c	(revision 276343)
+++ dev/vt/hw/vga/vt_vga.c	(working copy)
@@ -1275,8 +1275,8 @@
 
 	res_id = 0;
 	pseudo_phys_res = bus_alloc_resource(dev, SYS_RES_MEMORY,
-	    &res_id, VGA_MEM_BASE, VGA_MEM_BASE + VGA_MEM_SIZE,
-	    VGA_MEM_SIZE, RF_ACTIVE);
+	    &res_id, VGA_MEM_BASE, VGA_MEM_BASE + VGA_MEM_SIZE - 1,
+	    VGA_MEM_SIZE, 0);
 	if (pseudo_phys_res == NULL)
 		panic("Unable to reserve vt_vga memory");
 	return (0);
_______________________________________________
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"

Reply via email to