From patchwork Mon Aug 4 02:58:00 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Haojian Zhuang X-Patchwork-Id: 34753 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-qg0-f70.google.com (mail-qg0-f70.google.com [209.85.192.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id F1FA4204FF for ; Mon, 4 Aug 2014 03:03:04 +0000 (UTC) Received: by mail-qg0-f70.google.com with SMTP id z60sf13509653qgd.1 for ; Sun, 03 Aug 2014 20:03:04 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:subject:date:message-id :in-reply-to:references:cc:precedence:list-id:list-unsubscribe :list-archive:list-post:list-help:list-subscribe:mime-version:sender :errors-to:x-original-sender:x-original-authentication-results :mailing-list:content-type:content-transfer-encoding; bh=BDXBrl5vC2KnNFWud/Jmp/DLZMdP38G4bHgIsMfEOps=; b=S/b0O9j/tgApj06DNDHDUSnJzh6ElCt3C3CoJzyba+GRakcb0fyqohVVBTOKSMlXdr frNdCNSmUMmFSXNHaEJxcq7JK7zgtUWan4/rGu4BLyOJY0hVEQzgd0CjgGczxim8nsQ6 3zkSsQKTJuVq0lrLfehCFaFoXoKTwSMpzi7l4MoUYTW4Czq6SMAAQK1zk1ZbnEjDk5gQ sI9wttgvt67BIPQOhMj/9kQLY8U7NZLFe4PqXOmdLw20+gFuM82fothy3qee2uTb66Nh RqDRoaEAcJcv86G9gX+5hI9eKSjyTPkahbD4PjkfyYIcvBpzdGzogwFQZpr7aDjdkbe1 CZpw== X-Gm-Message-State: ALoCoQk/oq31C+OhaxEYOpNO1ppsEPStNUV3T4jWsg3blIfajmEpkOgq+7oSLGFW2M+zmIDAOrdD X-Received: by 10.236.1.198 with SMTP id 46mr6766150yhd.16.1407121384769; Sun, 03 Aug 2014 20:03:04 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.35.232 with SMTP id n95ls1930246qgn.23.gmail; Sun, 03 Aug 2014 20:03:04 -0700 (PDT) X-Received: by 10.220.163.130 with SMTP id a2mr460466vcy.52.1407121384693; Sun, 03 Aug 2014 20:03:04 -0700 (PDT) Received: from mail-vc0-f176.google.com (mail-vc0-f176.google.com [209.85.220.176]) by mx.google.com with ESMTPS id s2si11280557vco.17.2014.08.03.20.03.04 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 03 Aug 2014 20:03:04 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.176 as permitted sender) client-ip=209.85.220.176; Received: by mail-vc0-f176.google.com with SMTP id id10so10030660vcb.7 for ; Sun, 03 Aug 2014 20:03:04 -0700 (PDT) X-Received: by 10.220.182.73 with SMTP id cb9mr20746854vcb.9.1407121384612; Sun, 03 Aug 2014 20:03:04 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.37.5 with SMTP id tc5csp267780vcb; Sun, 3 Aug 2014 20:03:04 -0700 (PDT) X-Received: by 10.70.65.100 with SMTP id w4mr637pds.128.1407121382717; Sun, 03 Aug 2014 20:03:02 -0700 (PDT) Received: from bombadil.infradead.org (bombadil.infradead.org. [2001:1868:205::9]) by mx.google.com with ESMTPS id tu1si16174120pbc.12.2014.08.03.20.03.02 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 03 Aug 2014 20:03:02 -0700 (PDT) Received-SPF: none (google.com: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org does not designate permitted sender hosts) client-ip=2001:1868:205::9; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1XE8W3-0007Zb-1Y; Mon, 04 Aug 2014 03:00:51 +0000 Received: from mail-pa0-f48.google.com ([209.85.220.48]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1XE8W1-0007WE-47 for linux-arm-kernel@lists.infradead.org; Mon, 04 Aug 2014 03:00:49 +0000 Received: by mail-pa0-f48.google.com with SMTP id et14so9133603pad.35 for ; Sun, 03 Aug 2014 20:00:27 -0700 (PDT) X-Received: by 10.66.253.170 with SMTP id ab10mr21276146pad.53.1407121227717; Sun, 03 Aug 2014 20:00:27 -0700 (PDT) Received: from localhost.localdomain ([98.126.25.141]) by mx.google.com with ESMTPSA id jb5sm15729523pbd.73.2014.08.03.20.00.18 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 03 Aug 2014 20:00:27 -0700 (PDT) From: Haojian Zhuang To: arnd@arndb.de, olof@lixom.net, marc.zyngier@arm.com, jason@lakedaemon.net, linux-arm-kernel@lists.infradead.org, nicolas.pitre@linaro.org, khilman@linaro.org, xuwei5@hisilicon.com, arm@kernel.org Subject: [PATCH v16 1/9] ARM: mcpm: support 4 clusters Date: Mon, 4 Aug 2014 10:58:00 +0800 Message-Id: <1407121088-4151-2-git-send-email-haojian.zhuang@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1407121088-4151-1-git-send-email-haojian.zhuang@linaro.org> References: <1407121088-4151-1-git-send-email-haojian.zhuang@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140803_200049_181426_619FFFE5 X-CRM114-Status: UNSURE ( 9.65 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -1.4 (-) X-Spam-Report: SpamAssassin version 3.4.0 on bombadil.infradead.org summary: Content analysis details: (-1.4 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [209.85.220.48 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -0.7 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.220.48 listed in wl.mailspike.net] Cc: Haojian Zhuang X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: haojian.zhuang@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.176 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 Add the CONFIG_MCPM_QUAD_CLUSTER configuration to enlarge cluster number from 2 to 4. Signed-off-by: Haojian Zhuang Reviewed-by: Nicolas Pitre --- arch/arm/Kconfig | 9 +++++++++ arch/arm/include/asm/mcpm.h | 5 +++++ 2 files changed, 14 insertions(+) diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 87b63fd..10cc6ec 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -1490,6 +1490,15 @@ config MCPM for (multi-)cluster based systems, such as big.LITTLE based systems. +config MCPM_QUAD_CLUSTER + bool + depends on MCPM + help + To avoid wasting resources unnecessarily, MCPM only supports up + to 2 clusters by default. + Platforms with 3 or 4 clusters that use MCPM must select this + option to allow the additional clusters to be managed. + config BIG_LITTLE bool "big.LITTLE support (Experimental)" depends on CPU_V7 && SMP diff --git a/arch/arm/include/asm/mcpm.h b/arch/arm/include/asm/mcpm.h index d9702eb..a4fbacc 100644 --- a/arch/arm/include/asm/mcpm.h +++ b/arch/arm/include/asm/mcpm.h @@ -20,7 +20,12 @@ * to consider dynamic allocation. */ #define MAX_CPUS_PER_CLUSTER 4 + +#ifdef CONFIG_MCPM_QUAD_CLUSTER +#define MAX_NR_CLUSTERS 4 +#else #define MAX_NR_CLUSTERS 2 +#endif #ifndef __ASSEMBLY__