Message ID | 20210719074734.29170-38-peng.fan@oss.nxp.com |
---|---|
State | Superseded |
Headers | show
Delivered-To: patch@linaro.org Received: by 2002:a02:c94a:0:0:0:0:0 with SMTP id u10csp3870800jao; Mon, 19 Jul 2021 00:20:38 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxssPdbiykub3cKTEeZmzCeSBAMpMGUpxCvWGHpbEtYWz/Uj0kPsa39ynWAvHKn3ZEg/k8Z X-Received: by 2002:a05:6402:3089:: with SMTP id de9mr33045778edb.69.1626679238564; Mon, 19 Jul 2021 00:20:38 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1626679238; cv=pass; d=google.com; s=arc-20160816; b=LIYvA50Q7tE2SUTZa9Tj0CCPf65S7CFIXObpZgROCEM1NbwAAUPDl55yoX6UqyE5PA pf1APW9oFRPVikkIl/nRhRrCdN3LYv1rHpALjCMQCWr8K3GLjo99KxL3ch1WqFjvaBRq TW9fECd38AJFdLGTIHdvcJMFfvUSGKfoyOm1KBDjEuFdytP4W/ncIXQL6paYEc7Y9Isj b7+qs8VxSYbhK36JaPD0O7FUFlkl6sjPAHIqAeRASxffvmdGXoQgR42d6tiq1rb1fOly B7MpN9VaXk4I2J2PwqfhU0bRW9V/fICLVkHLiobDuJr9HfcD09pCg/wErZdUvMuKcuF4 Lw+Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:mime-version :content-transfer-encoding:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=37D3VXzBFyND8sq8qpBZuo7YUfsH8MCjX7NdleHKAo8=; b=bJ209ZWK6f7ApR8GsW9VnCuGX0o4WSayH5kpn7ESwpJGTOeex7xfFmVEthmMhOpWrf i1nD4unZFQZdfNnpUzA+wQhHkWDmESU9bo53+Q943DJbhq/DlXSlKAKlQVqzG6lA4lEq ywneUmaMlrBkviRGERTFrPqA9A4o4SZ3zo+dpA4VLsQ3PDUMyduJjvjCEcuKi4kCYYtd bTMMa0CPrQ3u3Un1fF9+druOG7gNfB8w9PAP5NrNIVhJUPOKtPe2Kn5RmA+0Nh+zOAMU VMNDtY+A5CANuUgEXWt59Imx9pXd9fD5U+NJBeA0XbBUm1L+M2BTAsoiDPwKesKwoLsl dfrw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=AfTeXg4E; arc=pass (i=1 spf=pass spfdomain=oss.nxp.com dkim=pass dkdomain=oss.nxp.com dmarc=pass fromdomain=oss.nxp.com); spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: <u-boot-bounces@lists.denx.de> Received: from phobos.denx.de (phobos.denx.de. [2a01:238:438b:c500:173d:9f52:ddab:ee01]) by mx.google.com with ESMTPS id t12si25195567edc.333.2021.07.19.00.20.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Jul 2021 00:20:38 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; Authentication-Results: mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=AfTeXg4E; arc=pass (i=1 spf=pass spfdomain=oss.nxp.com dkim=pass dkdomain=oss.nxp.com dmarc=pass fromdomain=oss.nxp.com); spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id D828F82DB6; Mon, 19 Jul 2021 09:16:16 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=oss.nxp.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=NXP1.onmicrosoft.com header.i=@NXP1.onmicrosoft.com header.b="AfTeXg4E"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 9212D82CC6; Mon, 19 Jul 2021 09:15:17 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-0.6 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,FORGED_SPF_HELO,MSGID_FROM_MTA_HEADER,SPF_HELO_PASS autolearn=no autolearn_force=no version=3.4.2 Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-he1eur04on060f.outbound.protection.outlook.com [IPv6:2a01:111:f400:fe0d::60f]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 530BF82C90 for <u-boot@lists.denx.de>; Mon, 19 Jul 2021 09:15:10 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=oss.nxp.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=peng.fan@oss.nxp.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JdnQ6wJ5g1RxwnCPkgaJyVfZWEU6Z3T97lQK7gGvtDMJiC6OqHEJs41cE5k0Kf/h+xstI7VXzaXCvzCsdBpkK6PLkBV+V6eoaWBB8hZSM1hQ45AlXwZBqp7vdBwS+5XZjL8PI7l56sWUyMME25NAIok6TJuNszQD62sZgsEKrFAHdzutolOk4KVDoC2vfe5m63zF9jMb4elu5i6pvbDdjY81ECRVlqsPnRg9C/b182ESME7mwkmZerQa5jWiqAvYGrBW80MD+YD9c0lE8Juq6q8kexADPwy+F4FStbI+WW9nOBPOE60hXCwlxZXLrMTzjs5L2uiXVSB66vpU3M+MCA== 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=37D3VXzBFyND8sq8qpBZuo7YUfsH8MCjX7NdleHKAo8=; b=hvNx5dKY+v3VCZ/Ou4hU1Nd5OPes2n3xcGaSd6dxUhXyZe9sIfnggObeArOqmpCN/8WdJLF7oZAtHfD41A7B8PNA7HK9XXMtL5VNr1mCD8ZFdYqcAlRudCW+swcuctWaTDZfDNwqhF/GRFfV7UQoJeU9+0WWx4jPwtCOtSKaYYTuZgWDZ9v8FaP43jvRNmr9ZGxPHfBjOSdlvsIlIaT3kNoc1z/1e79Mgo27ANWhz9+gbxYnD3iIh0xS3mBK961x7DAHStG04g729Bwgm8eyFe3dXudBRDgFGTjv6n6/1jQMWLQqyoQWchkseFfmxMDi3gMt05/BmRQfPEsb8xekYA== 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=37D3VXzBFyND8sq8qpBZuo7YUfsH8MCjX7NdleHKAo8=; b=AfTeXg4E5CBa7r7GZWDUeCSP5HHKsQA2+lwH5nq36+nkNXKTqKlG187I1EOoJyc2Qn1i8OjEme05XnY7nGXaTTHpZ0UisdDoE+BzAiw7UOxmMSSt2B0A6P9QSW3N0q60u5DYNYYCDGzEiJcDJFFDoi5D3bO4Rxn2AlALlZCv2BM= Authentication-Results: denx.de; dkim=none (message not signed) header.d=none; denx.de; dmarc=none action=none header.from=oss.nxp.com; Received: from DB6PR0402MB2760.eurprd04.prod.outlook.com (2603:10a6:4:a1::14) by DBAPR04MB7302.eurprd04.prod.outlook.com (2603:10a6:10:1a5::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4331.25; Mon, 19 Jul 2021 07:15:09 +0000 Received: from DB6PR0402MB2760.eurprd04.prod.outlook.com ([fe80::c445:d742:eb76:86dd]) by DB6PR0402MB2760.eurprd04.prod.outlook.com ([fe80::c445:d742:eb76:86dd%9]) with mapi id 15.20.4331.032; Mon, 19 Jul 2021 07:15:09 +0000 From: "Peng Fan (OSS)" <peng.fan@oss.nxp.com> To: sbabic@denx.de, festevam@gmail.com Cc: uboot-imx@nxp.com, u-boot@lists.denx.de, Peng Fan <peng.fan@nxp.com>, Ye Li <ye.li@nxp.com> Subject: [Patch V3 37/44] imx8ulp: soc: correct reset cause Date: Mon, 19 Jul 2021 15:47:27 +0800 Message-Id: <20210719074734.29170-38-peng.fan@oss.nxp.com> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20210719074734.29170-1-peng.fan@oss.nxp.com> References: <20210719074734.29170-1-peng.fan@oss.nxp.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SGAP274CA0006.SGPP274.PROD.OUTLOOK.COM (2603:1096:4:b6::18) 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 SGAP274CA0006.SGPP274.PROD.OUTLOOK.COM (2603:1096:4:b6::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4331.21 via Frontend Transport; Mon, 19 Jul 2021 07:15:06 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 8dc197b1-c401-4b5f-497a-08d94a84f0dd X-MS-TrafficTypeDiagnostic: DBAPR04MB7302: X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: <DBAPR04MB7302264DC528E1A0B1F05B0CC9E19@DBAPR04MB7302.eurprd04.prod.outlook.com> X-MS-Oob-TLC-OOBClassifiers: OLM:107; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: WlbNy80YhY0qdqa7C6iX+vcLEK+pR8rU0H7kZI9oeiWn3bTaKUnN+dZugGYv/MDDiGCMTvLdBjwWesCl5tOxQOq9buxo8HAeXyJPAhrzmpS8usYDP1fFSTpAj/bmOr6FsC7M4vBpsQf7GOvzEKH+rYkxp+3ABggzYUS/oSLudqiVl4qZUF3kmGFaBRqhiUZMu5FZXRQtHfMtnZkq67sjrkTK4dWsJHOZR4eScXSLvQ9ZgAfzbZTpBS6lshXCg4bcR6Yp3fk4xW9nLFDRErd8M6WdxBOKlsWUFo0hYcuwfG03Xi72RSh17dVnKygSnmCtyhbLRsAOP5vfiEDTnntJwkh3UdP7JORQIR5WzY2kTUX2ecRkH00mE7yjzsduEkz0Qog4pAWGD4SyDMviNZTA7MtzgkQx3v3AWXSD3RC+41px37USdOurlhEb6J1v9p0o4aK5P1MKqpnlHfMYLqGsVjivSMEmwvXQ1bDcoz5WUZFUPz2tGHPBawuFLzdLhmXPaMUJeCzkUYfJ7r2mZYoQ2L2xlPImdsEenq4eROCSj8QdG1tvHuLA/iRBJiGjopfPTVCab5UHtOTwdq6ax7hFvgXzQC9hP3esO4OX7fyTddCN9idKOb+60MncMFeo/f+R+yShFIs/w8HFRd8RDRtpttnkAz4z6yhICQsAT8dlfxLf2GoyQyGaUEdhPvNP0HbjNDPl3zZ9fsSbrPYnbEOYuKPnLPskyw2sWPNxy9ayjpc= 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)(366004)(2906002)(1076003)(6506007)(8936002)(52116002)(186003)(26005)(86362001)(83380400001)(316002)(54906003)(66556008)(5660300002)(2616005)(6666004)(6512007)(508600001)(8676002)(6486002)(66476007)(66946007)(4326008)(956004)(38350700002)(38100700002)(32563001); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: RNqngcTNkqFeQDnVJ6I46+/LnZ7Yk7U3TityXspMPSu+4o0O5iEKr+rwafnBsHQp/kUsxuNOgUNnIuj5aVy7F94RbjRreZzKimr64eccOdYxHJf32oAVIHo6PmoBO8Txbp5balg/SOHnrNAPldwO4ZaUNVWhSifENWNKdtiBceVKgGn6sJzDEUE/MKLpJixUhxd1kpWUFdVR9EGlqq31CLpPNceAadmN6mn71NXh8QuUpmbkWd3klwG5uEB2CO/OMizfyeI8HTtYdA3gH5lf93KdNCuk/o7HI7wWe03O7NCQ4y5peHf2vcwOOvRNcENx/UWAlVri7RTVR6iWC7U3MsY5/cO2RorLG9f9mt1xdLpYvzIzBkCX9T7vRoLahin9ILAUbvaDVVa3ubQ1thYE4v/qAFc0Feq+SBBHDn6uvEaZEqibx7+jjNonRYP8nFjqUcaK+OlR2RwE+aDe6XadjQgErxT9cvMceNsdi9ScxISJT90mMzGqsZMDqXfggwqD3QVF+DX64AKyGYi6TTINSIxG0MvdskAhnbd/73Rg4JOCPr8S0tgSLHppVQ5vyQdJcZGiOPLf6n2IZPomVI5haKLkkZAg04kSOq/gnZhKsGxOIH/9DnTunslYNX+wE522DLyqoyHv7+HI5Od8RZ8opW7A/u26Geh0mYdPr27bnnoDusE6sN3Dz+aV9I3Owjjnzu2tUncmDk3350ZPz3GMNVlYNuecLLrFzOAxtTO84q6JJrHt0QdF5sTxvEYQaco/wEUM+ftskq41uHzJkaOEjs1ilWAD+QJBHAPvGnw5mu6oyznYfUNyKNkFrXhoz1WOnEYkdTMHM23D4Q7nDx3lvQelZCveciv/Nh0k3Uxmg/75NuDg3/kH3qPR8Jh78ZBA13C3mvQEXA59s4AQXeR/OTT+XFM/mBz/DRRFtA3ZXUAXZR24V+qSCU3/gKoYortjqLttMk6lQEjjEhLWS9oyyYn7HvXRsjrsZc4IQuToOD0Aj1C8RHBRflD6+BlTzRp42Ncntf4UobUXQtji5Ucad/aVF4usoARRFrXPPb770ta5wGppi0qsAgSyXV+UMjtKTolgl7ArVdwcM4xKTWNrHylWWNBvR1vFw/rskspWPfxrA6B/mSVKHNShUO8gWiZge9eMkYSDUUbSxDXe5uRbZoRPOggjYeZ9Y/cHV4DwSUPpJuFYrI/js14G5/fktH8GjymSxRkGLALqcLfmG8V4/3XlKK4gULOcA/gQ1Mdy0KAaH8zf1vM9s03LIEFC9ShJP0DM9Qtv7QxkDEp1PdEXRSi2jEJ5+2hIjTIMozytzQTOgbgU1Hj7GWsRZhX+E+yY X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8dc197b1-c401-4b5f-497a-08d94a84f0dd X-MS-Exchange-CrossTenant-AuthSource: DB6PR0402MB2760.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Jul 2021 07:15:08.8967 (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: 2uVukzKLNt1naPJQYk5m+Bu41A6aX0i4r7TV1QWZg8AHqDlw4+UwcrP5zctbgBeb6Q8D4X89Tuz4Y72a7CqtlQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DBAPR04MB7302 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion <u-boot.lists.denx.de> List-Unsubscribe: <https://lists.denx.de/options/u-boot>, <mailto:u-boot-request@lists.denx.de?subject=unsubscribe> List-Archive: <https://lists.denx.de/pipermail/u-boot/> List-Post: <mailto:u-boot@lists.denx.de> List-Help: <mailto:u-boot-request@lists.denx.de?subject=help> List-Subscribe: <https://lists.denx.de/listinfo/u-boot>, <mailto:u-boot-request@lists.denx.de?subject=subscribe> Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" <u-boot-bounces@lists.denx.de> X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean |
Series |
imx: add i.MX8ULP support
|
expand
|
diff --git a/arch/arm/mach-imx/imx8ulp/soc.c b/arch/arm/mach-imx/imx8ulp/soc.c index 513c4166c9..052169f5ff 100644 --- a/arch/arm/mach-imx/imx8ulp/soc.c +++ b/arch/arm/mach-imx/imx8ulp/soc.c @@ -148,8 +148,6 @@ enum bt_mode get_boot_mode(void) #define CMC_SRS_POR BIT(1) #define CMC_SRS_WUP BIT(0) -static u32 reset_cause = -1; - static char *get_reset_cause(char *ret) { u32 cause1, cause = 0, srs = 0; @@ -162,9 +160,7 @@ static char *get_reset_cause(char *ret) srs = readl(reg_srs); cause1 = readl(reg_ssrs); - reset_cause = cause1; - - cause = cause1 & (CMC_SRS_POR | CMC_SRS_WUP | CMC_SRS_WARM); + cause = srs & (CMC_SRS_POR | CMC_SRS_WUP | CMC_SRS_WARM); switch (cause) { case CMC_SRS_POR: @@ -174,7 +170,7 @@ static char *get_reset_cause(char *ret) sprintf(ret, "%s", "WUP"); break; case CMC_SRS_WARM: - cause = cause1 & (CMC_SRS_WDG | CMC_SRS_SW | + cause = srs & (CMC_SRS_WDG | CMC_SRS_SW | CMC_SRS_JTAG_RST); switch (cause) { case CMC_SRS_WDG: @@ -192,7 +188,7 @@ static char *get_reset_cause(char *ret) } break; default: - sprintf(ret, "%s-%X", "UNKN", cause1); + sprintf(ret, "%s-%X", "UNKN", srs); break; }