Message ID | 20240820025902.2355565-1-liyuesong@vivo.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 00ED4C3DA4A for <linux-arm-kernel@archiver.kernel.org>; Tue, 20 Aug 2024 03:00:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:MIME-Version:Content-Type: Content-Transfer-Encoding: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:In-Reply-To:References:List-Owner; bh=7IhBHtjhViEJCXGGxvgJMrhPHotzBLw8UYtdsZzBkN4=; b=kc02ABebvD20F9k5wOZXIN0k6O hn0PXmvqUKd4WjTbFBOO6Hs9nE1Ej7RSI+eT85LkrxyoputdXmzWK86tX3myXoTueGwJ1h7NQK1Pd nUJTuooIQVEP9gDWraqJLdk2DrEZFOP/fCQd34GRh5+i5irR9K+NsizKAfV68fO8re82UzOb4O6Y5 5TLoQTYZDj0DctqxT9dxHkfRYRkZyByJb4P1+PsiQY2azBhRIAcxZuq6qZETVDufn6VgC+guq2dit FmgoKwq8PBIPdcC7cHp5PIgSeMeaJiWLHrYwOhPEO+MhCACtGsJB0P1CRoDYRAfC4/ENTuak6igTa bFvp6fHw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sgF6s-00000003bky-2XZB; Tue, 20 Aug 2024 03:00:38 +0000 Received: from mail-sgaapc01on20630.outbound.protection.outlook.com ([2a01:111:f400:feab::630] helo=APC01-SG2-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sgF6C-00000003bfx-0ol9 for linux-arm-kernel@lists.infradead.org; Tue, 20 Aug 2024 02:59:57 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=ksoNfIGQ+iORrBWGgOd5GjA42apEJxhuQnTSBob2PmULngH5X6gqvvQsv8obJNAchj+z/HbSjO+Fd4U92D/AT7XI9ILuIVzbCXO7QsPruBDZN/804ouxfgECKuByUB8FfOY0jcdC5kmTaL14FOpErfGNOvwdegTrlTFN3Kp45aLyypjga4Q5Ryp0gKC6sqxhLBFewkzXk/aSi0M3RCM4jHx+y2II1dzhoqNRS8R3JliXsfkTa90F6DHvddlBf0s7mrmWlG9ouXeEuDFkCj99rFRheCIxkTvzT2GibFUaaE0AUiKT1bRBuljcdL997zX2rkKbmxVJEALTVMsrIeVBcA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=7IhBHtjhViEJCXGGxvgJMrhPHotzBLw8UYtdsZzBkN4=; b=RESGObqVcI3n+gmsXorKRHPYQ9TBQzfZXBmSLHpWnprFwXdE8roKoGPN8MlhqId0jFdh4SdnqAj2P/0w9RQ5bYlpTtz/jg2XPEr951lPWGs+Xze0jjknGix1DpJlnqZjfu98wnKxRgm+6ZdvVVMJnoqNwqVN2iNs9WQ+tnCxLioe6H/yFSgWf6awV7g8aXmUgkEBadVCpWPVonqkDsU3Axg8bJC6x1X3ILsAolOogtHjJbuylaegLZggO/FGN3qiy7R+RLmGWTmXcRemvi4aACTXkhspPz+fDCnZM+aVHy4872p1vg+XK8uOXwrn+JQ4xqtaRTuYGcR2fsWll1SviQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=vivo.com; dmarc=pass action=none header.from=vivo.com; dkim=pass header.d=vivo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vivo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=7IhBHtjhViEJCXGGxvgJMrhPHotzBLw8UYtdsZzBkN4=; b=KMhOoO/1eYjq7bsZcWZIGDhiOUBTs0NpTkGa9HVwJQRgSgc8uA8OdX9ZOWOOWi2Gt+Pr3fX4d2/7Wb16Kh06kj9a9sJxbgGJtWoEJxb6D+5RacJN6zZ5O98oUuQDmCv42syacyOb0osUaKMSCaYilnDanmvIpei99ey6zWqcJ1rlvZ0IBKaHG++qWz9YxBj5RfSE0G9jYtYqbLhFnAQ2NdQIGnL3+k4XPT6tCEyGEUE9GR+ik00KNxnCEy8lIJ6w13gFqLs66YvShnSafoNaZtCEB8Y0zra2pA0RYf4If/pRswEHhOSbaw4D+UG8eNtG1hroRlsOFC9u9Jfr4/lQMg== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=vivo.com; Received: from TYZPR06MB5709.apcprd06.prod.outlook.com (2603:1096:400:283::14) by SEYPR06MB5858.apcprd06.prod.outlook.com (2603:1096:101:c1::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7875.21; Tue, 20 Aug 2024 02:59:29 +0000 Received: from TYZPR06MB5709.apcprd06.prod.outlook.com ([fe80::bc46:cc92:c2b6:cd1a]) by TYZPR06MB5709.apcprd06.prod.outlook.com ([fe80::bc46:cc92:c2b6:cd1a%7]) with mapi id 15.20.7849.021; Tue, 20 Aug 2024 02:59:29 +0000 From: Yuesong Li <liyuesong@vivo.com> To: abelvesa@kernel.org, mturquette@baylibre.com, shawnguo@kernel.org, s.hauer@pengutronix.de, sboyd@kernel.org Cc: peng.fan@nxp.com, kernel@pengutronix.de, festevam@gmail.com, shengjiu.wang@nxp.com, linux-clk@vger.kernel.org, imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, opensource.kernel@vivo.com, Yuesong Li <liyuesong@vivo.com> Subject: [PATCH v1] clk:clk-imx8-acm:fix wrong pointer check in clk_imx_acm_attach_pm_domains() Date: Tue, 20 Aug 2024 10:59:02 +0800 Message-Id: <20240820025902.2355565-1-liyuesong@vivo.com> X-Mailer: git-send-email 2.34.1 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: TYCPR01CA0188.jpnprd01.prod.outlook.com (2603:1096:400:2b0::20) To TYZPR06MB5709.apcprd06.prod.outlook.com (2603:1096:400:283::14) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: TYZPR06MB5709:EE_|SEYPR06MB5858:EE_ X-MS-Office365-Filtering-Correlation-Id: 36a6034f-1b03-4b96-66df-08dcc0c41b81 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|366016|1800799024|376014|7416014|52116014|38350700014; X-Microsoft-Antispam-Message-Info: qomo7WYBbQJw1fSYGQFOrylWMeRMj3SQhf7oO83EM++sP23criWnwA4pGKjfPLpJESxnmRZfo3szFrkToFS2jQzDqQGkTavZobPow1NZiUPrK/D4UIjq4oEkermNTk058nY6yx2hBf6H7hS4wF0AdX3DqJBT7mTuZJk1MADB2CmFAuzJlayAT5TXnZt0dE2l5hnWh/Lvr1OTJNTtglDLME/KmrXccFljmrfWswZ1YBGFPVYTt1YS7MJ301Z0NWkE1KCUB+tCuNWOjQHiAjRHhYMJg6mrfmLbcENunV4wtyVTKttoL4P8XJx3wzHY0sOUGncJ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ZI5lB6r3rsL2Nqkiw== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:TYZPR06MB5709.apcprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(366016)(1800799024)(376014)(7416014)(52116014)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: b64ZQM9tKEPlyr/F/iD5NmugMAGq7x3EQXHNCsfr975WsOMb7/Pdj5dXmQpVQXN1HuDCmVLDVvwjXv6HHJre53ZdGx5OMkAUsMpAOzbCG4Z4u6HFtDWhYoUujzTNk+go/FJYWO7bz4bpLWjbi7xe/L0krHammQZRVN6wsKCHJ+skgQwJi8PNj3I/gznppr8S1g6wgHcMmUnAxhwuDFQZyRnbx0hqHrqvwj3vTpsLbbOkMaIeocOVYFkVOHlc4kB3KpvBQ74RtBJ1rgpyWOjJHb0T7sISW4BPO6KxTstXiQA11ujS1PDV8RKYmyx0FJfHw3PYPYXJG9coI2OG4T7cKC7EQB85tkPl5wizyD+4WWudjoPB74hOklLdqe5KWMwS6rUSlfOZEAczVgkF8WRyTWQZQgc+sRikfOF1q7ijuSmqgGGCU2SMROoZrTrIxTTkxHBWXR662NO+ruWW5Fqii/+3677JPpfT0Ez476Jm3SGmhGiiGKPG9PUMf76TkVquxZLc7y4CqgU9NpRAaMnWzV2SyHFRLwUpkEpa/KAwbNjtLcn+z/5cp04hUFDBC8BvO1r+fdsoq8I5tf78xnHg1Wtg2B92gUpOypWYlAhfuHlrqBhcb07Pg0qFuiQ8h4XfW9s8bqYv0P+ynv2AzF+axGyDfQc9E1ccV7/beu+qtsDkDK2/UwxPaqrD/T5YoICtx0bXOoqINeI7b7vqMdIWkIb44furOs00Kn45e9hgCKD9+Chd0o9oxLBxUBD9DrWmCSdyE6q1r/laGwsAAm4bUSRGZi/Bpo2DgEEvaB1VxOawPlr0FYoD9l6mE5oNAVwuNQuWOS57ONVTYB+jSXN/7P+Wssy8Q1tGi1g/sm+8z3RQYidSKtadoNzK0HiblxE7n4kyhdCnMZH9d3tOmoxHYwqnNYwVdsomNIHhaauOBGRcu3XLSPsPhLMS/7Jgs1MzItnxnfhuzSnxC7Y9tuGpysqKgkrwxvBPuJxMbHTNT/kyNDANL02ZmWsj9spzb1N9hM9WwqrMaBugLFJdsOZBGvDMhlr3tmni91FbpvG9Kf7xRvXVqDiJuTwAr1Pq4LuPdnMn0cDI/PZa5tNqWsuB5yswKGvUnuoFF0OZYJQCo6OOFs46VRn22Sozv3s94sAI6m5cK36E9czdNnTr+ytdld+SLm8KiJSG7gSN1OgwXAM7kiDPP1g6RPdF9HjbodxNz7Cy5rDlwK4CfX97vuGAgeHR4Pa40vpCxeEvQpDCj4Wnk2ODq9gzDkuUK+jcrSYYC7WW9L05qRiQi6dncSqHB+OiJuFoJC5TPIOXsB6tqvvScsUfgz3EeFnkj1Y7ex+Nn/M8oyqnYHE9uPPAWd4WhdFvKqNe0j5UTYQfSgxZiwWcmn8xe45GxSPIlQcKdbnJ/2A8XfpdsEP2ZPbxqFAgQKY1fDh2wDFBrFOePyOwEXlZnloSjR1FLCZAKBKE7NLSWwtSQy4terEiPIVASCL/hMWz1yNjxjtCcB3l076YcQbbAgpJ+/+TIxyLPYAO1xVNKPiBjdhw68qZNKGtU91VhdxEMJVj7tz5bLnvaeE6EjE+9ge/oueq4zoFfkAI+rOe X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 36a6034f-1b03-4b96-66df-08dcc0c41b81 X-MS-Exchange-CrossTenant-AuthSource: TYZPR06MB5709.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Aug 2024 02:59:28.9321 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 923e42dc-48d5-4cbe-b582-1a797a6412ed X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: qYkAQAvY0IVkXlX7ZpN/WJnwQ7eieX7fv/A2GPlKPBK7CWcBM0Jqo1zF9lfZ4cxcf92Sb1MkoJVGO59sgDAHcA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SEYPR06MB5858 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240819_195956_246246_164946E5 X-CRM114-Status: GOOD ( 10.34 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: <linux-arm-kernel.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-arm-kernel/> List-Post: <mailto:linux-arm-kernel@lists.infradead.org> List-Help: <mailto:linux-arm-kernel-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=subscribe> Sender: "linux-arm-kernel" <linux-arm-kernel-bounces@lists.infradead.org> Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org |
Series |
[v1] clk:clk-imx8-acm:fix wrong pointer check in clk_imx_acm_attach_pm_domains()
|
expand
|
Quoting Yuesong Li (2024-08-19 19:59:02) > device_link_add() returns NULL pointer not PTR_ERR() when it fails,so > replace the IS_ERR() check with NULL pointer check. Can you document that fact by adding a "Return:" line to the kernel-doc for device_link_add() in another patch?
diff --git a/drivers/clk/imx/clk-imx8-acm.c b/drivers/clk/imx/clk-imx8-acm.c index 1bdb480cc96c..ed8cad8d6a57 100644 --- a/drivers/clk/imx/clk-imx8-acm.c +++ b/drivers/clk/imx/clk-imx8-acm.c @@ -289,7 +289,7 @@ static int clk_imx_acm_attach_pm_domains(struct device *dev, DL_FLAG_STATELESS | DL_FLAG_PM_RUNTIME | DL_FLAG_RPM_ACTIVE); - if (IS_ERR(dev_pm->pd_dev_link[i])) { + if (!dev_pm->pd_dev_link[i]) { dev_pm_domain_detach(dev_pm->pd_dev[i], false); ret = PTR_ERR(dev_pm->pd_dev_link[i]); goto detach_pm;
device_link_add() returns NULL pointer not PTR_ERR() when it fails,so replace the IS_ERR() check with NULL pointer check. Fixes: d3a0946d7ac9 ("clk: imx: imx8: add audio clock mux driver") Signed-off-by: Yuesong Li <liyuesong@vivo.com> --- drivers/clk/imx/clk-imx8-acm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)