Skip to contentSkip to conversation

x86/mm: don't call HVM-only function for PV guests

PATCH In review Jan Beulich 2 participants 2 messages Oct 27, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 x86/mm: don't call HVM-only function for PV guests

Somehow I managed to drop the HVM dependency from v2 to v3 of what became commit 5c23c760a8 ("x86/HVM: correct page dirty marking in hvm_map_guest_frame_rw()"), obviously breaking migration of PV guests.

xen/arch/x86/mm/paging.c +2 -1
@@ -425,7 +425,8 @@ static int paging_log_dirty_op(struct do
          * Mark dirty all currently write-mapped pages on e.g. the
          * final iteration of a save operation.
          */
-        if ( sc->mode & XEN_DOMCTL_SHADOW_LOGDIRTY_FINAL )
+        if ( has_hvm_container_domain(d) &&
+             (sc->mode & XEN_DOMCTL_SHADOW_LOGDIRTY_FINAL) )
             hvm_mapped_guest_frames_mark_dirty(d);
 
         domain_pause(d);

x86/mm: don't call HVM-only function for PV guests

Somehow I managed to drop the HVM dependency from v2 to v3 of what became commit 5c23c760a8 ("x86/HVM: correct page dirty marking in hvm_map_guest_frame_rw()"), obviously breaking migration of PV guests.

xen/arch/x86/mm/paging.c +2 -1
@@ -425,7 +425,8 @@ static int paging_log_dirty_op(struct do
          * Mark dirty all currently write-mapped pages on e.g. the
          * final iteration of a save operation.
          */
-        if ( sc->mode & XEN_DOMCTL_SHADOW_LOGDIRTY_FINAL )
+        if ( has_hvm_container_domain(d) &&
+             (sc->mode & XEN_DOMCTL_SHADOW_LOGDIRTY_FINAL) )
             hvm_mapped_guest_frames_mark_dirty(d);
 
         domain_pause(d);

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

#1 lore raw
Quoted 5 lines · Jan Beulich

Somehow I managed to drop the HVM dependency from v2 to v3 of what became commit 5c23c760a8 ("x86/HVM: correct page dirty marking in hvm_map_guest_frame_rw()"), obviously breaking migration of PV guests.

Oops yes. Reviewed-by: Andrew Cooper <[email protected]>

Quoted 16 lines
xen/arch/x86/mm/paging.c +2 -1
@@ -425,7 +425,8 @@ static int paging_log_dirty_op(struct do
          * Mark dirty all currently write-mapped pages on e.g. the
          * final iteration of a save operation.
          */
-        if ( sc->mode & XEN_DOMCTL_SHADOW_LOGDIRTY_FINAL )
+        if ( has_hvm_container_domain(d) &&
+             (sc->mode & XEN_DOMCTL_SHADOW_LOGDIRTY_FINAL) )
             hvm_mapped_guest_frames_mark_dirty(d);
 
         domain_pause(d);