Jan Beulich
2006-Feb-17 10:38 UTC
[Xen-devel] [PATCH] x86-64 linux: another adjustment to vmalloc fault handling
Changeset 8847 improved things, but doesn''t generally work. We namely experienced problems (when we originally tried the same change) with accesses to machine_to_phys_mapping, which (in mfn_to_pfn) is specifically allowed to fault. Hence there should not be attempts to fix up faults within the hypervisor range (as for any page table entries obtained there no m2p translation exists for the guest, resulting in bogus physical addresses getting used for further fault processing, frequently leading to nested faults). Jan _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Keir Fraser
2006-Feb-17 11:05 UTC
Re: [Xen-devel] [PATCH] x86-64 linux: another adjustment to vmalloc fault handling
On 17 Feb 2006, at 10:38, Jan Beulich wrote:> Changeset 8847 improved things, but doesn''t generally work. We namely > experienced problems (when we originally tried the > same change) with accesses to machine_to_phys_mapping, which (in > mfn_to_pfn) is specifically allowed to fault. Hence > there should not be attempts to fix up faults within the hypervisor > range (as for any page table entries obtained there > no m2p translation exists for the guest, resulting in bogus physical > addresses getting used for further fault > processing, frequently leading to nested faults).But machine_to_phys_mapping == 0xffff800000000000 while PAGE_OFFSET == HYPERVISOR_VIRT_END == 0xffff880000000000. So the patch doesn''t really change anything, and machine_to_phys_mapping lives below both PAGE_OFFSET and HYPERVISOR_VIRT_END anyway. -- Keir _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Jan Beulich
2006-Feb-17 11:22 UTC
Re: [Xen-devel] [PATCH] x86-64 linux: another adjustment to vmalloc fault handling
>>> Keir Fraser <Keir.Fraser@cl.cam.ac.uk> 17.02.06 12:05:13 >>> > >On 17 Feb 2006, at 10:38, Jan Beulich wrote: > >> Changeset 8847 improved things, but doesn''t generally work. We namely >> experienced problems (when we originally tried the >> same change) with accesses to machine_to_phys_mapping, which (in >> mfn_to_pfn) is specifically allowed to fault. Hence >> there should not be attempts to fix up faults within the hypervisor >> range (as for any page table entries obtained there >> no m2p translation exists for the guest, resulting in bogus physical >> addresses getting used for further fault >> processing, frequently leading to nested faults). > >But machine_to_phys_mapping == 0xffff800000000000 while >PAGE_OFFSET == HYPERVISOR_VIRT_END == 0xffff880000000000. > >So the patch doesn''t really change anything, and >machine_to_phys_mapping lives below both PAGE_OFFSET and >HYPERVISOR_VIRT_END anyway.Oh, I''m sorry, I mixed up TASK_SIZE64 and PAGE_OFFSET (we had used the former initially, because it''s being done similarly on i386). Between PAGE_OFFSET and HYPERVISOR_VIRT_END I just found using the latter here more correct, as PAGE_OFFSET is not required to live at HYPERVISOR_VIRT_END, but that should always be the boundary for checking. Jan _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel