[RFC v2] genalloc:add an gen_pool_first_fit_align algo to genalloc

Zhao Qiang qiang.zhao at freescale.com
Tue Jul 28 15:32:42 AEST 2015


On Tue, 2015-07-28 at 5:21, Scott Wood wrote:
> -----Original Message-----
> From: Wood Scott-B07421
> Sent: Tuesday, July 28, 2015 5:21 AM
> To: Zhao Qiang-B45475
> Cc: lauraa at codeaurora.org; linux-kernel at vger.kernel.org; linuxppc-
> dev at lists.ozlabs.org; akpm at linux-foundation.org; olof at lixom.net;
> catalin.marinas at arm.com; Xie Xiaobo-R63061
> Subject: Re: [RFC v2] genalloc:add an gen_pool_first_fit_align algo to
> genalloc
> 
> On Mon, 2015-07-27 at 17:57 +0800, Zhao Qiang wrote:
> 
> Where's the part that adds the ability to pass in data to each allocation
> call, as per the previous discussion?

You means to use gen_pool_alloc_data()?
Previously you said that the format of data is algorithm-specific,
So I think it is better to handle data in algorithm function.

If you still prefer gen_pool_alloc_data(), I will modify it.
But there still are details I want to confirm with you.
1. If use gen_pool_alloc_data(), should I pass data as a parameter?
2. Should I count align_mask in gen_pool_alloc_data(), meanwhile, add 
   a align_mask to data as a member?
3. where to define the data, in genalloc.h or caller layer?

> 
> -Scott



More information about the Linuxppc-dev mailing list