Re: [PATCH 2/2] linux: ARM: memmap: Revise freeing unused memmap entries for SPARSEMEM

From: Akira Takeuchi
Date: Thu Mar 29 2012 - 21:26:35 EST

On Thu, 29 Mar 2012 13:13:14 +0100
Russell King - ARM Linux <linux@xxxxxxxxxxxxxxxx> wrote:

> On Thu, Mar 29, 2012 at 07:02:52PM +0900, Akira Takeuchi wrote:
> > F0-F4 is the unused memory regions and their corresponding memmap entries
> > can be freed. However, free_unused_memmap() only frees the entries for
> > F1/F2/F4, and does not free the entries for F0/F3.
> No we're not going to support having free areas at the start of an
> otherwise populated bank of memory. This is just insane. Fix your
> hardware instead or your sparsemem setup.

As you say, it is able to reduce the number of unused entries remained
by setting SECTION_SIZE_BITS smaller.
On the other hand, I think it's not always true to assign whole memory
to Linux. In some cases, there are free areas at the start of populated
bank of memory and these free areas are assigned to sub CPUs or DSPs
for example. Recent CE SoCs are apt to include multiple CPUs and DSPs
sharing memory among them. This patch is beneficial for such systems,
I think.

Akira Takeuchi

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at