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

Re: [PATCH] x86/shadow: fix build without PV or HVM


  • To: <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Roger Pau Monné <roger.pau@xxxxxxxxxx>
  • Date: Tue, 27 Apr 2021 12:49:46 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=khLL002hRBXd9WKfica/99bJXhH5ZJ+qh+xZdE2rdSs=; b=YN6oZR8sEHXtr6kIymcGKohoYMMiVQiJYZA21Sh7TBG/TjgELw9RSRVgk+9l5cy7oVDN76+W674rOo4wLKqxkKOvz3+nE8PUtKnACDpEuDgVg3a+otTJUvoBitcRs/rcR+uJ+hItR0n0fLg70qOo6W7RLnwZfvgNZyBupWAV29G6Fu2wUjqOzCWlTZfmmrm8sf8szXsLoCrDhQMPcsFO+asBY0KyQp+oabKH2azTMfRpqR9RRTsUnNrmETldpT+CUCMxCmAQF+0WWW8pKpIfxK7PzxdasWkjzZZgCLZPZcXF/4PzF0hF6woxVv9GBfT8KQksOKVs7Xk4OagJuhL0DA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=NIqxdvL5fHtwsZLg+eLkqaE0WhPXdUxHafRbhJUvvgUR1ynbSDvoE7x+xmyk0Og2W3ypmDvPJumZBQHly0O4sQBd6cPiNz9XrCZFzbOlcb51/vtxvt5BuUXnbeXw5R7fsr1QRwPQuzsf+N1Jd+Yo4nOg+ACVeByK8A9wZHOFWBOxG2Xnnh9LrlAwk+S2rMf6Ek5FhkrXd1vypGv1XLV1kiGWRhgR5L7H6ZWShn98VtNVx0ggMYeFqfglrbfRm1D2jDi2Bs4wrVgaeks+KOYhfXgbGxsAQ/5OjQY8Bap4PGXRoZ8dzjgTxIJ+CwAdV38zuPcp/orQA+J9l5CswtjBFQ==
  • Authentication-results: esa1.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
  • Cc: Jan Beulich <jbeulich@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
  • Delivery-date: Tue, 27 Apr 2021 10:50:10 +0000
  • Ironport-hdrordr: A9a23:LPKnMKCDrkHbccXlHegctMeALOonbusQ8zAX/mhLY1h8btGYm8 eynP4SyB/zj3IrVGs9nM2bUZPufVr1zrQwxYUKJ7+tUE3duGWuJJx/9oeK+VHdMgXE3Kpm2a 9kGpISNPTZEUV6gcHm4AOxDtYnx529/Lq1gPrFpk0NcShBQchbnmBEIyycFVB7QxQDKJoiDZ yH5tdGoT3IQwVsUu2QAH4ZU+/f4+DRnJX9bhIcQzIh4g+CjTSngYSKbiSw9BEYTj9J3PMe4X HI+jaJnZmLntOa7lvn12HV54lLg9eJ8LV+LeGFl8R9EESPti+Gf4JkMofy2QwdgObq01oylc mJnhFIBbUO11r0XkWY5STgwBPh1jFG0Q6T9Xa9jWH4qcL0ABIWYvAx/L5xSRfS50o+sNwU6s sitAj4xvknfy/opyjz68PFUBtnjCOP0AIfuNUekmBFVs8mYKJRxLZvjX99KosKHy7x9ekcYY 9TJfzbjcwmFW+yXjTyu2lix8GURXIjHhuKaVhqgL3q7xFm2F9+1EcW38oZgzMp8488UYBN46 D+Pr1vj6wmdL5bUYtNQMM6BeenAG3ERhzBdEqUPFTcDakCf1bAsYT+7rkZ7PyjEaZ4g6caqd Dkahd1pGQyc0XhBYmlx5tQ6C3AR227QHDE1txez4IRgMy9eJPbdQm4DHw+mcqppPsSRufBXe yoBZ5QC/j/aUPzBIdy2RHkUZU6EwhebOQl/vIAH36eqMPCLYPn8sbBduzIGbbrGTE4HkzlBH 8uWyXyOdVg4kinV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42ghWINW07pvARqBlTjM3vMvAEa/zThOVjMYhRN+Ajdagm2txuqir6xF/5 A/ei8XTvqMXSNa9QmstHyOjdZOQwt+hDzRJ5w2R7XU4mFvn1BwtisrsKHKq/M8TCwfyC3R5t4e gfo=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On Tue, Apr 27, 2021 at 12:40:03PM +0200, Roger Pau Monne wrote:
