[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5240FBEF.10102@cn.fujitsu.com>
Date: Tue, 24 Sep 2013 10:41:51 +0800
From: Zhang Yanfei <zhangyanfei@...fujitsu.com>
To: Tejun Heo <tj@...nel.org>
CC: Zhang Yanfei <zhangyanfei.yes@...il.com>,
Tang Chen <tangchen@...fujitsu.com>, rjw@...k.pl,
lenb@...nel.org, tglx@...utronix.de, mingo@...e.hu, hpa@...or.com,
akpm@...ux-foundation.org, toshi.kani@...com,
liwanp@...ux.vnet.ibm.com, trenn@...e.de, yinghai@...nel.org,
jiang.liu@...wei.com, wency@...fujitsu.com, laijs@...fujitsu.com,
isimatu.yasuaki@...fujitsu.com, izumi.taku@...fujitsu.com,
mgorman@...e.de, minchan@...nel.org, mina86@...a86.com,
gong.chen@...ux.intel.com, vasilis.liaskovitis@...fitbricks.com,
lwoodman@...hat.com, riel@...hat.com, jweiner@...hat.com,
prarit@...hat.com, x86@...nel.org, linux-doc@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-mm@...ck.org,
linux-acpi@...r.kernel.org
Subject: Re: [PATCH v3 2/5] memblock: Improve memblock to support allocation
from lower address.
Hello tejun,
On 09/24/2013 04:21 AM, Tejun Heo wrote:
> Hello,
>
> On Tue, Sep 24, 2013 at 02:07:13AM +0800, Zhang Yanfei wrote:
>> Yes, I am following your advice in principle but kind of confused by
>> something you said above. Where should the set_memblock_alloc_above_kernel
>> be used? IMO, the function is like:
>>
>> find_in_range_node()
>> {
>> if (ok) {
>> /* bottom-up */
>> ret = __memblock_find_in_range(max(start, _end_of_kernel), end...);
>> if (!ret)
>> return ret;
>> }
>>
>> /* top-down retry */
>> return __memblock_find_in_range_rev(start, end...)
>> }
>>
>> For bottom-up allocation, we always start from max(start, _end_of_kernel).
>
> Oh, I was talking about naming of the memblock_set_bottom_up()
> function. We aren't really doing pure bottom up allocations, so I
> think it probably would be clearer if the name clearly denotes that
> we're doing above-kernel allocation.
I see. But I think memblock_set_alloc_above_kernel may lose the info
that we are doing bottom-up allocation. So my idea is we introduce
pure bottom-up allocation mode in previous patches and we use the
bottom-up allocation here and limit the start address above the kernel
, with explicit comments to indicate this.
How do you think?
Thanks.
>
> Thanks.
>
--
Thanks.
Zhang Yanfei
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists