Received: by 2002:ab2:60d1:0:b0:1f7:5705:b850 with SMTP id i17csp444408lqm; Wed, 1 May 2024 05:49:39 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX/WubxdfX2poyzGD09NUWmb0Y7B6M6h5AuME1gdV6kImzgWSEg9sAIj8WSSAkIxT3eGmNACMTIdXp0CvZ+8frrantzkEKhPW8qnuaSnQ== X-Google-Smtp-Source: AGHT+IEqwIHrXK0bzJyNkLG0KNZWmc+xGji+tD+Oh/xORNlmOJ39CK+s3IZ97XXnuMbILoDmDziG X-Received: by 2002:a17:902:da8d:b0:1e5:a3b2:3dad with SMTP id j13-20020a170902da8d00b001e5a3b23dadmr2545995plx.42.1714567779166; Wed, 01 May 2024 05:49:39 -0700 (PDT) Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id m2-20020a170902db0200b001e589f808a5si24677286plx.295.2024.05.01.05.49.38 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 May 2024 05:49:39 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-165272-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@NXP1.onmicrosoft.com header.s=selector2-NXP1-onmicrosoft-com header.b=Kqlxeuda; arc=fail (signature failed); spf=pass (google.com: domain of linux-kernel+bounces-165272-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-165272-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id C51FC283B4A for ; Wed, 1 May 2024 12:49:38 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 71FDD8565E; Wed, 1 May 2024 12:49:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=NXP1.onmicrosoft.com header.i=@NXP1.onmicrosoft.com header.b="Kqlxeuda" Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04on2051.outbound.protection.outlook.com [40.107.6.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6D1701EA84; Wed, 1 May 2024 12:49:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.6.51 ARC-Seal:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714567772; cv=fail; b=QvwOACNGsLbHZRgyWdzQXGvyYd+oh2MyE8NKD2uKH+E2U8UEkqrWgQrIh0n6noi2DlazwMj6hc3EQaIGRPR007Pxk+MjpKEhF/kKaIWvzp0b5wc9FwzKxevrVvPaSI8Nj7rlFLr0HlVdC8xn2oUi43K05ylXe1j6yzgVReKdnZI= ARC-Message-Signature:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714567772; c=relaxed/simple; bh=T8RPCLVB0venRQNxNQUNK7eXrSySPXtqqefcl0oLISg=; h=From:Date:Subject:Content-Type:Message-Id:References:In-Reply-To: To:Cc:MIME-Version; b=cqcDtdl/WeL4vN1FuUg4ZzJsYDzg/GMYjLZRJEGy7B99VpL3UjHROLLvEuvw7mzZXEDYhFFgcDaC6HeSHmnATVYCwszNrfbfYzJV4P9P2wxIJgSYZWj1cq0jya2ihmy4T2lmtbXWGDVoCa6PmGE9J0goOvBJcsAGoZ93XFmpdmQ= ARC-Authentication-Results:i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=oss.nxp.com; spf=pass smtp.mailfrom=oss.nxp.com; dkim=pass (1024-bit key) header.d=NXP1.onmicrosoft.com header.i=@NXP1.onmicrosoft.com header.b=Kqlxeuda; arc=fail smtp.client-ip=40.107.6.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=oss.nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.nxp.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=cd2pkTEpxdjR4zHMJabEAK8ziMtPIJdXtnU2NZKH+0KI12XRklQK+DhQtJrRal59uhMEX9bifoohmvgy5x2EEFMBDYLWc0hreM2/HuKM6hipY4VHs1E5IuP69ZmbdMBk79aTnk43OT4jIiE8RnvutU6tvF8E7xIgMIFu3ISbNh3d2BLLA4gcmr4vSHF9NMRwF+ZP7Pi5hQU1iInfiojmpfDvkRnk8OglpS1yTeP6md24K9RxJ5U8S/Ljzs4qfLmDLU6qXyv+NyB3VmsJclpp+B5DFx4ngrVqzzvLvcsxlnfWODpBLAdlqTHHHUhLf02Y8ZevKWc9/xOmTOHFnk6zvw== 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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=WgaCub/AVvrWstgRn7NDSa3uLOl1yukaIFVzxzPeW7I=; b=EhjlbkSwIpK9p5mi+T8IG4fJMmy3vM2r3qtAH+zO2GV6i1EIR0hj6DvE75r8/pNWdBh8M2gBbUvgvYvRxHqQFwETfJFXyr8NstOe3KlDaIwXGu7BQkNLDITjPC6PqUqqlIEhti7JjZLntybbY+B/96ft3UN3DhmT89ZbintLaW52oZuSNsmWfcOIwwIIL1vby/qgsy2AfbWbiEW1HCac3xC8BMKYhRFoNCqZn5E4ubYaJ0R8B0cFwqshVjIEXN2s4zLpOTI2X7rat+QyxUxL5s3o7fW/XS7Sa/6Q3zVjBeDIQ0pMir+I2ACkYrpmKHI1Gx7IYNX8RXkWZq0XezQ9Ng== 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=WgaCub/AVvrWstgRn7NDSa3uLOl1yukaIFVzxzPeW7I=; b=KqlxeudasMTvhe+KYjUqTRiD3zhIewnGUP/1/6FPzIUOiA7oIwOjMAYneE8FW/eXrC47IYOR5Id2saq1vXi4EVllT7bKTH9SciPp/WSRBpQEhmxx98G8kKyQ8xHo6utAnI+1zI/YiPCeNB4NpGnYXJgg1/3kf6F9AqjO0XWHZAo= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=oss.nxp.com; Received: from DU0PR04MB9417.eurprd04.prod.outlook.com (2603:10a6:10:358::11) by DB9PR04MB9284.eurprd04.prod.outlook.com (2603:10a6:10:36c::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7519.36; Wed, 1 May 2024 12:49:27 +0000 Received: from DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::d30b:44e7:e78e:662d]) by DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::d30b:44e7:e78e:662d%4]) with mapi id 15.20.7519.031; Wed, 1 May 2024 12:49:27 +0000 From: "Peng Fan (OSS)" Date: Wed, 01 May 2024 20:56:02 +0800 Subject: [PATCH 04/21] pinctrl: stm32: Use scope based of_node_put() cleanups Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20240501-pinctrl-cleanup-v1-4-797ceca46e5c@nxp.com> References: <20240501-pinctrl-cleanup-v1-0-797ceca46e5c@nxp.com> In-Reply-To: <20240501-pinctrl-cleanup-v1-0-797ceca46e5c@nxp.com> To: Linus Walleij , Thierry Reding , Jonathan Hunter , Dvorkin Dmitry , Wells Lu , Maxime Coquelin , Alexandre Torgue , Emil Renner Berthing , Jianlong Huang , Hal Feng , Orson Zhai , Baolin Wang , Chunyan Zhang , Viresh Kumar , Shiraz Hashim , soc@kernel.org, Krzysztof Kozlowski , Sylwester Nawrocki , Alim Akhtar , Geert Uytterhoeven , Patrice Chotard , Heiko Stuebner , Damien Le Moal , Ludovic Desroches , Nicolas Ferre , Alexandre Belloni , Claudiu Beznea , Dong Aisheng , Fabio Estevam , Shawn Guo , Jacky Bai , Pengutronix Kernel Team , Chester Lin , Matthias Brugger , Ghennadi Procopciuc , Sean Wang , Matthias Brugger , AngeloGioacchino Del Regno , Sascha Hauer , Andrew Jeffery , Joel Stanley , Dan Carpenter Cc: linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-tegra@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-stm32@st-md-mailman.stormreply.com, linux-samsung-soc@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-rockchip@lists.infradead.org, linux-riscv@lists.infradead.org, linux-mediatek@lists.infradead.org, imx@lists.linux.dev, linux-aspeed@lists.ozlabs.org, openbmc@lists.ozlabs.org, Peng Fan X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1714568179; l=1839; i=peng.fan@nxp.com; s=20230812; h=from:subject:message-id; bh=3dCftRoTOrOimvH/zZhm1znYYmC195eNUPhLJhk2Pd4=; b=fEVszNhFmB0ozWSgviQak9c62GVC/GEZgZAP4r8VCKSloHSeg9ffm1vWAQQ+bwWtefd5irQb/ 3aoJSkKQVp/AVh9+Sc4htbGVlXth84TcdldSRvPA3MnRCqG5c4wNNYL X-Developer-Key: i=peng.fan@nxp.com; a=ed25519; pk=I4sJg7atIT1g63H7bb5lDRGR2gJW14RKDD0wFL8TT1g= X-ClientProxiedBy: SG2PR02CA0064.apcprd02.prod.outlook.com (2603:1096:4:54::28) To DU0PR04MB9417.eurprd04.prod.outlook.com (2603:10a6:10:358::11) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DU0PR04MB9417:EE_|DB9PR04MB9284:EE_ X-MS-Office365-Filtering-Correlation-Id: c222aae5-b13c-4c9e-3bfc-08dc69dd22b9 X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230031|1800799015|376005|52116005|7416005|366007|38350700005|921011; X-Microsoft-Antispam-Message-Info: =?utf-8?B?OEVWanQ2OExpeWw0TVFIcFphc0UzV0h3aUxCUHo5ZEM2S3ZkRUdhOXhUQk0y?= =?utf-8?B?Y0N2bEdsNXlydlZrUmRyM2FiamJPVUN2YnpUVWw5VS8zR2NRamg5Q1lmVmg2?= =?utf-8?B?dytOWUFmd29jRyttemVJMzFPNDExVVFwcmxUUHJySHN4RFNGV0VxN0s0eG8x?= =?utf-8?B?Tm1xVCt6VlNmQUtESnhBeGRvbkNCcnBkNVBQeE1Qc0t6R0JOK1BxTzJFZndz?= =?utf-8?B?QUs0RlNLTVZZZkdIeGVjWHNtK1kxN3pFN0FiTmVtVzkzcUpqNGVTbGF1SVp0?= =?utf-8?B?MVIvTU4rN0ttQXo0Ty85N0h3T0EwOXJuaVFBaGFzZ1YzeWxhckdZaWp0TSsr?= =?utf-8?B?akhzQTZ0dlBiWnN0WlBzVm9IQnEyVkxQTEhFNW10UmZxcjdZWWtSV2VGLzZw?= =?utf-8?B?bFNHSWRUT083V3N1V2FXVXlydWpRU29Eaz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vYklINGZGNHJvUmZkVkF5RzZIazRTRzV6TW51NU0v?= =?utf-8?B?UXJVb2xpNElJaVNBRHZ6VElrczJIQVFNeWNmYXRiZExhajVFUDZnSWc1MUtw?= =?utf-8?B?YXU4VmQ5UnMyQVh4U0lWREZKRnFQS3kxZmNEdGRCTXpoTW1kYm1mM2FjaEpj?= =?utf-8?B?NS95MmhVdFBpcFl0TG90SW5LMlpZN3BwS3pRSHVqRVB2SlZibnRBR1dweG0x?= =?utf-8?B?SUltTDRzYTljR05jVFB0dFdTYVV6eU05VjN4c1Q5N3pYaDkrdVc5eUUwRHBz?= =?utf-8?B?NDkxVlE1TkpzU3ViUjJmZTloU1pkczg0YzV0akdrUGptYmhFWVF6U1hoci8x?= =?utf-8?B?UHA5ME5mSVhOcktPK01VQ2VpL005Sm9xSXNKMlh3L2k4ZnpsODJ3cWd6REpF?= =?utf-8?B?TERvTXl5b2FXM3B0NEVUWG9vZEpwbU10bE4wUnM4ZjNpUzNWbG9DZDNWdmhB?= =?utf-8?Q?ySOIaCBmcJo2Qfwuys0yy1oKe9MuEFAOI8snE=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DU0PR04MB9417.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(1800799015)(376005)(52116005)(7416005)(366007)(38350700005)(921011);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?NmFBKzhJVlVFUW1kdkNQVHlGS0Q5cG9saHp4NmFsN1JOMnlmLzdXaU9kR3Bv?= =?utf-8?B?RUlpUkdhazlDUHFJcmZqMER0UWJpWGJpSEdyZ1hDaEJ6YTlsRjN0YzQxSXNI?= =?utf-8?B?b3NpbzR1b3k1aW5BQkFqNE4wRjNnZmJTUnowWFI0K2ovODRodTZTcXQ3WFpX?= =?utf-8?B?eHpHRG03UEhSSj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f-8?B?Ry9Tb2xDMnA4bzdQdzBVQVJVbFZOZXlxb21aN3YrOXhvK1lWdjB2Y2ZWNTBO?= =?utf-8?B?NHIwM0hWbi8zZk1JRHJjR3pIQjNMdjVtcEVBWE5HdWJUblFJWG53QnRoYnFV?= =?utf-8?Q?nNSW26EE2r3dBOQn0swugUaaQ?= X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: c222aae5-b13c-4c9e-3bfc-08dc69dd22b9 X-MS-Exchange-CrossTenant-AuthSource: DU0PR04MB9417.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 May 2024 12:49:27.2054 (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: gYhhvpfni11AYjiQmPbJI7VN9cJiU/58D8H2Bm9JL6Fv8mo+F82kEz2zeToWO4luMT6owRB/C7fRHw0IinuiLw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB9PR04MB9284 From: Peng Fan Use scope based of_node_put() cleanup to simplify code. Signed-off-by: Peng Fan --- drivers/pinctrl/stm32/pinctrl-stm32.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/pinctrl/stm32/pinctrl-stm32.c b/drivers/pinctrl/stm32/pinctrl-stm32.c index 978ccdbaf3d3..ca163a91e724 100644 --- a/drivers/pinctrl/stm32/pinctrl-stm32.c +++ b/drivers/pinctrl/stm32/pinctrl-stm32.c @@ -670,7 +670,6 @@ static int stm32_pctrl_dt_node_to_map(struct pinctrl_dev *pctldev, struct device_node *np_config, struct pinctrl_map **map, unsigned *num_maps) { - struct device_node *np; unsigned reserved_maps; int ret; @@ -678,12 +677,11 @@ static int stm32_pctrl_dt_node_to_map(struct pinctrl_dev *pctldev, *num_maps = 0; reserved_maps = 0; - for_each_child_of_node(np_config, np) { + for_each_child_of_node_scoped(np_config, np) { ret = stm32_pctrl_dt_subnode_to_map(pctldev, np, map, &reserved_maps, num_maps); if (ret < 0) { pinctrl_utils_free_map(pctldev, *map, *num_maps); - of_node_put(np); return ret; } } @@ -1401,7 +1399,7 @@ static int stm32_gpiolib_register_bank(struct stm32_pinctrl *pctl, struct fwnode static struct irq_domain *stm32_pctrl_get_irq_domain(struct platform_device *pdev) { struct device_node *np = pdev->dev.of_node; - struct device_node *parent; + struct device_node *parent __free(device_node) = NULL; struct irq_domain *domain; if (!of_property_present(np, "interrupt-parent")) @@ -1412,7 +1410,6 @@ static struct irq_domain *stm32_pctrl_get_irq_domain(struct platform_device *pde return ERR_PTR(-ENXIO); domain = irq_find_host(parent); - of_node_put(parent); if (!domain) /* domain not registered yet */ return ERR_PTR(-EPROBE_DEFER); -- 2.37.1