x86/ept: Drop shadow mode check in ept_sync_domain()

This function can only be reached from EPT-related code which is inherently
HAP. Thus it is not useful to check for shadow_paging (or lack of HAP) there.

Moreover, it is an error to call this function in the non-EPT cases.

Not a functional change.

Signed-off-by: Teddy Astie <teddy.astie@vates.tech>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
This commit is contained in:
Teddy Astie authored and Jan Beulich committed 2025-12-01 10:12:58 +01:00
1 parent d00cb14893
commit bea8b17913
1 file changed
+3 -2
+3 -2
View File
@@ -1268,9 +1268,10 @@ static void ept_sync_domain_mask(struct p2m_domain *p2m, const cpumask_t *mask)
void ept_sync_domain(struct p2m_domain *p2m)
{
struct domain *d = p2m->domain;
ASSERT(hap_enabled(d));
/* Only if using EPT and this domain has some VCPUs to dirty. */
if ( paging_mode_shadow(d) || !d->vcpu || !d->vcpu[0] )
/* Only if this domain has some VCPUs to dirty. */
if ( !d->vcpu || !d->vcpu[0] )
return;
ept_sync_domain_prepare(p2m);
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.