[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH for-next 7/9] xen: Convert is_xen_heap_mfn to use typesafe MFN
>>> On 13.03.19 at 18:24, <julien.grall@xxxxxxx> wrote: > On 13/03/2019 15:04, Jan Beulich wrote: >>>>> On 18.02.19 at 12:35, <julien.grall@xxxxxxx> wrote: >>> --- a/xen/common/page_alloc.c >>> +++ b/xen/common/page_alloc.c >>> @@ -2121,9 +2121,9 @@ void init_xenheap_pages(paddr_t ps, paddr_t pe) >>> * Yuk! Ensure there is a one-page buffer between Xen and Dom zones, >>> to >>> * prevent merging of power-of-two blocks across the zone boundary. >>> */ >>> - if ( ps && !is_xen_heap_mfn(paddr_to_pfn(ps)-1) ) >>> + if ( ps && !is_xen_heap_mfn(_mfn(paddr_to_pfn(ps)-1)) ) >>> ps += PAGE_SIZE; >>> - if ( !is_xen_heap_mfn(paddr_to_pfn(pe)) ) >>> + if ( !is_xen_heap_mfn(maddr_to_mfn(pe)) ) >> >> Why maddr_to_mfn() here but still paddr_to_pfn() above? Oh, >> we don't have any mfn_sub(), I see. > > Yes we don't have mfn_sub() (or even gfn_sub()). I only found a couple of > places > where such helpers might be useful. I can introduce the 2 helpers if you > think > it is worth it. Well, I guess in the end I'm fine either way. It simply struck me as odd at the first glance that you use maddr_to_mfn() in one case but not the other. Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |