From patchwork Thu May 6 01:04:40 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Peng Fan (OSS)" X-Patchwork-Id: 12241399 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=-17.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,MSGID_FROM_MTA_HEADER,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT 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 CEFACC433B4 for ; Thu, 6 May 2021 00:38:36 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (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 4F4DD61185 for ; Thu, 6 May 2021 00:38:36 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4F4DD61185 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=oss.nxp.com 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=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=QUJoKxDG64o9Wf/qhaUGAg4hKgjVpD4QrX0GflDQr1o=; b=apLd6DFPOe4wQ96yvOJNpv75m 62dsra5WRzvC6jrmp+HT9y+lNe/FJNxh+QtOh8FXj9W3mhOYdi9DIDdsAH4VB3i/f3yeMGcly50YD BDOgNGJjT6mglG48o+XAoOIIxwRQjLPshY+ayM+Rcy8kdaXiat0nPJ5QDvvtHyESo0rQJY5Fc243Y Zd8KAIUZErdw9JXFBDhzHfL685jNMVlL3Hu5LiQz22QZ+at5MWbRrWnXzzIhmNQJ2Ay/JvZd/eY1l xJM1THwELIbLeVAH34pXhGG1kOSKWDFwwxMxNzdy6OXN+iogInaHortEW4lTsjDeClJYUSp2K2JEs QyQX6CyVA==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1leS0K-002ilZ-9E; Thu, 06 May 2021 00:36:37 +0000 Received: from bombadil.infradead.org ([2607:7c80:54:e::133]) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1leRxd-002hiM-4v for linux-arm-kernel@desiato.infradead.org; Thu, 06 May 2021 00:33:49 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=MIME-Version:Content-Type: Content-Transfer-Encoding:References:In-Reply-To:Message-Id:Date:Subject:Cc: To:From:Sender:Reply-To:Content-ID:Content-Description; bh=c6QVYSOpg6OI1/lGSqpz04ydUyaxyFOFKNDWb1So/pQ=; b=fRqfHH0V/ZDSLgKwwSuTQAsKt7 4OCrLrWWBfL3rn615SC+2mXtmH433LJRztv1n4qugKrO76hd1m32trWXs588sFMwfuu34O8WCDu2O RREVdLSdGsVs6KiJnJ4I0fQmbqbcS0xN2OiXbJ6AHn8WcchTqeSfwXPebzo7CQad1kcGVgri+pTmR 37p+uadJmM3orXCup8Kb297PD7MSA0OBB+VirUZx9Tx+CGbca4c61zW+FHKU2uWoNsbmGR5CtnI5q deo+vo/19/+ZaBzaN3jRYnaOCpa0KytdA8sewJ3AUJZshqKq/tiIPW0aqA1cd47NU07txH1KSSeVh eumUCpkQ==; Received: from mail-eopbgr70057.outbound.protection.outlook.com ([40.107.7.57] helo=EUR04-HE1-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1leRxa-005RKA-MM for linux-arm-kernel@lists.infradead.org; Thu, 06 May 2021 00:33:47 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RTy8d+ri+g8KtOR9TSGcWsBavpP98lCZlBpicVipRMaxs0vVHd7f+LXMBEKOyRddf3D8AZ5/CSBbvUWK1f0vM9CsikaOIGFe+GdqP90tFeL6QH7BXgnfyS1FOQ0rWV0GbWrbCDs5OmpFvts68OI45FuUduImSWmF/4vkBnRfSBnZTU5VIELXa+Z+qnXTtOrc31BYcNs/SnCriU8TjewZsgo0nu5A2oGKX2EG/8ux4xrbsmVVwlO/Lijj+4Rd2LWuBTEoJ/hAwheryWyZy4QCqJrCmO4CcClTHnXTkMMOYUx2aD2R8h7OzF/Gu0G83jsjH4FHyucrq1KYcbSRBb//SA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=c6QVYSOpg6OI1/lGSqpz04ydUyaxyFOFKNDWb1So/pQ=; b=APoWUDAm//vX0OHrMZO+j57TR97g0aIu9XU+wSUJQ6TVQjuDYkcFL9ZDCPKKkUXUDtBkOVnsHrOj9KyTT6D1RNn2FZ+fQqId+VYE+cwTYSToih4efLcAzc4o1zuKZMBCX27hscGL/Rye8CM8zexd3/g7n4WADkvh5LPTxtzz54v8qOFJu2cNty8W791p+BcpgCb0QPiCID0unkUMSdoZC6juq65+bn9PmXA/GzaIsDSKg+JdvG811M+hI1FXw19pSEdS6IsKuWTLp80uBwBBZhFmmXJr7ZBT9evwBRAxwTaMD1nqbRCefnSd9PhL5RxjHO/mp7OfCdzVJcDg8xbcQA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oss.nxp.com; dmarc=pass action=none header.from=oss.nxp.com; dkim=pass header.d=oss.nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=NXP1.onmicrosoft.com; s=selector2-NXP1-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=c6QVYSOpg6OI1/lGSqpz04ydUyaxyFOFKNDWb1So/pQ=; b=H6TVB0V06c+VYLqainKwsCWYsBG8/RHC3H0r3gUPPYs1V26w5LIP0Zp3+j2I0vGDS7dU3Fu1d2Ux8awcHLLL3IMaVGb8wM8w2yGAMTG/SEbgKo1G7dZaaRljiLNmX95HJgV5y3xNwLekUiav7nGzgOURePpyAhOgFyjenUvDyPw= Authentication-Results: kernel.org; dkim=none (message not signed) header.d=none;kernel.org; dmarc=none action=none header.from=oss.nxp.com; Received: from DB6PR0402MB2760.eurprd04.prod.outlook.com (2603:10a6:4:a1::14) by DBBPR04MB7884.eurprd04.prod.outlook.com (2603:10a6:10:1f2::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4087.41; Thu, 6 May 2021 00:33:43 +0000 Received: from DB6PR0402MB2760.eurprd04.prod.outlook.com ([fe80::45b9:c993:87ec:9a64]) by DB6PR0402MB2760.eurprd04.prod.outlook.com ([fe80::45b9:c993:87ec:9a64%8]) with mapi id 15.20.4065.039; Thu, 6 May 2021 00:33:43 +0000 From: "Peng Fan (OSS)" To: robh+dt@kernel.org, shawnguo@kernel.org, s.hauer@pengutronix.de Cc: kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, p.zabel@pengutronix.de, l.stach@pengutronix.de, krzk@kernel.org, agx@sigxcpu.org, marex@denx.de, andrew.smirnov@gmail.com, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, ping.bai@nxp.com, frieder.schrempf@kontron.de, aford173@gmail.com, abel.vesa@nxp.com, Peng Fan Subject: [PATCH V2 13/13] soc: imx: gpcv2: move reset assert after requesting domain power up Date: Thu, 6 May 2021 09:04:40 +0800 Message-Id: <20210506010440.7016-14-peng.fan@oss.nxp.com> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20210506010440.7016-1-peng.fan@oss.nxp.com> References: <20210506010440.7016-1-peng.fan@oss.nxp.com> X-Originating-IP: [119.31.174.71] X-ClientProxiedBy: SGAP274CA0010.SGPP274.PROD.OUTLOOK.COM (2603:1096:4:b6::22) To DB6PR0402MB2760.eurprd04.prod.outlook.com (2603:10a6:4:a1::14) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from linux-1xn6.ap.freescale.net (119.31.174.71) by SGAP274CA0010.SGPP274.PROD.OUTLOOK.COM (2603:1096:4:b6::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4108.24 via Frontend Transport; Thu, 6 May 2021 00:33:37 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: f7b7ea42-8fcf-4f5a-c3e7-08d910269a1a X-MS-TrafficTypeDiagnostic: DBBPR04MB7884: X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:6108; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: ll1AA/PQqs0bIx/rHNwxAP1TkIW1uQgzdK7zy69RawoQaxgD+2uB60vce3ol8OeB2+fpZ1ZhWGEwPT/SAAu7A7nsVZ2UCLCotUtX4EtPCT6LOXJLFned0ptBL4EBBqSw4pj0/QBsCdfhhCykEVDDsQ9ABONcV6286PyxIO8p5MaFboY4CKbmft4fZx6AD1p3ztGNO1+cS8ZoNlMJZGqg75VQHLXPfBIkHblBoHZJ6wrAAjIhgRwjCyrbIv8t/KQuJhMBHMsEVP3LOh1U81Fg20MaYZdSemVkEvRn2J/6Ee4+0CLV/1NXChBJas1RR5tkveHNLbCUPDcriLmrxPJ237GsN84tVTzzQlVk3O3szmCHNOjx0Rqrn2/XMF9SK6rTUTVSZa9byJUhUQSNVXGuewPtaDVE7CqyOLrf/ci+OWUuIoP2HYsiseko998UwD8lYcpdKt5DPz9Yyd3AXFbnvADfomNuNQXqONeyEfy258zcyjrhK0Pul59578nYQIs6zNdh0lS0zI44iKJqCkr5mNt6/siD9LrxmYxtJ+AyhSUWgSjh1O6/pcje/9sb5dLBJgZJPBFjeCUBDF4EfUnGmiqDYxebHRhV6J8hYRecpHEfwqA3rHvXegoE/lojR+1Ipfv4jmGdj3H3iF9WlVT8gA== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DB6PR0402MB2760.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(376002)(366004)(346002)(396003)(39860400002)(136003)(52116002)(186003)(6666004)(5660300002)(6512007)(478600001)(2906002)(1076003)(26005)(6506007)(16526019)(6486002)(83380400001)(956004)(8936002)(86362001)(8676002)(38350700002)(316002)(38100700002)(66946007)(66476007)(2616005)(66556008)(4326008)(7416002); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData: 3ueNzCKQDATkcM5cgDMx56GgmzrJufEddYLBRBbn3h83zG8jj9yHFpz2p01/LmT9xKRaTjUhw7Ef4w9GsBPr9/ZwWyv5r33wLChZHpZGAEekNZS09DAoqcVezq1B6mpJTv+RcNXOZ6itSlPRh3rCPFvoFzxGjD1Kn8Zhq1w6FjyvAoqFTYDpqZReBLt8E7OcwalVkk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6ijUVTe+XgFaPp1gxagna23yjFZrwRDtxiAxa1o3hxbKZJoyOZnnJ9vOUnEprcUCavOgTfsAlvT X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: f7b7ea42-8fcf-4f5a-c3e7-08d910269a1a X-MS-Exchange-CrossTenant-AuthSource: DB6PR0402MB2760.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 May 2021 00:33:43.2911 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Q5iysvq/Y3rx7FyuaFopXWoZGZMV3O7psWAeBC8GjFaleWApUH5h4/oyrZ/7VC7tMXM6U98gAiTomQ1ANxDt9g== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DBBPR04MB7884 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210505_173346_755703_0C21B8C6 X-CRM114-Status: GOOD ( 11.51 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Peng Fan The i.MX8MM VPU power up sequence is a bit special, it must follow: 1. request power up 2. reset assert 3. reset deassert This change in this patch will not affect other domains, because the power domain default is in asserted state, unless bootloader deassert the reset. It also applies to GPU power domain. Signed-off-by: Peng Fan Reviewed-by: Frieder Schrempf Tested-by: Frieder Schrempf --- drivers/soc/imx/gpcv2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/soc/imx/gpcv2.c b/drivers/soc/imx/gpcv2.c index 65b562cbcc6d..325a34833ffa 100644 --- a/drivers/soc/imx/gpcv2.c +++ b/drivers/soc/imx/gpcv2.c @@ -217,8 +217,6 @@ static int imx_pgc_power_up(struct generic_pm_domain *genpd) goto out_regulator_disable; } - reset_control_assert(domain->reset); - if (domain->bits.pxx) { /* request the domain to power up */ regmap_update_bits(domain->regmap, GPC_PU_PGC_SW_PUP_REQ, @@ -241,6 +239,8 @@ static int imx_pgc_power_up(struct generic_pm_domain *genpd) GPC_PGC_CTRL_PCR); } + reset_control_assert(domain->reset); + /* delay for reset to propagate */ udelay(5);