From patchwork Wed Feb 27 02:28:07 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joseph Lo X-Patchwork-Id: 223468 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id E60862C0084 for ; Wed, 27 Feb 2013 13:28:27 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932186Ab3B0C21 (ORCPT ); Tue, 26 Feb 2013 21:28:27 -0500 Received: from hqemgate04.nvidia.com ([216.228.121.35]:3161 "EHLO hqemgate04.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932124Ab3B0C21 (ORCPT ); Tue, 26 Feb 2013 21:28:27 -0500 Received: from hqnvupgp06.nvidia.com (Not Verified[216.228.121.13]) by hqemgate04.nvidia.com id ; Tue, 26 Feb 2013 18:28:18 -0800 Received: from hqemhub02.nvidia.com ([172.17.108.22]) by hqnvupgp06.nvidia.com (PGP Universal service); Tue, 26 Feb 2013 18:26:42 -0800 X-PGP-Universal: processed; by hqnvupgp06.nvidia.com on Tue, 26 Feb 2013 18:26:42 -0800 Received: from jlo-ubuntu-64.nvidia.com (172.20.144.16) by hqemhub02.nvidia.com (172.20.150.31) with Microsoft SMTP Server (TLS) id 8.3.297.1; Tue, 26 Feb 2013 18:28:23 -0800 From: Joseph Lo To: Stephen Warren CC: , , Joseph Lo Subject: [PATCH V2 4/4] ARM: tegra114: bring up secondary CPU for SMP Date: Wed, 27 Feb 2013 10:28:07 +0800 Message-ID: <1361932087-13372-5-git-send-email-josephl@nvidia.com> X-Mailer: git-send-email 1.8.1.1 In-Reply-To: <1361932087-13372-1-git-send-email-josephl@nvidia.com> References: <1361932087-13372-1-git-send-email-josephl@nvidia.com> X-NVConfidentiality: public MIME-Version: 1.0 Sender: linux-tegra-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-tegra@vger.kernel.org The secondary CPU can be brought up by toggling the power in PMC. Then the flow controller will release CPU to go by clearing the reset and clamp signal automatically. Based on the work by: Bo Yan Signed-off-by: Joseph Lo --- V2: * no change --- arch/arm/mach-tegra/platsmp.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/arch/arm/mach-tegra/platsmp.c b/arch/arm/mach-tegra/platsmp.c index 601bd0c..516aab2 100644 --- a/arch/arm/mach-tegra/platsmp.c +++ b/arch/arm/mach-tegra/platsmp.c @@ -146,6 +146,12 @@ remove_clamps: return 0; } +static int tegra114_boot_secondary(unsigned int cpu, struct task_struct *idle) +{ + cpu = cpu_logical_map(cpu); + return tegra_pmc_cpu_power_on(cpu); +} + static int __cpuinit tegra_boot_secondary(unsigned int cpu, struct task_struct *idle) { @@ -153,6 +159,8 @@ static int __cpuinit tegra_boot_secondary(unsigned int cpu, return tegra20_boot_secondary(cpu, idle); if (IS_ENABLED(CONFIG_ARCH_TEGRA_3x_SOC) && tegra_chip_id == TEGRA30) return tegra30_boot_secondary(cpu, idle); + if (IS_ENABLED(CONFIG_ARCH_TEGRA_114_SOC) && tegra_chip_id == TEGRA114) + return tegra114_boot_secondary(cpu, idle); return -EINVAL; }