Re: [PATCH v5 4/6] x86/mem-hotplug: Support initialize page tables in bottom-up

2013-09-26 Thread H. Peter Anvin
Can we put this in a common header somewhere? Andrew Morton wrote: >On Wed, 25 Sep 2013 02:30:51 +0800 Zhang Yanfei > wrote: > >> From: Tang Chen >> >> The Linux kernel cannot migrate pages used by the kernel. As a >> result, kernel pages cannot be hot-removed. So we cannot allocate >> hotplugg

Re: [PATCH v5 4/6] x86/mem-hotplug: Support initialize page tables in bottom-up

2013-09-26 Thread Andrew Morton
On Wed, 25 Sep 2013 02:30:51 +0800 Zhang Yanfei wrote: > From: Tang Chen > > The Linux kernel cannot migrate pages used by the kernel. As a > result, kernel pages cannot be hot-removed. So we cannot allocate > hotpluggable memory for the kernel. > > In a memory hotplug system, any numa node t

Re: [PATCH v5 4/6] x86/mem-hotplug: Support initialize page tables in bottom-up

2013-09-26 Thread Zhang Yanfei
On 09/26/2013 10:48 PM, Tejun Heo wrote: > Hello, > > On Wed, Sep 25, 2013 at 02:30:51AM +0800, Zhang Yanfei wrote: >> +/** >> + * memory_map_bottom_up - Map [map_start, map_end) bottom up >> + * @map_start: start address of the target memory range >> + * @map_end: end address of the target memory

Re: [PATCH v5 4/6] x86/mem-hotplug: Support initialize page tables in bottom-up

2013-09-26 Thread Tejun Heo
On Fri, Sep 27, 2013 at 12:03:01AM +0800, Zhang Yanfei wrote: > Ah, I see. You are saying another issue. He is worrying that if we use > kexec to load the kernel high, say we have 16GB, we put the kernel in > 15.99GB (just an example), so we only have less than 100MB above the kernel. > > But as I

Re: [PATCH v5 4/6] x86/mem-hotplug: Support initialize page tables in bottom-up

2013-09-26 Thread Zhang Yanfei
On 09/26/2013 11:48 PM, Tejun Heo wrote: > On Thu, Sep 26, 2013 at 11:43:02PM +0800, Zhang Yanfei wrote: >>> As Yinghai pointed out in another thread, do we need to worry about >>> falling back to top-down? >> >> I've explained to him. Nop, we don't need to worry about that. Because even >> the min

Re: [PATCH v5 4/6] x86/mem-hotplug: Support initialize page tables in bottom-up

2013-09-26 Thread Tejun Heo
On Thu, Sep 26, 2013 at 11:43:02PM +0800, Zhang Yanfei wrote: > > As Yinghai pointed out in another thread, do we need to worry about > > falling back to top-down? > > I've explained to him. Nop, we don't need to worry about that. Because even > the min_pfn_mapped becomes ISA_END_ADDRESS in the se

Re: [PATCH v5 4/6] x86/mem-hotplug: Support initialize page tables in bottom-up

2013-09-26 Thread Zhang Yanfei
Hello tejun, On 09/26/2013 10:48 PM, Tejun Heo wrote: > Hello, > > On Wed, Sep 25, 2013 at 02:30:51AM +0800, Zhang Yanfei wrote: >> +/** >> + * memory_map_bottom_up - Map [map_start, map_end) bottom up >> + * @map_start: start address of the target memory range >> + * @map_end: end address of the

Re: [PATCH v5 4/6] x86/mem-hotplug: Support initialize page tables in bottom-up

2013-09-26 Thread Tejun Heo
Hello, On Wed, Sep 25, 2013 at 02:30:51AM +0800, Zhang Yanfei wrote: > +/** > + * memory_map_bottom_up - Map [map_start, map_end) bottom up > + * @map_start: start address of the target memory range > + * @map_end: end address of the target memory range > + * > + * This function will setup direct

[PATCH v5 4/6] x86/mem-hotplug: Support initialize page tables in bottom-up

2013-09-24 Thread Zhang Yanfei
From: Tang Chen The Linux kernel cannot migrate pages used by the kernel. As a result, kernel pages cannot be hot-removed. So we cannot allocate hotpluggable memory for the kernel. In a memory hotplug system, any numa node the kernel resides in should be unhotpluggable. And for a modern server,