From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 16893C433E0 for ; Thu, 7 Jan 2021 12:33:42 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C286A23356 for ; Thu, 7 Jan 2021 12:33:41 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C286A23356 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Type: Content-Transfer-Encoding:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date:Message-ID:From: References:To:Subject:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=hDy+8S9bnzIljGFPzd2Cvp2xWl5VJmIgZRvfBDZxxwM=; b=IkBXnHTzVBRXI3r8hoWjRKClM 38Tfs3qYSO5mEwwiNObLGm37ve2+MjgcvUr2T8YfBGLvW+CukijoF6Wnq9VFDYWkeSBWsY+rwefzx iOnXJXr3LN5LzWzxDM82J5FyH6VNclp/V64yXQcXIaj3LGBe5kwRzs3HsCw0BJpwy86nb7qvnnLDD ACjWRnQ4hBPuGXROdYlVGbRWqG86PuV7mICCj3UzANeZfi+UWZdv+5r1QUF7pfRuOtxFrsUNGS161 eZyAsOH6KMDaWp5pSBO+xFCeVlJrg9oP1iAZRfjN1zcojJOu0BGZfvXRMMeQRnFkQAg6FTmdchn6c O7GmDzM2w==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kxUSq-000560-C8; Thu, 07 Jan 2021 12:32:28 +0000 Received: from mail-out.m-online.net ([212.18.0.9]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kxUSo-00053w-Et for linux-arm-kernel@lists.infradead.org; Thu, 07 Jan 2021 12:32:27 +0000 Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 4DBQbs1H5Jz1qs3n; Thu, 7 Jan 2021 13:32:25 +0100 (CET) Received: from localhost (dynscan1.mnet-online.de [192.168.6.70]) by mail.m-online.net (Postfix) with ESMTP id 4DBQbs0TmDz1sFX9; Thu, 7 Jan 2021 13:32:25 +0100 (CET) X-Virus-Scanned: amavisd-new at mnet-online.de Received: from mail.mnet-online.de ([192.168.8.182]) by localhost (dynscan1.mail.m-online.net [192.168.6.70]) (amavisd-new, port 10024) with ESMTP id LDhDXT7wlG9D; Thu, 7 Jan 2021 13:32:23 +0100 (CET) X-Auth-Info: u9puUw1KHqTHBlbbmYQBYH6XOr0bvNyQelP5LfAKBsY= Received: from [IPv6:::1] (p578adb1c.dip0.t-ipconnect.de [87.138.219.28]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.mnet-online.de (Postfix) with ESMTPSA; Thu, 7 Jan 2021 13:32:23 +0100 (CET) Subject: Re: [PATCH] [RFC] ARM: imx: add smp support for imx7d To: Shawn Guo References: <20200917160814.97995-1-marex@denx.de> <20201026144050.GJ9880@dragon> From: Marek Vasut Message-ID: <2293c2d4-4dc6-04fc-4ec3-80ffe1b318cb@denx.de> Date: Thu, 7 Jan 2021 13:09:23 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.6.0 MIME-Version: 1.0 In-Reply-To: <20201026144050.GJ9880@dragon> Content-Language: en-US X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210107_073226_648911_5A765242 X-CRM114-Status: GOOD ( 19.28 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Arulpandiyan Vadivel , Anson Huang , Leonard Crestez , Fabio Estevam , linux-arm-kernel@lists.infradead.org, NXP Linux Team Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 10/26/20 3:40 PM, Shawn Guo wrote: [...] >> diff --git a/arch/arm/mach-imx/common.h b/arch/arm/mach-imx/common.h >> index 72c3fcc32910..de4383aa6a08 100644 >> --- a/arch/arm/mach-imx/common.h >> +++ b/arch/arm/mach-imx/common.h >> @@ -84,11 +84,13 @@ void imx_set_cpu_arg(int cpu, u32 arg); >> void v7_secondary_startup(void); >> void imx_scu_map_io(void); >> void imx_smp_prepare(void); >> +void imx_gpcv2_set_core1_pdn_pup_by_software(bool pdn); > > Why does it need to be protected by #ifdef CONFIG_SMP? Because the code is useless on UP system. [...] >> diff --git a/arch/arm/mach-imx/headsmp.S b/arch/arm/mach-imx/headsmp.S >> index 766dbdb2ae27..fcba58be8e79 100644 >> --- a/arch/arm/mach-imx/headsmp.S >> +++ b/arch/arm/mach-imx/headsmp.S >> @@ -21,6 +21,15 @@ diag_reg_offset: >> >> ENTRY(v7_secondary_startup) >> ARM_BE8(setend be) @ go BE8 if entered LE >> + mrc p15, 0, r0, c0, c0, 0 >> + lsl r0, r0, #16 >> + lsr r0, r0, #20 >> + /* 0xc07 is cortex A7's ID */ >> + mov r1, #0xc00 >> + orr r1, #0x7 >> + cmp r0, r1 >> + beq secondary_startup > > Can we branch to 'b secondary_startup' below via some label, so that we > have a single entry to secondary_startup? That would make this code less efficient, wouldn't it. [...] >> static int ls1021a_boot_secondary(unsigned int cpu, struct task_struct *idle) >> diff --git a/arch/arm/mach-imx/src.c b/arch/arm/mach-imx/src.c >> index f52f371292ac..326c7097fc25 100644 >> --- a/arch/arm/mach-imx/src.c >> +++ b/arch/arm/mach-imx/src.c >> @@ -12,9 +12,12 @@ [...] >> static void __iomem *src_base; >> static DEFINE_SPINLOCK(scr_lock); >> +static bool gpr_v2; >> +static void __iomem *gpc_base; > > This is kinda a SRC driver. I'm a bit uncomfortable to have GPC code > dumped in here. More importantly, will the GPC code added here have > any race condition with GPCv2 driver (drivers/soc/imx/gpcv2.c)? Not that I am aware of. [...] _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel