Re: [PATCH 4/8] v3 Allow memory_block to span multiple memory sections

2010-07-26 Thread Dave Hansen
On Fri, 2010-07-23 at 22:09 -0500, Nathan Fontenot wrote: > If we add a lock should I submit it as part of this patchset? or > submit it > as a follow-on? It should probably be at the beginning of the patch set. We don't want to have a case where your set introduces races that we _need_ a later p

Re: [PATCH 4/8] v3 Allow memory_block to span multiple memory sections

2010-07-26 Thread Nathan Fontenot
On 07/20/2010 02:18 PM, Dave Hansen wrote: > On Mon, 2010-07-19 at 22:55 -0500, Nathan Fontenot wrote: >> +static int add_memory_section(int nid, struct mem_section *section, >> + unsigned long state, enum mem_add_context context) >> +{ >> + struct memory_block *mem; >>

Re: [PATCH 4/8] v3 Allow memory_block to span multiple memory sections

2010-07-23 Thread Nathan Fontenot
On 07/20/2010 02:18 PM, Dave Hansen wrote: > On Mon, 2010-07-19 at 22:55 -0500, Nathan Fontenot wrote: >> +static int add_memory_section(int nid, struct mem_section *section, >> + unsigned long state, enum mem_add_context context) >> +{ >> + struct memory_block *mem; >>

Re: [PATCH 4/8] v3 Allow memory_block to span multiple memory sections

2010-07-20 Thread Dave Hansen
On Mon, 2010-07-19 at 22:55 -0500, Nathan Fontenot wrote: > +static u32 get_memory_block_size(void) > +{ > + u32 block_sz; > + > + block_sz = memory_block_size_bytes(); > + > + /* Validate blk_sz is a power of 2 and not less than section size */ > + if ((block_sz & (block_sz

Re: [PATCH 4/8] v3 Allow memory_block to span multiple memory sections

2010-07-20 Thread Dave Hansen
On Mon, 2010-07-19 at 22:55 -0500, Nathan Fontenot wrote: > +static int add_memory_section(int nid, struct mem_section *section, > + unsigned long state, enum mem_add_context context) > +{ > + struct memory_block *mem; > + int ret = 0; > + > + mem = find_memo

Re: [PATCH 4/8] v3 Allow memory_block to span multiple memory sections

2010-07-20 Thread Nathan Fontenot
Update the memory sysfs code that each sysfs memory directory is now considered a memory block that can contain multiple memory sections per memory block. The default size of each memory block is SECTION_SIZE_BITS to maintain the current behavior of having a single memory section per memory block

Re: [PATCH 4/8] v3 Allow memory_block to span multiple memory sections

2010-07-20 Thread KAMEZAWA Hiroyuki
On Mon, 19 Jul 2010 22:55:08 -0500 Nathan Fontenot wrote: > Update the memory sysfs code that each sysfs memory directory is now > considered a memory block that can contain multiple memory sections per > memory block. The default size of each memory block is SECTION_SIZE_BITS > to maintain the

[PATCH 4/8] v3 Allow memory_block to span multiple memory sections

2010-07-19 Thread Nathan Fontenot
Update the memory sysfs code that each sysfs memory directory is now considered a memory block that can contain multiple memory sections per memory block. The default size of each memory block is SECTION_SIZE_BITS to maintain the current behavior of having a single memory section per memory block