Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757185Ab3EHQ0l (ORCPT ); Wed, 8 May 2013 12:26:41 -0400 Received: from mail-la0-f47.google.com ([209.85.215.47]:34331 "EHLO mail-la0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757018Ab3EHQ0j (ORCPT ); Wed, 8 May 2013 12:26:39 -0400 Message-ID: <518A7CC0.1010606@cogentembedded.com> Date: Wed, 08 May 2013 20:26:40 +0400 From: Sergei Shtylyov User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:16.0) Gecko/20121010 Thunderbird/16.0.1 MIME-Version: 1.0 To: Jiang Liu CC: Andrew Morton , Jiang Liu , David Rientjes , Wen Congyang , Mel Gorman , Minchan Kim , KAMEZAWA Hiroyuki , Michal Hocko , James Bottomley , David Howells , Mark Salter , Jianguo Wu , linux-mm@kvack.org, linux-arch@vger.kernel.org, linux-kernel@vger.kernel.org, Yoshinori Sato , Geert Uytterhoeven Subject: Re: [PATCH v5, part4 20/41] mm/h8300: prepare for removing num_physpages and simplify mem_init() References: <1368028298-7401-1-git-send-email-jiang.liu@huawei.com> <1368028298-7401-21-git-send-email-jiang.liu@huawei.com> In-Reply-To: <1368028298-7401-21-git-send-email-jiang.liu@huawei.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1666 Lines: 46 Hello. On 08-05-2013 19:51, Jiang Liu wrote: > Prepare for removing num_physpages and simplify mem_init(). > Signed-off-by: Jiang Liu > Cc: Yoshinori Sato > Cc: Geert Uytterhoeven > Cc: linux-kernel@vger.kernel.org > --- > arch/h8300/mm/init.c | 34 ++++++++-------------------------- > 1 file changed, 8 insertions(+), 26 deletions(-) > diff --git a/arch/h8300/mm/init.c b/arch/h8300/mm/init.c > index 22fd869..0088f3a 100644 > --- a/arch/h8300/mm/init.c > +++ b/arch/h8300/mm/init.c > @@ -121,40 +121,22 @@ void __init paging_init(void) > > void __init mem_init(void) > { > - int codek = 0, datak = 0, initk = 0; > - /* DAVIDM look at setup memory map generically with reserved area */ > - unsigned long tmp; > - extern unsigned long _ramend, _ramstart; > - unsigned long len = &_ramend - &_ramstart; > - unsigned long start_mem = memory_start; /* DAVIDM - these must start at end of kernel */ > - unsigned long end_mem = memory_end; /* DAVIDM - this must not include kernel stack at top */ > + unsigned long codesize = _etext - _stext; > > #ifdef DEBUG > - printk(KERN_DEBUG "Mem_init: start=%lx, end=%lx\n", start_mem, end_mem); > + pr_debug("Mem_init: start=%lx, end=%lx\n", memory_start, memory_end); > #endif pr_debug() only prints something if DEBUG is #define'd, so you can drop the #ifdef here. WBR, Sergei -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/