[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] x86: don't build guest-walk code without HVM and SHADOW_PAGING



>>> On 05.10.18 at 12:32, <andrew.cooper3@xxxxxxxxxx> wrote:
> On 05/10/18 11:20, Jan Beulich wrote:
>> It's dead code in that case.
>>
>> We could go further, as we don't really need the 2- and 3-level walk
>> code in PV mode, but to drop their compilation requires quite a bit of
>> disentangling of shadow mode code.
>>
>> Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
>>
>> --- a/xen/arch/x86/mm/Makefile
>> +++ b/xen/arch/x86/mm/Makefile
>> @@ -2,9 +2,8 @@ subdir-y += shadow
>>  subdir-$(CONFIG_HVM) += hap
>>  
>>  obj-$(CONFIG_HVM) += altp2m.o
>> -obj-y += guest_walk_2.o
>> -obj-y += guest_walk_3.o
>> -obj-y += guest_walk_4.o
>> +obj-$(CONFIG_HVM) += guest_walk_2.o guest_walk_3.o guest_walk_4.o
>> +obj-$(CONFIG_SHADOW_PAGING) += guest_walk_2.o guest_walk_3.o guest_walk_4.o
>>  obj-$(CONFIG_MEM_ACCESS) += mem_access.o
>>  obj-y += mem_paging.o
>>  obj-y += mem_sharing.o
> 
> I'm fine with the change in principle.  How about
> 
> obj-gw := guest_walk_2.o guest_walk_3.o guest_walk_4.o
> 
> obj-$(CONFIG_HVM) += obj-gw
> obj-$(CONFIG_SHADOW_PAGING) += obj-gw
> 
> to avoid duplicating the guest_walk* list?

I had it that way, and I dropped it specifically in order to later
just touch the shadow related line, when only the 4-level walk
is going to remain needed on !HVM configs.

> Either way, Acked-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>

Thanks, Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.