RE: [PATCH] powerpc:Fix rheap alignment problem

From: Li Yang-r58472 <hidden>
Date: 2006-07-03 12:19:11
Also in: lkml

quoted
quoted
Two problems with genalloc that I can see (for CPM programming):
1) (minor) Does not have a way to specify alignment (genalloc does it for
you)
quoted
quoted
2) (major problerm, at least for me) Does not have a way to allocate a
specified address in the pool.
quoted
quoted
2 is needed esp when programming MCC drivers, since a lot of the
datastructures must be in DP RAM _and_ be in a specific spot. And if you cannot
tell the allocator that I am using a specific address, then the allocator might
very well give somebody else that portion of RAM. The only solution without
a fixed allocator is to allocate ALL memory in the DP RAM and use your own
allocator.
quoted
quoted
Yeah, that too.

Too bad there are no main tree drivers like that, but they do exist.

One could conceivably hack genalloc to do that, but will end up with
something complex too.

BTW, there are other uEngine based architectures with similar alignment
requirements.

So in conclusion, for the in-tree drivers genalloc is sufficient as an cpm
memory allocator.
quoted
For some out of tree drivers, it is not.
Sounds like a good enough justification to keep rheap for now then.
As the reason I stated in the last mail, rheap should continue being used not only for this fix-address situation but also for CPM/QE buffer descriptor management.  Rheap and genalloc are two different implementations of dynamic memory allocator, which have different suitable cases.  Both of them should be kept for different applications.
Ben.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help