Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp3363954pxu; Tue, 15 Dec 2020 05:26:36 -0800 (PST) X-Google-Smtp-Source: ABdhPJycLoENCHUBGYTDkGOMiZQqzYvqv19MWefYkRYngLQjNnpet2jrWtt+ZO5qFCBYfM1US2fD X-Received: by 2002:a17:906:314f:: with SMTP id e15mr5956109eje.496.1608038795811; Tue, 15 Dec 2020 05:26:35 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1608038795; cv=none; d=google.com; s=arc-20160816; b=LeJIn/cd4aIUqfUkkwOkJG0nGtizvXH1EkRhwEfcI1NvZAva/cEVcxwiMc23wJPTn7 nhgoqFIqE+VDGggzsFDHmfk4cIrD6XFB07uH7L6pAintFBBx9N5m7n+PuY1oeL8L3gim fGBBecD+seXda7cSuQR54pRIIaS1QghLSwt+cMKEyR7W7Ak7C9DPnBGY7cnRgfFDMxU8 1qNi+R2X6gaSZCjx5N6DYKSIMTVaB1lxl7kJiEUaU3EXp99xrbKaf/PlNkkcTpOWXXqn 9i57oqxBhU5rxGyZnvoPBB75sDzltLNCC5kUnjThBXVdLnH24NdksVp62m/axI7me1H6 6NPA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=bkxdQtF0PSyxWHsF/N3b/gLuk8Ynw/zX/sNAWEcvgGQ=; b=I84hAW2iu9q3MgmpTNWgH7Mo0oPz43NyADHZ7ku0hlTDjH+PUNueYhZ9J/FJUyq+rY vW/9kJ9Wd3AbBqLSuxRbNg5k1qw/IMYnfCVhUHzMRRzrtMTUUP/wha03DyYG71PG8WMC iBF4YojAjVDiJEBfcL6Cwa4TRpIhs72/cCtVhkizj1bhz3rC4dhMiQQ5haXphDW7+5Vf Upb44ddhzcHLzDOtGGuZj62xRPpCA9CNL7SdSISn92MendRxQ8qzHvyZTAmZRBQ4TqcZ p12n4TnazTrNGqf2QqEv0kAwx+9TRqPa0nOs8TiDOnxP3FPTd3mcWyNEJRTXZim6JV05 irnQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c1si792469edk.605.2020.12.15.05.26.11; Tue, 15 Dec 2020 05:26:35 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727069AbgLONW5 (ORCPT + 99 others); Tue, 15 Dec 2020 08:22:57 -0500 Received: from elvis.franken.de ([193.175.24.41]:42248 "EHLO elvis.franken.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726580AbgLONW5 (ORCPT ); Tue, 15 Dec 2020 08:22:57 -0500 Received: from uucp (helo=alpha) by elvis.franken.de with local-bsmtp (Exim 3.36 #1) id 1kpAHO-0001tH-00; Tue, 15 Dec 2020 14:22:14 +0100 Received: by alpha.franken.de (Postfix, from userid 1000) id DA36FC0386; Tue, 15 Dec 2020 14:21:23 +0100 (CET) Date: Tue, 15 Dec 2020 14:21:23 +0100 From: Thomas Bogendoerfer To: Tiezhu Yang Cc: Huacai Chen , Jiaxun Yang , linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, Xuefeng Li , Youling Tang , Jinyang He Subject: Re: [PATCH] MIPS: Loongson64: Give chance to build under !CONFIG_NUMA and !CONFIG_SMP Message-ID: <20201215132123.GA9201@alpha.franken.de> References: <1606998772-5904-1-git-send-email-yangtiezhu@loongson.cn> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1606998772-5904-1-git-send-email-yangtiezhu@loongson.cn> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Dec 03, 2020 at 08:32:52PM +0800, Tiezhu Yang wrote: > In the current code, we can not build under !CONFIG_NUMA and !CONFIG_SMP > on the Loongson64 platform, it seems bad for the users who just want to > use pure single core (not nosmp) to debug, so do the following things to > give them a chance: > > (1) Do not select NUMA and SMP for MACH_LOONGSON64 in Kconfig, make NUMA > depends on SMP, and then just set them in the loongson3_defconfig. > (2) Move szmem() from numa.c to init.c and add prom_init_memory() under > !CONFIG_NUMA. > (3) Clean up szmem() due to the statements of case SYSTEM_RAM_LOW and > SYSTEM_RAM_HIGH are the same. > (4) Remove the useless declaration of prom_init_memory() and add the > declaration of szmem() in loongson.h to avoid build error. > > Signed-off-by: Youling Tang > Signed-off-by: Jinyang He > Signed-off-by: Tiezhu Yang > --- > arch/mips/Kconfig | 3 +- > arch/mips/configs/loongson3_defconfig | 2 + > arch/mips/include/asm/mach-loongson64/loongson.h | 2 +- > arch/mips/loongson64/init.c | 49 ++++++++++++++++++++++ > arch/mips/loongson64/numa.c | 52 +----------------------- > 5 files changed, 54 insertions(+), 54 deletions(-) > > diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig > index 44a47ad..2034c66 100644 > --- a/arch/mips/Kconfig > +++ b/arch/mips/Kconfig > @@ -490,8 +490,6 @@ config MACH_LOONGSON64 > select SYS_SUPPORTS_ZBOOT > select SYS_SUPPORTS_RELOCATABLE > select ZONE_DMA32 > - select NUMA > - select SMP > select COMMON_CLK > select USE_OF > select BUILTIN_DTB > @@ -2755,6 +2753,7 @@ config ARCH_SPARSEMEM_ENABLE > config NUMA > bool "NUMA Support" > depends on SYS_SUPPORTS_NUMA > + depends on SMP can you solve your problem without this hunk ? I don't want to make NUMA depeding on SMP. NUMA just selects memory archtitecture. Thomas. -- Crap can work. Given enough thrust pigs will fly, but it's not necessarily a good idea. [ RFC1925, 2.3 ]