Re: [PATCH v3 1/4] mm/memory_hotplug: enforce block size aligned range check

2018-02-15 Thread Pavel Tatashin
No, not really. I just think the alignment shouldn't really matter. Each memory block should simply represent a hotplugable entitity with a well defined pfn start and size (in multiples of section size). This is in fact what we do internally anyway. One problem might be that an existing userspace

Re: [PATCH v3 1/4] mm/memory_hotplug: enforce block size aligned range check

2018-02-15 Thread Pavel Tatashin
No, not really. I just think the alignment shouldn't really matter. Each memory block should simply represent a hotplugable entitity with a well defined pfn start and size (in multiples of section size). This is in fact what we do internally anyway. One problem might be that an existing userspace

Re: [PATCH v3 1/4] mm/memory_hotplug: enforce block size aligned range check

2018-02-15 Thread Michal Hocko
On Thu 15-02-18 08:36:00, Pavel Tatashin wrote: > Hi Michal, > > Thank you very much for your reviews and for Acking this patch. > > > > > The whole memblock != section_size sucks! It leads to corner cases like > > you see. There is no real reason why we shouldn't be able to to online > > 2G

Re: [PATCH v3 1/4] mm/memory_hotplug: enforce block size aligned range check

2018-02-15 Thread Michal Hocko
On Thu 15-02-18 08:36:00, Pavel Tatashin wrote: > Hi Michal, > > Thank you very much for your reviews and for Acking this patch. > > > > > The whole memblock != section_size sucks! It leads to corner cases like > > you see. There is no real reason why we shouldn't be able to to online > > 2G

Re: [PATCH v3 1/4] mm/memory_hotplug: enforce block size aligned range check

2018-02-15 Thread Pavel Tatashin
Hi Michal, Thank you very much for your reviews and for Acking this patch. > > The whole memblock != section_size sucks! It leads to corner cases like > you see. There is no real reason why we shouldn't be able to to online > 2G unaligned memory range. Failing for that purpose is just wrong. The

Re: [PATCH v3 1/4] mm/memory_hotplug: enforce block size aligned range check

2018-02-15 Thread Pavel Tatashin
Hi Michal, Thank you very much for your reviews and for Acking this patch. > > The whole memblock != section_size sucks! It leads to corner cases like > you see. There is no real reason why we shouldn't be able to to online > 2G unaligned memory range. Failing for that purpose is just wrong. The

Re: [PATCH v3 1/4] mm/memory_hotplug: enforce block size aligned range check

2018-02-15 Thread Michal Hocko
On Tue 13-02-18 14:31:56, Pavel Tatashin wrote: > Start qemu with the following arguments: > -m 64G,slots=2,maxmem=66G -object memory-backend-ram,id=mem1,size=2G > > Which: boots machine with 64G, and adds a device mem1 with 2G which can be > hotplugged later. > > Also make sure that config has

Re: [PATCH v3 1/4] mm/memory_hotplug: enforce block size aligned range check

2018-02-15 Thread Michal Hocko
On Tue 13-02-18 14:31:56, Pavel Tatashin wrote: > Start qemu with the following arguments: > -m 64G,slots=2,maxmem=66G -object memory-backend-ram,id=mem1,size=2G > > Which: boots machine with 64G, and adds a device mem1 with 2G which can be > hotplugged later. > > Also make sure that config has

[PATCH v3 1/4] mm/memory_hotplug: enforce block size aligned range check

2018-02-13 Thread Pavel Tatashin
Start qemu with the following arguments: -m 64G,slots=2,maxmem=66G -object memory-backend-ram,id=mem1,size=2G Which: boots machine with 64G, and adds a device mem1 with 2G which can be hotplugged later. Also make sure that config has the following turned on: CONFIG_MEMORY_HOTPLUG

[PATCH v3 1/4] mm/memory_hotplug: enforce block size aligned range check

2018-02-13 Thread Pavel Tatashin
Start qemu with the following arguments: -m 64G,slots=2,maxmem=66G -object memory-backend-ram,id=mem1,size=2G Which: boots machine with 64G, and adds a device mem1 with 2G which can be hotplugged later. Also make sure that config has the following turned on: CONFIG_MEMORY_HOTPLUG