From patchwork Mon Mar 25 03:05:39 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kuninori Morimoto X-Patchwork-Id: 13601124 Return-Path: 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 BD020C54E58 for ; Mon, 25 Mar 2024 03:09:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Date:Subject:From: References:In-Reply-To:To:Message-ID:Reply-To:Cc:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=HR9EwJwMbX3T0Zn8b6vEN9YjFLvTGjkm3UoOPws/Tdc=; b=Dm8NuRUDHJoYnHjSFUnQ+G5di5 BaIBdoqEP6sQw2/px02JbrRlgOTISB1BrcVOvW6W1ntLiB2tGvk9i4BQEw2ucOJdgivFhGk1Il7sr nc1WdEX76NepI6NfBr1Xq1aVokEcgM4c/QFcvVhY25z6f5ffyuHod/fnGVBaHOEGAnW9lPbdCVP19 fGoCd/y0DXCpX6K54H/F7PNwvHlB+L5BuuldAgbFi3w5SwDpcSBy0EremQe2slRxv21I1Aka9hyXr 44+0+tRtHD/4848mdWYKozwJwGoLKBGJAUZckg1sFypVcoNAXk6QykMvWiYc1u5Vhm509Y+c/bd/y S4D6+Lyw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1roah4-0000000Epd7-2CBM; Mon, 25 Mar 2024 03:08:14 +0000 Received: from desiato.infradead.org ([2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1roafc-0000000Ep6N-1SHh for linux-arm-kernel@bombadil.infradead.org; Mon, 25 Mar 2024 03:06:53 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=MIME-Version:Date:Content-Type:Subject :From:References:In-Reply-To:To:Message-ID:Sender:Reply-To:Cc: Content-Transfer-Encoding:Content-ID:Content-Description; bh=WhWU5pMTa0RW9lB2L2jViSSAy9x86pATn/ADdUCQ1qs=; b=LFW/GHn88wtcc8/b5ztVZkiTXO 8B8QcBK1kwSs5U/GxUQ+ONOeoB52m6dab+THOHD6XtX/syo02tiMaUWgLWF831cUAHzn55LSUr7XE 1AMB9XPNdF1d4uwJsuT/Ig4iL5vjoQJrMa5IhdQOzXALIWXvOHmWLJbkEznnxh05Q5piqHDRRoHAh k0o/c96r39UNrD5l2Cc1z05O6w/HgwbVHuFqS0VEABodqVyEDzNTCfXUCaDH2OkzhjwBYvXua66jo L1mm7MWfocGIYX97urfDlz2bvpPEYUqDrpG76yfs5b00rfbBqjXQzd49y2Z7UaMNELvKmUeF+r+T2 91bViOYw==; Received: from mail-os0jpn01on20600.outbound.protection.outlook.com ([2a01:111:f403:201a::600] helo=JPN01-OS0-obe.outbound.protection.outlook.com) by desiato.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1roafT-0000000GMv3-1R2H for linux-arm-kernel@lists.infradead.org; Mon, 25 Mar 2024 03:06:42 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=G1qCsA2Km52QHuOQHnqbdHoh5nGwsW7eNfz6HnfbiL9elYqoWc/tb77NyEx4ECmA4oKCHJSOhlFVEZp05CsdDXD63mMVg9/QiVXRO/2cU0MOQz6WvRbwqIxUe7mognSLGqd/QXeZScfOdvc2ilBCvKiLl/HNYlAjrLU9FxL0Eb/bWKX9KfSkSfA1tW3DOotwoJkHy1I2YEdIWYdmxV+c90n0LXeTY+nJW8cdsWD/pQ4wQZKF39eg+O96ycccU1lwHCexB0QaOA1CTGf4hMz1S2PgunF48lFvncXNJ3vtYQSrh1IAMRlXlu8XOAIhU1eUGv8YgHL4XqafW8qzBvEclA== 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=WhWU5pMTa0RW9lB2L2jViSSAy9x86pATn/ADdUCQ1qs=; b=M1/VjDaFaP6EY9DpcXW2h1LL/38QL6M6PYLcEqAHBQgWTt42eji4hjdxYAanHzH2CzyiGLE2yx+3C3WPFpK78NwcqNZ+dSGY1VIA3PfzfOIPox9v4QAZ4NmByMrsxTbmtjOj+nzhDQPUZ8hUHxyTyH2wT1uOo9ocV2fkvbVLg6t1kXY6wdSPiRvRbxOSGYggPQoA94ecfkOvfoqsEKCKtciKrorz+HpZB6RNtRQ+wwT12wgFXAvMfy1T1SUAsqUUFe47TmrDx2zSg6RSo5lDGNxYZ/JICw4rsBVK047MfmmRtpYF2pACd/ZbIUk6dIagYoJyRZ9WSG4ra1prpgbccw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=renesas.com; dmarc=pass action=none header.from=renesas.com; dkim=pass header.d=renesas.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=renesas.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=WhWU5pMTa0RW9lB2L2jViSSAy9x86pATn/ADdUCQ1qs=; b=dgburxymTiuWgPc6tOGUbxYRBIscMmIvWHpHMTDuW/j7q+d/myhWtPyAmOKCR8ZecklAvDUzZcCSaJ5tUOTd3e16V0HvJ5qPaWw8ilqmxVEuq1jfM6zZt0mhSTpIBT3Nmv0dzSTgI1LO2k5YWshNEDSD/2kjT+fNnU4CcznMbhA= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=renesas.com; Received: from TYCPR01MB10914.jpnprd01.prod.outlook.com (2603:1096:400:3a9::11) by OS3PR01MB6966.jpnprd01.prod.outlook.com (2603:1096:604:12d::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.31; Mon, 25 Mar 2024 03:05:39 +0000 Received: from TYCPR01MB10914.jpnprd01.prod.outlook.com ([fe80::131e:55c0:a4a0:713b]) by TYCPR01MB10914.jpnprd01.prod.outlook.com ([fe80::131e:55c0:a4a0:713b%7]) with mapi id 15.20.7386.025; Mon, 25 Mar 2024 03:05:39 +0000 Message-ID: <87ttkv57uk.wl-kuninori.morimoto.gx@renesas.com> To: "Lad, Prabhakar" , Alexander Shishkin , Alexandre Belloni , Claudiu Beznea , Daniel Vetter , David Airlie , Eugen Hristev , Greg Kroah-Hartman , Helge Deller , Laurent Pinchart , Maarten Lankhorst , Mauro Carvalho Chehab , Maxime Ripard , Michal Simek , Nicolas Ferre , Rob Herring , Suzuki K Poulose , Thomas Zimmermann , Tomi Valkeinen , coresight@lists.linaro.org, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-fbdev@vger.kernel.org, linux-media@vger.kernel.org, linux-omap@vger.kernel.org, linux-staging@lists.linux.dev In-Reply-To: <8734sf6mgn.wl-kuninori.morimoto.gx@renesas.com> References: <8734sf6mgn.wl-kuninori.morimoto.gx@renesas.com> From: Kuninori Morimoto Subject: [PATCH 6/8] staging: media: atmel: use for_each_endpoint_of_node() Date: Mon, 25 Mar 2024 03:05:39 +0000 X-ClientProxiedBy: TYCPR01CA0116.jpnprd01.prod.outlook.com (2603:1096:405:4::32) To TYCPR01MB10914.jpnprd01.prod.outlook.com (2603:1096:400:3a9::11) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: TYCPR01MB10914:EE_|OS3PR01MB6966:EE_ X-MS-Office365-Filtering-Correlation-Id: 457e2ebb-7602-4866-9569-08dc4c78737d X-LD-Processed: 53d82571-da19-47e4-9cb4-625a166a4a2a,ExtAddr X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: aYNz118gGtVvozVPytM99Y7gp2GK2F/PuKOSEGl0g9Usx9eBBjbgFboxdbocuU+qk3TBsIOz1zWZKdvhQRjnV/jzRZrmUfZ8+CdmwixHmg7D4w87dvbqNaeBbO5+Q/lk7QdtgTb/bsmTmX+onHwO43+DtcxsYGz0jy+8KmeT6wzJIPonDMdZm0i1KrOzEWDMR4F2sAaqzNkEtVkJm9qByTdjTBQgyIKLIVnyaVTcXix51/5n20g2fo1L0f6Q+KSlyV4GWKKk40ZKAwkmQaZoEfAVwSa3WXtqiV+1e8mNBWolWEFZb6/08j2U59nr3axo06CO6sqc2cvLIS9IPamTFnXCPTFgeFQFMuiuVkQfVStV2b7c5ClYDMwORdcYGuBQbL2Tq9Iw9HmB9BMqEYlXF8xN1aB//k4ctYbjQjOsESoEbqOxdRJ0BWdTNiuhkfrpvvPQQSe/2CTmtN1MCF5EPuGVxY71HLimdjlfbSFUoHZab7wJqsppaZgOCjC2NM96C7HvM0np8f1stG8RDBu2jnLc+FGenHDk044H6dPYj47m2S92EGHbfEbKJ3VwG+8LEDThcloLBolWCxkNOq5oS+JZs/eurS3Ry9EszPUL8XhdQWUrdX//FskSH/Xn8Z0spXHdm8rgrQbukvD1rnWx3RZSNmhja2HkO0Z/M75JKxCYuY5PwOcmF0iO/TMc8KuS+fpRuvtyX54VZxVrYRwaT4ZLfEe24PmW3PK3wrEhx5w= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:TYCPR01MB10914.jpnprd01.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(1800799015)(52116005)(7416005)(366007)(376005)(38350700005)(921011);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: jRPJ8qlyeWgtbwcHCpgvmrtn9rULkWCj7Go6cuNRZKNXYpL/R1BAyWSxaNnDOcwwOHY8cfNOP8fdqYfeQb/lCtdxzUVKcXjIwWpIle80DdMjfGSwug5thgp6aThxMHgSIN+ZhiwBRWB+/UlDkKmo/Kn158tGV+1J4svZDxTmFsj7MzyVOzRHG+2ezyXdPp793qO8daFNQVhD9fRpqY0AmqlPHvgr0F9L2W1bj9h4DET37jNytrg8x4cbirNdo3cyOf3IFd/eZPPOBOcxWO6KIPhgTNKkddP92uBgekkEeoeBuVYzdfMv4IjfcosUTuZyMKdylQ72HO11IDjKPWhGYrIQt3aKuIXAxBXBb/2Ut56VdteONYuazdgDidSDG+6/aiyZ0WZMDCUb+aiarRMWuc7j/e5jSEB+6T03jz87bikTKiwS2I7/An4a6VHBPUlV+4sn58h2Xi5N3yj5Iwo4m5Rh73WAFpmsCAMBehg+tQaskJ2tjGa2c1s/VSNPiSVHKaYiFjdGvaxf7XJuQCVO2uiZDCxQQEnh40PPSfcKvIzRHmtGqifzfs7bmUI2wgxrK0SC5knoLx6XovxBZ934LkYZ2V4Dw2JB0OPqxl6i9UOkvjqODoQpkgAzVJtkHXngbPIWAHhNf92Oxh8OoBaZ8o9X5nUKt+1C+Uuy9LUsPo6a49WpO8V+36TjxDP+xogdNHxA0MXKg+zfMprp83FUST3TkZqw7I21NztdU4Cjw+OtAJKgODGN8MbIHtm1/DkW0vB43jmBwCJjBjqn7oY3Tp1tnhogA/ovwTpu7F6QeKgQ5c7esp2U3BOVtN7CPeaU+QVz8rxU+hZNjqRESQ543PL3/zdN6rTdvWb0pxlPia3xzEpJ5eDIL677ImYwwWAovLAqn5x2LccV99kEuVYXBw8QWjrK5Ay1MRV+AXYUIl6B22bWvZB9toJa+YRs4uXjNedy1m2RLrjute5fJ/84KFoRs/QxFh3SOS09leuzuvP3R0ohSr6ul4GbpB5nkGscKQaRf3Ql/Eq1B+X1U5Jt94lIq43ynggI7RAELWUCFAx1XDVK50CpME1km/dcpuptRdhnXDgv4SIYu0NU0B/4jc29ia9lkVEDOIIfCgK7PoLA1S+p53Sg1RvCF/lOH8KK1mK3u4qEALWHSWCiL4ZI5k9vigMcZQ+6AYtfrC3Pw6tKVP8fBHmOm0VAN4pCvthY0Fm5rGoE6VA0qbvKLAGcP3eZO0VAgzl15h4nfp3+Lz8S4eMy3cEnEOq1QJ87IiL1zsTdhtpaVqXby33X73RhZ5Zu3W2YZc3+XFDf7OxE8VrWO2Ogewb5sJ3c8IRV/irD/PYYS9SVjHkjQH/Z2ooBEtSzmWJwZ0+4ccmvb1XylCMsZGbYtFKIwTgnM5C4OvqNlGU6hst9NVVTCfOIM9cdzREp8ZEdMsKhck8n4e+/C3W2bcQWNM8txq6ccbpwGaFC4IeHQPH+Qlu1REGS5iiJ9F6uvQ8yUOL26LL7ahrtCny7K3bxl4Fh6gQROuHBbrFEn3984S9SQULVtDP+YnGUsNSrXo6FOvgMXWHI3epFc4demb5zdWijoSO+NJ2H+n6CEFmJjXRTF26lRqxFlCOmzCxhU8WMuvZt2BL2RjMUs3M= X-OriginatorOrg: renesas.com X-MS-Exchange-CrossTenant-Network-Message-Id: 457e2ebb-7602-4866-9569-08dc4c78737d X-MS-Exchange-CrossTenant-AuthSource: TYCPR01MB10914.jpnprd01.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Mar 2024 03:05:39.7941 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 53d82571-da19-47e4-9cb4-625a166a4a2a X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: JL3FM5A5KLaDLJdsSp2L+pPB4vxbePao+76mly4RFOYWib0gkHvHUxAUi2xxB7rrhrUfQggvkxKgS7ZCWOByh+OFI2Ij19VQSH+AwSv9f7oAmWo73gQLl5q4OlC+cNu5 X-MS-Exchange-Transport-CrossTenantHeadersStamped: OS3PR01MB6966 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240325_030635_994246_F2157116 X-CRM114-Status: GOOD ( 10.45 ) 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 We already have for_each_endpoint_of_node(), don't use of_graph_get_next_endpoint() directly. Replace it. Signed-off-by: Kuninori Morimoto --- drivers/staging/media/deprecated/atmel/atmel-sama5d2-isc.c | 6 +----- drivers/staging/media/deprecated/atmel/atmel-sama7g5-isc.c | 6 +----- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/drivers/staging/media/deprecated/atmel/atmel-sama5d2-isc.c b/drivers/staging/media/deprecated/atmel/atmel-sama5d2-isc.c index 31b2b48085c5..cbfbec0c6cb5 100644 --- a/drivers/staging/media/deprecated/atmel/atmel-sama5d2-isc.c +++ b/drivers/staging/media/deprecated/atmel/atmel-sama5d2-isc.c @@ -340,13 +340,9 @@ static int isc_parse_dt(struct device *dev, struct isc_device *isc) INIT_LIST_HEAD(&isc->subdev_entities); - while (1) { + for_each_endpoint_of_node(np, epn) { struct v4l2_fwnode_endpoint v4l2_epn = { .bus_type = 0 }; - epn = of_graph_get_next_endpoint(np, epn); - if (!epn) - return 0; - ret = v4l2_fwnode_endpoint_parse(of_fwnode_handle(epn), &v4l2_epn); if (ret) { diff --git a/drivers/staging/media/deprecated/atmel/atmel-sama7g5-isc.c b/drivers/staging/media/deprecated/atmel/atmel-sama7g5-isc.c index 020034f631f5..7c477b1d3c48 100644 --- a/drivers/staging/media/deprecated/atmel/atmel-sama7g5-isc.c +++ b/drivers/staging/media/deprecated/atmel/atmel-sama7g5-isc.c @@ -326,13 +326,9 @@ static int xisc_parse_dt(struct device *dev, struct isc_device *isc) mipi_mode = of_property_read_bool(np, "microchip,mipi-mode"); - while (1) { + for_each_endpoint_of_node(np, epn) { struct v4l2_fwnode_endpoint v4l2_epn = { .bus_type = 0 }; - epn = of_graph_get_next_endpoint(np, epn); - if (!epn) - return 0; - ret = v4l2_fwnode_endpoint_parse(of_fwnode_handle(epn), &v4l2_epn); if (ret) {