> When trying to build an hypervisor without PV or HVM (ie: using
> automation/configs/x86/no_hvm_pv_config) it fails to link with:
> 
> prelink.o: In function `sh_remove_write_access_from_sl1p':
> arch/x86/mm/shadow/common.c:(.text+0x72b4c): undefined reference to 
> `sh_rm_write_access_from_sl1p__guest_4'
> arch/x86/mm/shadow/common.c:(.text+0x72b4c): relocation truncated to fit: 
> R_X86_64_PC32 against undefined symbol `sh_rm_write_access_from_sl1p__guest_4'
> prelink.o: In function `sh_remove_shadow_via_pointer':
> arch/x86/mm/shadow/common.c:(.text+0x72bfa): undefined reference to 
> `sh_clear_shadow_entry__guest_4'
> arch/x86/mm/shadow/common.c:(.text+0x72bfa): relocation truncated to fit: 
> R_X86_64_PC32 against undefined symbol `sh_clear_shadow_entry__guest_4'
> prelink.o: In function `_sh_resync':
> arch/x86/mm/shadow/common.c:(.text+0x72e4a): undefined reference to 
> `sh_resync_l1__guest_4'
> arch/x86/mm/shadow/common.c:(.text+0x72e4a): relocation truncated to fit: 
> R_X86_64_PC32 against undefined symbol `sh_resync_l1__guest_4'
> prelink.o: In function `shadow_vcpu_init':
> (.text+0x72eeb): undefined reference to `sh_paging_mode__guest_4'
> prelink.o: In function `shadow_vcpu_init':
> (.text+0x72eeb): relocation truncated to fit: R_X86_64_PC32 against undefined 
> symbol `sh_paging_mode__guest_4'
> prelink.o: In function `sh_resync_all':
> (.text+0x73315): undefined reference to `sh_safe_not_to_sync__guest_4'
> prelink.o: In function `sh_resync_all':
> (.text+0x73315): relocation truncated to fit: R_X86_64_PC32 against undefined 
> symbol `sh_safe_not_to_sync__guest_4'
> prelink.o: In function `sh_resync_all':
> (.text+0x7336a): undefined reference to `sh_resync_l1__guest_4'
> prelink.o: In function `sh_resync_all':
> (.text+0x7336a): relocation truncated to fit: R_X86_64_PC32 against undefined 
> symbol `sh_resync_l1__guest_4'
> prelink.o: In function `sh_validate_guest_entry':
> (.text+0x736bd): undefined reference to `sh_map_and_validate_gl4e__guest_4'
> prelink.o: In function `sh_validate_guest_entry':
> (.text+0x736bd): relocation truncated to fit: R_X86_64_PC32 against undefined 
> symbol `sh_map_and_validate_gl4e__guest_4'
> prelink.o: In function `sh_validate_guest_entry':
> (.text+0x736dd): undefined reference to `sh_map_and_validate_gl1e__guest_4'
> prelink.o: In function `sh_validate_guest_entry':
> (.text+0x736dd): relocation truncated to fit: R_X86_64_PC32 against undefined 
> symbol `sh_map_and_validate_gl1e__guest_4'
> prelink.o: In function `sh_validate_guest_entry':
> (.text+0x736fd): undefined reference to `sh_map_and_validate_gl2e__guest_4'
> prelink.o: In function `sh_validate_guest_entry':
> (.text+0x736fd): relocation truncated to fit: R_X86_64_PC32 against undefined 
> symbol `sh_map_and_validate_gl2e__guest_4'
> prelink.o: In function `sh_validate_guest_entry':
> (.text+0x7371d): undefined reference to `sh_map_and_validate_gl2he__guest_4'
> prelink.o: In function `sh_validate_guest_entry':
> (.text+0x7371d): relocation truncated to fit: R_X86_64_PC32 against undefined 
> symbol `sh_map_and_validate_gl2he__guest_4'
> prelink.o: In function `sh_validate_guest_entry':
> (.text+0x7373d): undefined reference to `sh_map_and_validate_gl3e__guest_4'
> prelink.o: In function `sh_validate_guest_entry':
> (.text+0x7373d): additional relocation overflows omitted from the output
> prelink.o: In function `shadow_unhook_mappings':
> (.text+0x7379b): undefined reference to `sh_unhook_64b_mappings__guest_4'
> prelink.o: In function `sh_destroy_shadow':
> (.text+0x74183): undefined reference to `sh_destroy_l1_shadow__guest_4'
> prelink.o: In function `sh_destroy_shadow':
> (.text+0x74199): undefined reference to `sh_destroy_l4_shadow__guest_4'
> prelink.o: In function `sh_destroy_shadow':
> (.text+0x741a1): undefined reference to `sh_destroy_l3_shadow__guest_4'
> prelink.o: In function `sh_destroy_shadow':
> (.text+0x741a9): undefined reference to `sh_destroy_l2_shadow__guest_4'
> prelink.o:(.data.rel.ro.local+0x1018): undefined reference to 
> `sh_remove_l1_shadow__guest_4'
> prelink.o:(.data.rel.ro.local+0x1020): undefined reference to 
> `sh_remove_l1_shadow__guest_4'
> prelink.o:(.data.rel.ro.local+0x1028): undefined reference to 
> `sh_remove_l2_shadow__guest_4'
> prelink.o:(.data.rel.ro.local+0x1030): undefined reference to 
> `sh_remove_l3_shadow__guest_4'
> prelink.o:(.data.rel.ro.local+0x1068): undefined reference to 
> `sh_rm_mappings_from_l1__guest_4'
> prelink.o:(.data.rel.ro.local+0x1070): undefined reference to 
> `sh_rm_mappings_from_l1__guest_4'
> ld: /root/src/xen/xen/.xen-syms.0: hidden symbol 
> `sh_destroy_l2_shadow__guest_4' isn't defined
> ld: final link failed: Bad value
> 
> Fix this by making shadow depend on either PV or HVM being selected in
> Kconfig.
> 
> Fixes: aff8bf94ce6 ('x86/shadow: only 4-level guest code needs building when 
> !HVM')
> Signed-off-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>

Urg, I see this has already been fixed. Not sure why my rebase didn't
clear the patch.

Sorry for the noise.



 


Rackspace

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