On Fri, 2006-04-21 at 15:04 +0900, Isaku Yamahata wrote:
> Hi Alex.
> What was the problem with the legacy VGA space?
Hi Isaku,
There are several problem as far as I can tell. First, what if the
system doesn't have legacy VGA? HP has several systems that might fall
into this category. We're assuming something is there that may not
exist, and we're also perhaps assuming a more complete legacy address
space than may exist. The next problem is that the MDT provided by the
platform should contain entries for the VGA space. If it does, then the
real and fabricate VGA ranges overlap in the MDT provided to dom0. I
believe HP zx1 systems report the 0xA0000 range as an MMIO range when
VGA is present. The Linux kernel does check the type of memory when
deciding whether to initialize VGA. If the 0xA0000 range is anything
other than conventional memory, we'll probe for VGA.
> In case !CONFIG_XEN_IA64_DOM0_VP, the MDT which xen arranges says
> to Linux that [0*MB, 1*MB] is usable.
> So Linux uses the area, however Linux VGA driver writes its space
> without any checks to check vga existance.
> It results in data corruption. (the check is done at very early stage
> of booting so that such corruption might not be a issue.)
Perhaps we simply need to replicate the platform MDT entries for
anything below 1MB and set these up for identity mapping. If the
platform doesn't report anything there, it will only be a 1MB hole in
the address space.
> I'm guessing that the following line should be fixed.
> The legacy vga area should be used by Linux at least.
> > MAKE_MD(EFI_LOADER_DATA,EFI_MEMORY_WB,0*MB,1*MB, 1);
>
>
> On the other hand in case CONFIG_XEN_IA64_DOM0_VP,
> you just commented out the following two lines.
> > MAKE_MD(EFI_LOADER_DATA,EFI_MEMORY_WB, 0 * MB, VGA_RAM_START, 1);
> > MAKE_MD(EFI_LOADER_DATA,EFI_MEMORY_WB, VGA_COLOURMAP_END, 1*MB, 1);
>
> Does it mean that the simulation of 1MB free memory at physical
> address zero is unnecessary?
I would say yes. I think we should copy the platform MDT entries for
anything below 1MB. I'm afraid that some platforms may not have MDT
entries describing legacy spaces, or else I would suggest a smarter
approach to reclaim that 1MB if VGA does not exist. Thanks,
Alex
--
Alex Williamson HP Linux & Open Source Lab
_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel
|