From 75c908beb6a1c96c030893d313ee5b82c075aad6 Mon Sep 17 00:00:00 2001 From: Jon Hunter Date: Thu, 14 Dec 2023 12:09:12 +0000 Subject: [PATCH] media: camera: Remove devm_fwnode_get_gpiod_from_child The function devm_fwnode_get_gpiod_from_child() was removed in Linux v6.2. This function has always called devm_fwnode_gpiod_get_index() and this was first introduced in Linux v5.5. Therefore, remove devm_fwnode_get_gpiod_from_child() and always use devm_fwnode_gpiod_get_index(). Bug 4346767 Change-Id: Ie94a20ffda67569962fa48d7104c8ff706be079d Signed-off-by: Jon Hunter Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3034777 Tested-by: mobile promotions Reviewed-by: mobile promotions --- drivers/media/platform/tegra/cdi/cdi_mgr.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/drivers/media/platform/tegra/cdi/cdi_mgr.c b/drivers/media/platform/tegra/cdi/cdi_mgr.c index a5bf34fc..b128aa3a 100644 --- a/drivers/media/platform/tegra/cdi/cdi_mgr.c +++ b/drivers/media/platform/tegra/cdi/cdi_mgr.c @@ -31,7 +31,6 @@ #include #include #include -#include #include @@ -1662,13 +1661,8 @@ static int cdi_mgr_configure_gpios(struct device *dev, struct cdi_mgr_priv *cdi_ } } -#if LINUX_VERSION_CODE < KERNEL_VERSION(6, 2, 0) - cdi_mgr->gpios[i].desc = devm_fwnode_get_gpiod_from_child(dev, - "devblk", &child->fwnode, GPIOD_ASIS, NULL); -#else cdi_mgr->gpios[i].desc = devm_fwnode_gpiod_get_index(dev, &child->fwnode, "devblk", 0, GPIOD_ASIS, NULL); -#endif if (IS_ERR(cdi_mgr->gpios[i].desc)) { ret = PTR_ERR(cdi_mgr->gpios[i].desc); if (ret < 0)