lkml.org 
[lkml]   [2021]   [Mar]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v5 1/5] mm,memory_hotplug: Allocate memmap from the added memory range
On Fri, Mar 19, 2021 at 11:20:19AM +0100, David Hildenbrand wrote:
> > +bool mhp_supports_memmap_on_memory(unsigned long size)
> > +{
> > + unsigned long nr_vmemmap_pages = size / PAGE_SIZE;
> > + unsigned long vmemmap_size = nr_vmemmap_pages * sizeof(struct page);
> > + unsigned long remaining_size = size - vmemmap_size;
> > +
> > + /*
> > + * Besides having arch support and the feature enabled at runtime, we
> > + * need a few more assumptions to hold true:
> > + *
> > + * a) We span a single memory block: memory onlining/offlinin;g happens
>
> s/offlinin;g/offlining;/

Bleh, terrible :-(

> IS_ALIGNED(remaining_size, pageblock_nr_pages << PAGE_SHIFT);

Yaiks

Hopefully Andrew can amend these two nits?

> (another pair of eyes certainly wouldn't hurt :) )

definitely, but those are pricy as you may know :-D

> Reviewed-by: David Hildenbrand <david@redhat.com>

Thanks a lot for the throughout review David, highly appreciated!


--
Oscar Salvador
SUSE L3

\
 
 \ /
  Last update: 2021-03-19 11:32    [W:0.229 / U:0.244 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site