From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758487Ab0FPFrI (ORCPT ); Wed, 16 Jun 2010 01:47:08 -0400 Received: from rcsinet10.oracle.com ([148.87.113.121]:28712 "EHLO rcsinet10.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757427Ab0FPFqs (ORCPT ); Wed, 16 Jun 2010 01:46:48 -0400 From: Yinghai Lu To: Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , Andrew Morton , Benjamin Herrenschmidt Cc: David Miller , Linus Torvalds , Johannes Weiner , linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, Yinghai Lu Subject: [PATCH 27/37] x86: Have nobootmem version setup_bootmem_allocator() Date: Tue, 15 Jun 2010 22:42:36 -0700 Message-Id: <1276666966-14259-28-git-send-email-yinghai@kernel.org> X-Mailer: git-send-email 1.6.4.2 In-Reply-To: <1276666966-14259-1-git-send-email-yinghai@kernel.org> References: <1276666966-14259-1-git-send-email-yinghai@kernel.org> X-Auth-Type: Internal IP X-Source-IP: rcsinet13.oracle.com [148.87.113.125] X-CT-RefId: str=0001.0A090205.4C186508.0068,ss=1,fgs=0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org We can reduce #ifdef number from 3 to one in init_32.c Signed-off-by: Yinghai Lu --- arch/x86/mm/init_32.c | 15 ++++++++++----- 1 files changed, 10 insertions(+), 5 deletions(-) diff --git a/arch/x86/mm/init_32.c b/arch/x86/mm/init_32.c index e3ae067..f172aa3 100644 --- a/arch/x86/mm/init_32.c +++ b/arch/x86/mm/init_32.c @@ -771,11 +771,9 @@ static unsigned long __init setup_node_bootmem(int nodeid, return bootmap + bootmap_size; } -#endif void __init setup_bootmem_allocator(void) { -#ifndef CONFIG_NO_BOOTMEM int nodeid; unsigned long bootmap_size, bootmap; /* @@ -787,13 +785,11 @@ void __init setup_bootmem_allocator(void) if (bootmap == (unsigned long)LMB_ERROR) panic("Cannot find bootmem map of size %ld\n", bootmap_size); lmb_reserve_range(bootmap, bootmap + bootmap_size, "BOOTMAP"); -#endif printk(KERN_INFO " mapped low ram: 0 - %08lx\n", max_pfn_mapped<