Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-28 Thread Oscar Salvador
On Thu, Feb 28, 2019 at 03:08:17PM +0100, Michal Hocko wrote: > On Thu 28-02-19 14:40:54, Oscar Salvador wrote: > > On Thu, Feb 28, 2019 at 01:11:15PM +0100, Michal Hocko wrote: > > > On Thu 28-02-19 11:19:52, Oscar Salvador wrote: > > > > On Thu, Feb 28, 2019 at 10:55:35AM +0100, Michal Hocko wrot

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-28 Thread Michal Hocko
On Thu 28-02-19 14:40:54, Oscar Salvador wrote: > On Thu, Feb 28, 2019 at 01:11:15PM +0100, Michal Hocko wrote: > > On Thu 28-02-19 11:19:52, Oscar Salvador wrote: > > > On Thu, Feb 28, 2019 at 10:55:35AM +0100, Michal Hocko wrote: > > > > You seemed to miss my point or I am wrong here. If scan_mov

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-28 Thread Oscar Salvador
On Thu, Feb 28, 2019 at 01:11:15PM +0100, Michal Hocko wrote: > On Thu 28-02-19 11:19:52, Oscar Salvador wrote: > > On Thu, Feb 28, 2019 at 10:55:35AM +0100, Michal Hocko wrote: > > > You seemed to miss my point or I am wrong here. If scan_movable_pages > > > skips over a hugetlb page then there is

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-28 Thread Michal Hocko
On Thu 28-02-19 11:19:52, Oscar Salvador wrote: > On Thu, Feb 28, 2019 at 10:55:35AM +0100, Michal Hocko wrote: > > You seemed to miss my point or I am wrong here. If scan_movable_pages > > skips over a hugetlb page then there is nothing to migrate it and it > > will stay in the pfn range and the r

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-28 Thread Oscar Salvador
On Thu, Feb 28, 2019 at 10:55:35AM +0100, Michal Hocko wrote: > You seemed to miss my point or I am wrong here. If scan_movable_pages > skips over a hugetlb page then there is nothing to migrate it and it > will stay in the pfn range and the range will not become idle. I might be misunterstanding

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-28 Thread Michal Hocko
On Thu 28-02-19 10:41:08, Oscar Salvador wrote: > On Thu, Feb 28, 2019 at 10:21:54AM +0100, Michal Hocko wrote: > > On Thu 21-02-19 10:42:12, Oscar Salvador wrote: > > [...] > > > diff --git a/mm/memory_hotplug.c b/mm/memory_hotplug.c > > > index d5f7afda67db..04f6695b648c 100644 > > > --- a/mm/mem

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-28 Thread Oscar Salvador
On Thu, Feb 28, 2019 at 10:21:54AM +0100, Michal Hocko wrote: > On Thu 21-02-19 10:42:12, Oscar Salvador wrote: > [...] > > diff --git a/mm/memory_hotplug.c b/mm/memory_hotplug.c > > index d5f7afda67db..04f6695b648c 100644 > > --- a/mm/memory_hotplug.c > > +++ b/mm/memory_hotplug.c > > @@ -1337,8 +

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-28 Thread Michal Hocko
On Thu 21-02-19 10:42:12, Oscar Salvador wrote: [...] > diff --git a/mm/memory_hotplug.c b/mm/memory_hotplug.c > index d5f7afda67db..04f6695b648c 100644 > --- a/mm/memory_hotplug.c > +++ b/mm/memory_hotplug.c > @@ -1337,8 +1337,7 @@ static unsigned long scan_movable_pages(unsigned long > start, un

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-28 Thread Michal Hocko
On Thu 28-02-19 08:38:34, David Hildenbrand wrote: > On 27.02.19 23:00, Mike Kravetz wrote: > > On 2/27/19 1:51 PM, Oscar Salvador wrote: > >> On Thu, Feb 21, 2019 at 10:42:12AM +0100, Oscar Salvador wrote: > >>> [1] https://lore.kernel.org/patchwork/patch/998796/ > >>> > >>> Signed-off-by: Oscar S

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-27 Thread David Hildenbrand
On 27.02.19 23:00, Mike Kravetz wrote: > On 2/27/19 1:51 PM, Oscar Salvador wrote: >> On Thu, Feb 21, 2019 at 10:42:12AM +0100, Oscar Salvador wrote: >>> [1] https://lore.kernel.org/patchwork/patch/998796/ >>> >>> Signed-off-by: Oscar Salvador >> >> Any further comments on this? >> I do have a "co

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-27 Thread Mike Kravetz
On 2/27/19 1:51 PM, Oscar Salvador wrote: > On Thu, Feb 21, 2019 at 10:42:12AM +0100, Oscar Salvador wrote: >> [1] https://lore.kernel.org/patchwork/patch/998796/ >> >> Signed-off-by: Oscar Salvador > > Any further comments on this? > I do have a "concern" I would like to sort out before dropping

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-27 Thread Oscar Salvador
On Thu, Feb 21, 2019 at 10:42:12AM +0100, Oscar Salvador wrote: > [1] https://lore.kernel.org/patchwork/patch/998796/ > > Signed-off-by: Oscar Salvador Any further comments on this? I do have a "concern" I would like to sort out before dropping the RFC: It is the fact that unless we have spare

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-22 Thread Oscar Salvador
On Thu, Feb 21, 2019 at 02:12:19PM -0800, Mike Kravetz wrote: > I suspect the reason for the check is that it was there before the ability > to migrate gigantic pages was added, and nobody thought to remove it. As > you say, the likelihood of finding a gigantic page after running for some > time i

Re: [RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-21 Thread Mike Kravetz
On 2/21/19 1:42 AM, Oscar Salvador wrote: > On x86_64, 1GB-hugetlb pages could never be offlined due to the fact > that hugepage_migration_supported() returned false for PUD_SHIFT. > So whenever we wanted to offline a memblock containing a gigantic > hugetlb page, we never got beyond has_unmovable_

[RFC PATCH] mm,memory_hotplug: Unlock 1GB-hugetlb on x86_64

2019-02-21 Thread Oscar Salvador
On x86_64, 1GB-hugetlb pages could never be offlined due to the fact that hugepage_migration_supported() returned false for PUD_SHIFT. So whenever we wanted to offline a memblock containing a gigantic hugetlb page, we never got beyond has_unmovable_pages() check. This changed with [1], where now we