If anything, a check covering a wider range of invalid M2P entries ought to be used (e.g. VALID_M2P()). But since everything is fully under Xen's control at this stage, simply remove the BUG_ON().
Signed-off-by: Jan Beulich <[email protected]> --- a/xen/arch/x86/pv/dom0_build.c +++ b/xen/arch/x86/pv/dom0_build.c @@ -815,7 +815,6 @@ int __init dom0_construct_pv(struct doma page_list_for_each ( page, &d->page_list ) { mfn = mfn_x(page_to_mfn(page)); - BUG_ON(SHARED_M2P(get_gpfn_from_mfn(mfn))); if ( get_gpfn_from_mfn(mfn) >= count ) { BUG_ON(compat);
