{"id":2231126,"url":"http://patchwork.ozlabs.org/api/patches/2231126/?format=json","web_url":"http://patchwork.ozlabs.org/project/linux-tegra/patch/20260430110652.558622-15-vladimir.oltean@nxp.com/","project":{"id":21,"url":"http://patchwork.ozlabs.org/api/projects/21/?format=json","name":"Linux Tegra Development","link_name":"linux-tegra","list_id":"linux-tegra.vger.kernel.org","list_email":"linux-tegra@vger.kernel.org","web_url":null,"scm_url":null,"webscm_url":null,"list_archive_url":"","list_archive_url_format":"","commit_url_format":""},"msgid":"<20260430110652.558622-15-vladimir.oltean@nxp.com>","list_archive_url":null,"date":"2026-04-30T11:06:39","name":"[v7,phy-next,14/27] usb: gadget: tegra-xudc: avoid direct dereference of phy->dev.of_node","commit_ref":null,"pull_url":null,"state":"new","archived":false,"hash":"c4d852229c4453d3224977c5bf7074062af3a836","submitter":{"id":75582,"url":"http://patchwork.ozlabs.org/api/people/75582/?format=json","name":"Vladimir Oltean","email":"vladimir.oltean@nxp.com"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/linux-tegra/patch/20260430110652.558622-15-vladimir.oltean@nxp.com/mbox/","series":[{"id":502276,"url":"http://patchwork.ozlabs.org/api/series/502276/?format=json","web_url":"http://patchwork.ozlabs.org/project/linux-tegra/list/?series=502276","date":"2026-04-30T11:06:26","name":"Split Generic PHY consumer and provider","version":7,"mbox":"http://patchwork.ozlabs.org/series/502276/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/patches/2231126/comments/","check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/2231126/checks/","tags":{},"related":[],"headers":{"Return-Path":"\n <linux-tegra+bounces-14100-incoming=patchwork.ozlabs.org@vger.kernel.org>","X-Original-To":["incoming@patchwork.ozlabs.org","linux-tegra@vger.kernel.org"],"Delivered-To":"patchwork-incoming@legolas.ozlabs.org","Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=nxp.com header.i=@nxp.com header.a=rsa-sha256\n header.s=selector1 header.b=UMBFweKF;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org\n (client-ip=2600:3c04:e001:36c::12fc:5321; helo=tor.lore.kernel.org;\n envelope-from=linux-tegra+bounces-14100-incoming=patchwork.ozlabs.org@vger.kernel.org;\n receiver=patchwork.ozlabs.org)","smtp.subspace.kernel.org;\n\tdkim=pass (2048-bit key) header.d=nxp.com header.i=@nxp.com\n header.b=\"UMBFweKF\"","smtp.subspace.kernel.org;\n arc=fail smtp.client-ip=52.101.65.37","smtp.subspace.kernel.org;\n dmarc=pass (p=none dis=none) header.from=nxp.com","smtp.subspace.kernel.org;\n spf=pass smtp.mailfrom=nxp.com","dkim=none (message not signed)\n header.d=none;dmarc=none action=none header.from=nxp.com;"],"Received":["from tor.lore.kernel.org (tor.lore.kernel.org\n [IPv6:2600:3c04:e001:36c::12fc:5321])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4g5ryZ0Kpsz1yGq\n\tfor <incoming@patchwork.ozlabs.org>; Thu, 30 Apr 2026 21:08:54 +1000 (AEST)","from smtp.subspace.kernel.org (conduit.subspace.kernel.org\n [100.90.174.1])\n\tby tor.lore.kernel.org (Postfix) with ESMTP id AE0EC304A875\n\tfor <incoming@patchwork.ozlabs.org>; Thu, 30 Apr 2026 11:07:33 +0000 (UTC)","from localhost.localdomain (localhost.localdomain [127.0.0.1])\n\tby smtp.subspace.kernel.org (Postfix) with ESMTP id 7F5DB3F9F4C;\n\tThu, 30 Apr 2026 11:07:33 +0000 (UTC)","from DU2PR03CU002.outbound.protection.outlook.com\n (mail-northeuropeazon11011037.outbound.protection.outlook.com [52.101.65.37])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby smtp.subspace.kernel.org (Postfix) with ESMTPS id 959E6426D36;\n\tThu, 30 Apr 2026 11:07:31 +0000 (UTC)","from AM9PR04MB8585.eurprd04.prod.outlook.com (2603:10a6:20b:438::13)\n by VI1PR04MB7182.eurprd04.prod.outlook.com (2603:10a6:800:121::7) with\n Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9870.20; Thu, 30 Apr\n 2026 11:07:21 +0000","from AM9PR04MB8585.eurprd04.prod.outlook.com\n ([fe80::f010:fca8:7ef:62f4]) by AM9PR04MB8585.eurprd04.prod.outlook.com\n ([fe80::f010:fca8:7ef:62f4%4]) with mapi id 15.20.9846.025; Thu, 30 Apr 2026\n 11:07:21 +0000"],"ARC-Seal":["i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116;\n\tt=1777547253; cv=fail;\n b=MaLS6BhJQATszY9Y2xdNK856BfjYzoaMnKia/ncjUeGrdDSfuqgSSDy8YqRv/8IwV7/gOLSi+zFTBTAPkLOq3b7eC5FZuTNECB/uQq5ctoaLYhYmRuev2yyGc52DVBAL2x/Gn2x1//taGWE/G6TjHlHRjpNDNkDQ1b+7rAESx2Y=","i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none;\n b=O3BKgWGHAHAbStytQpD473qHz9JsCtp3LgHcdFFPWgIfLUruFhAbBFa/gOU5eFsKM0hQSvc8IXFLRvZ/7HTSIiz3nSp/UUhw3cac2Lf9KEEfur3Db07w92FJ07ojwsYnI5YeqDYMlRjWx+Y+7brDOP3QYFLlDTI46/5ol0IOMSWDT0kk63EnYZL5ETk91qv1e9+HjkWnjw4q057wOmD/2W4g0Py7QAlqG257zX1JTfV0+77EPFQvaiihQMP6ni/CJHqBQuW/umWmvlrRqoFSRxpWV54LdCGcWbGeVlPNZ0qWzUybW5LeIyYEPzCd6MH4Rt0cjc83G/io496lhe+qVQ=="],"ARC-Message-Signature":["i=2; a=rsa-sha256; d=subspace.kernel.org;\n\ts=arc-20240116; t=1777547253; c=relaxed/simple;\n\tbh=1jbR8ctvdwfWn2+V0Am+qBM8BmtJ5xZ5CM0TNSwx3yY=;\n\th=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References:\n\t Content-Type:MIME-Version;\n b=cnSKEhEI5YrWZQi5/6b6eui4bstgzMPZMnt0tke5Lg4R6zXppqx7tVBJ4UdX50km2zPl2uFUsbUOgiVVfS52ASyWgbAdTlHEIQh6JnjJzI7uleHVilQ5owPjp0yPfPeSmEWa9GMVVt2tKcomMsuvhIlY9BZgxWOZgfXL8prOVw8=","i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com;\n s=arcselector10001;\n 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;\n bh=G5FCjmEG1XDGz3sCPq9VXRXcsutJAgvtv8mVJdpgqgo=;\n b=tQg2osPf6RWRe7vuaKRvc6QOMphBhilDAqEnzWzCyXPIYcEb6nhxSQAOgj1vK8Ir0yTM+l1vZsXww/mnilPnJLkovXEZaU1pTN0JBOw4Cyhbb9LzKckos/IK5qXhXwGOF7eIxEfDVgWFMNsITtW1HlZHB4m1gsfY1BVVKdXaLGqhqYpoI0Gveap2hmqHO+gWTvkOQWSMvwvmhL4LEdilono11RMEg+Xp6hbjrdbp7g3IQrjh5Xci3TZbWBD6ho2Cs2ksG2WTQPQH+QLAK5F7fIwTcdaUUrYY1vHgH+CrNuN/MywPVGOEXpi1I8ejYKDc5PrdEQ1oadstaVhHVK9Qng=="],"ARC-Authentication-Results":["i=2; smtp.subspace.kernel.org;\n dmarc=pass (p=none dis=none) header.from=nxp.com;\n spf=pass smtp.mailfrom=nxp.com;\n dkim=pass (2048-bit key) header.d=nxp.com header.i=@nxp.com\n header.b=UMBFweKF; arc=fail smtp.client-ip=52.101.65.37","i=1; mx.microsoft.com 1; spf=pass\n smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass\n header.d=nxp.com; arc=none"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;\n bh=G5FCjmEG1XDGz3sCPq9VXRXcsutJAgvtv8mVJdpgqgo=;\n b=UMBFweKFxaHFLRqnCq42ai/dLrol9kBw8noQVypRevSjvZ53U5fMdcExa+J9z4Yl+9yiTlrUtTZRbsCDU99bmSO+d9y/hVwMI1AJGlx/Ou51j4dRbeV37+3itK7iWGx9yKpjlp/TNEL12ryRU2OVNAYvOy/2U7Unp+kJxYE9S7GJhp4GOMNH9rY3K9oVX3D2OE3gzSGNJa4rhiuJB0aKoWMrgGeAe0yPNxj+VeCC5WYJCa+8aqnxpYO3pUXn6aKMJpL5WTmgsK5M7vG7Zpq0s1TN5op4VbFxhmv9vo4LGfWGH+HCf5DJ5x2ltgMH6pTecXOiR+AyZwi2a0NAEtXdNA==","From":"Vladimir Oltean <vladimir.oltean@nxp.com>","To":"linux-phy@lists.infradead.org","Cc":"Vinod Koul <vkoul@kernel.org>,\n\tNeil Armstrong <neil.armstrong@linaro.org>,\n\tdri-devel@lists.freedesktop.org,\n\tfreedreno@lists.freedesktop.org,\n\tlinux-arm-kernel@lists.infradead.org,\n\tlinux-arm-msm@vger.kernel.org,\n\tlinux-can@vger.kernel.org,\n\tlinux-gpio@vger.kernel.org,\n\tlinux-ide@vger.kernel.org,\n\tlinux-kernel@vger.kernel.org,\n\tlinux-media@vger.kernel.org,\n\tlinux-pci@vger.kernel.org,\n\tlinux-renesas-soc@vger.kernel.org,\n\tlinux-riscv@lists.infradead.org,\n\tlinux-rockchip@lists.infradead.org,\n\tlinux-samsung-soc@vger.kernel.org,\n\tlinux-scsi@vger.kernel.org,\n\tlinux-sunxi@lists.linux.dev,\n\tlinux-tegra@vger.kernel.org,\n\tlinux-usb@vger.kernel.org,\n\tnetdev@vger.kernel.org,\n\tspacemit@lists.linux.dev,\n\tUNGLinuxDriver@microchip.com,\n\tGreg Kroah-Hartman <gregkh@linuxfoundation.org>,\n\tJC Kuo <jckuo@nvidia.com>,\n\tJohan Hovold <johan+linaro@kernel.org>,\n\tJonathan Hunter <jonathanh@nvidia.com>,\n\tMathias Nyman <mathias.nyman@intel.com>,\n\tThierry Reding <thierry.reding@gmail.com>","Subject":"[PATCH v7 phy-next 14/27] usb: gadget: tegra-xudc: avoid direct\n dereference of phy->dev.of_node","Date":"Thu, 30 Apr 2026 14:06:39 +0300","Message-Id":"<20260430110652.558622-15-vladimir.oltean@nxp.com>","X-Mailer":"git-send-email 2.34.1","In-Reply-To":"<20260430110652.558622-1-vladimir.oltean@nxp.com>","References":"<20260430110652.558622-1-vladimir.oltean@nxp.com>","Content-Transfer-Encoding":"8bit","Content-Type":"text/plain","X-ClientProxiedBy":"AM0PR10CA0004.EURPRD10.PROD.OUTLOOK.COM\n (2603:10a6:208:17c::14) To AM9PR04MB8585.eurprd04.prod.outlook.com\n (2603:10a6:20b:438::13)","Precedence":"bulk","X-Mailing-List":"linux-tegra@vger.kernel.org","List-Id":"<linux-tegra.vger.kernel.org>","List-Subscribe":"<mailto:linux-tegra+subscribe@vger.kernel.org>","List-Unsubscribe":"<mailto:linux-tegra+unsubscribe@vger.kernel.org>","MIME-Version":"1.0","X-MS-PublicTrafficType":"Email","X-MS-TrafficTypeDiagnostic":"AM9PR04MB8585:EE_|VI1PR04MB7182:EE_","X-MS-Office365-Filtering-Correlation-Id":"e5e892bb-aad7-4e75-7375-08dea6a8a650","X-MS-Exchange-SenderADCheck":"1","X-MS-Exchange-AntiSpam-Relay":"0","X-Microsoft-Antispam":"\n\tBCL:0;ARA:13230040|10070799003|7416014|376014|366016|19092799006|1800799024|18002099003|56012099003|22082099003;","X-Microsoft-Antispam-Message-Info":"\n\tVjxm4dT4YyrAAns68Zk2tH54RuyQO39C91uPBT8f0gJz7f95Yzt1H6bSZNDv7S3jrD64N/liAlRMnr7uqw3MZ0/COe0b2WYOp9i90bRAKOmsTG/KLPHJLZ/7M8BLp0vITL2MtwHExZEeY2Ho7ramZ4fYFNotfW/nMU55bbQP8NZLhoz624hOtsdXFZfgLwYjOEU1zfcNssoXnzfL+r92LOKoPQyJ89iRstr+Ky9reM1s6Z+gerU166pZCirWYw5j+/iMWIYKyxAfmPjPhBm0T6NYju+wqJOnvH05JTkadM+rAB2zlsBIYQ0k2//7Q1jkgpdW5CCskUNOZ3LBm1D9rUXlr2nXLf9OsIgr4I0pAUTzTCY+/SM3GSYcy9TUGmi/ZzlJxFO6eOZo+6gWzoyaWrBfCg3NLZmJI5NjrBOgz3lprgjrvxu69xl174+NeSJ07zo3EL7lldE3dWyF19eDcKy500c2QPH9G3B8u6GYYpKfZoZ3D569Phh3/KtONs17WOmzkZp6lZ4x8x3GMRwzf4IuWnfvkIkv1JekjvMSTGDoSkL3BlwhBN+3MnumZCmZ+BUKysVDg6z5qZPjAaAPTqV8tA7nCYcRws0u5xpcTn9p03wnRWnCXRgaLZ5VvsAJVqRAZ5TzMUBWOIB3SNUGu6MbHMlgzEPwvN3gQ18BGP0NQ41lnWbLCmPLQoLwOhqA4r5foqI5UyQTVqcW1A9xFnQO76dm9cEXGaNqtx8sBn4=","X-Forefront-Antispam-Report":"\n\tCIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AM9PR04MB8585.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(10070799003)(7416014)(376014)(366016)(19092799006)(1800799024)(18002099003)(56012099003)(22082099003);DIR:OUT;SFP:1101;","X-MS-Exchange-AntiSpam-MessageData-ChunkCount":"1","X-MS-Exchange-AntiSpam-MessageData-0":"\n GOSUmq02vXVyKIg667nUdJkomAM/j9xzmmGgg8x27Ib0TX/e/NZZwFpRGKaDLnGpoEx0dx/Rjj1R7/nl5/L5cKm//bCGBdGpLX2jmYW/pGN/pj0pND+PjiIXEZ5iE+oS6cmiFApOfQOEbIDLL+FFMABMGSxOUx7Zjg/XP2pvAza4807AhbxCKk+75if+2ZJGtLssJkirIXRzzltnUth/nOoBH/kz3IK3McRdLMnzjFLB0QqiVQsVrmD7nEdfeqbELtdtHcxV7BiYbzinqvCaai92jxfFz4X0kizIrkCjR83GSpAHMDo/mGPP3dNOFKMSkMaaZ7cGrlG11rnMHsePPOsGIZJfNDmKq//nJt3PRl5s+qwEnfgbRFdQE3ihmiebOpM+edkMxf4XvbZrWptsTg/czVtCPnIH7qMEQ7HCQX378DhOmz7QgR6YtD5A2/EfpRNnn8AsWbfNZfouMBsXpRzQWboC2BAj+VRe7mvTOXbvjXqCabH3mGVfHVzz7ilO83LuGaB3QamNa1sWXIIREZvScW7Q5A2RK/nLZx9STapnctZBszcXsD4+VmVMI0sOnbUAVfud4A64GkLxkXgPkB252DocKWCsl7aIVQXOBa2hMDe11iTuE3aOwmbAKaLB0v7QP5oJEZFDJ6wCSMdlF/EO5hI0ebnb94ZVFXrRY98Kk8D6USVaA45670JAYlrrIQl71yVeXK77BFfNpdLewn28V97mNCXPpJEOcsOsGsByBG4wnCYdgp+er4s4WQjx5EnBOnLUylEM+EnYOqvn1Qc6DO0oA9CpYhgJxZ5N+K/+FcOMXIgUKKxqdp+kGJoQzMOI26y05Y/+M0Jtwd0MoO6DE7OnCz2/CEjv9XsVkfOPteovcEn4Vh6dQegIr2+56dbRNamwHwJgTZOYIhIhFU+W0z0pnR7LRZQV1JHFp16INzL4BiTeW1WJfF7kXYYUQqzNh+Yatc8P5RUlerLYIK9bj13tvzBRvs+uHOk3EDnRL6M5pSaAjkf9zWik7VdBXP8sfONe39Nt8WDXSYgaNpB6/J/m5xrIW2TXYWaAE/jCgNjhZAWMSKTRdH/y5wWjTf36uP4bKYHA+XBeM/6CmoXQpPg15kJe99OZnmdMPsZ2KnRt6jSTS3hU7pHGsnRQXD9l8g5pdVuU5NqKKiEJQ8B2seRcIBDyLpPSQ4bXPrdTRhBPlAlRlZMKwFdkvyyav2StpSd6T7jdYJbtxuvT8IFiHEls1fwOwTArYEtsdCn/jF2E8W8Mc48K289K4J3kGEwMkM1xIhhcjAhVdayMoIyxRpsXfiPZcFZjxvzfI1Kj5BoQs3osUdp7tMjRLgVYdJjyPYUW3yV3AhaCU+RJ7rGDjBlTLbyQvxgiRHnfaxynMnUKQXnkkRZKXHE7cjff5HbXHff8wptB9l0nSIbjJpaxCy5R9dbs8qkRst8PKUtxj340aI2SZpm88NP8xqxCTZpMXwKRg+jonSZmfIqVVhscInv0+XEb+RWp9k0Yz+hgiAvWqDt0Nyy4dcJ+LvOGjZyF2S1/VNC/PnQJW2kgk0ghHaeljTyDUgv09qOKXoBo5uF65FjY9AvaAb5If/6il5ziARCXlgIxiKGCHf2JQKqXnGxTjrgaqbD/ii7VG4noq/sf4CAVqDJIalnPO1S434AjYIOTGFVzRKV4G8MbzT0VanE/QZ9MoJ7SCTg/5R3iIk+iMKcLpiypTi1oFBHlOWpTx04bjVNxgr8/hd9eiMwV/G2TrFjjJ/AVvHp0IKrSvBiwalYjIEGcknozCUiX","X-OriginatorOrg":"nxp.com","X-MS-Exchange-CrossTenant-Network-Message-Id":"\n e5e892bb-aad7-4e75-7375-08dea6a8a650","X-MS-Exchange-CrossTenant-AuthSource":"AM9PR04MB8585.eurprd04.prod.outlook.com","X-MS-Exchange-CrossTenant-AuthAs":"Internal","X-MS-Exchange-CrossTenant-OriginalArrivalTime":"30 Apr 2026 11:07:20.9807\n (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":"\n x8EGf2P8v4K0XOZvRQI+9IBdZ+H+sDVngmOBs60CmjT9R1w/swBSVhiNG+zSanxsx5FpWwSMaByuhI+6CXtAOw==","X-MS-Exchange-Transport-CrossTenantHeadersStamped":"VI1PR04MB7182"},"content":"In a somewhat similar situation as the Tegra USB host controller driver,\nthe Tegra XUDC driver for USB gadget mode needs to get to a struct\nusb_phy that sits behind the same OF node as the Generic PHY. It does\nthat directly, which will no longer be possible. The PHY provider is\nalso the xusb padctl driver.\n\nThe rework here is also to implement a parallel OF node lookup path\nbased on the \"phys\" phandle and the #phy-cells of the padctl provider.\n\nSome further notes:\n- create a local \"usbphy\" variable to hold the devm_usb_get_phy_by_node()\n  output. This makes the error checks more obvious (avoids keeping an\n  error-encoded pointer in xudc->usbphy[i] even temporarily).\n- the \"if (IS_ERR(utmi_phy)) .. else if (utmi_phy) .. else if (!utmi_phy)\"\n  pattern can be simplified, considering that neither the IS_ERR() nor\n  the NULL case continue execution in the current block. Therefore, we\n  can move the case where the \"utmi_phy\" is a valid pointer outside the\n  \"if\" checks, and this reduces the code indentation level.\n\nSigned-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>\n---\nCc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>\nCc: JC Kuo <jckuo@nvidia.com>\nCc: Johan Hovold <johan+linaro@kernel.org>\nCc: Jonathan Hunter <jonathanh@nvidia.com>\nCc: Mathias Nyman <mathias.nyman@intel.com>\nCc: Thierry Reding <thierry.reding@gmail.com>\n\nv5->v7: none\nv4->v5: patch is new\n---\n drivers/usb/gadget/udc/tegra-xudc.c | 35 ++++++++++++++++++++---------\n 1 file changed, 24 insertions(+), 11 deletions(-)","diff":"diff --git a/drivers/usb/gadget/udc/tegra-xudc.c b/drivers/usb/gadget/udc/tegra-xudc.c\nindex e9d33be02866..cf4e6c87e44d 100644\n--- a/drivers/usb/gadget/udc/tegra-xudc.c\n+++ b/drivers/usb/gadget/udc/tegra-xudc.c\n@@ -3494,6 +3494,7 @@ static void tegra_xudc_device_params_init(struct tegra_xudc *xudc)\n \n static int tegra_xudc_phy_get(struct tegra_xudc *xudc)\n {\n+\tstruct device_node *np = dev_of_node(xudc->dev);\n \tint err = 0, usb3_companion_port;\n \tunsigned int i, j;\n \n@@ -3515,7 +3516,10 @@ static int tegra_xudc_phy_get(struct tegra_xudc *xudc)\n \txudc->vbus_nb.notifier_call = tegra_xudc_vbus_notify;\n \n \tfor (i = 0; i < xudc->soc->num_phys; i++) {\n+\t\tstruct of_phandle_args args;\n \t\tchar phy_name[] = \"usb.-.\";\n+\t\tstruct usb_phy *usbphy;\n+\t\tint index, err;\n \n \t\t/* Get USB2 phy */\n \t\tsnprintf(phy_name, sizeof(phy_name), \"usb2-%d\", i);\n@@ -3525,22 +3529,31 @@ static int tegra_xudc_phy_get(struct tegra_xudc *xudc)\n \t\t\tdev_err_probe(xudc->dev, err,\n \t\t\t\t\"failed to get PHY for phy-name usb2-%d\\n\", i);\n \t\t\tgoto clean_up;\n-\t\t} else if (xudc->utmi_phy[i]) {\n-\t\t\t/* Get usb-phy, if utmi phy is available */\n-\t\t\txudc->usbphy[i] = devm_usb_get_phy_by_node(xudc->dev,\n-\t\t\t\t\t\txudc->utmi_phy[i]->dev.of_node,\n-\t\t\t\t\t\tNULL);\n-\t\t\tif (IS_ERR(xudc->usbphy[i])) {\n-\t\t\t\terr = PTR_ERR(xudc->usbphy[i]);\n-\t\t\t\tdev_err_probe(xudc->dev, err,\n-\t\t\t\t\t      \"failed to get usbphy-%d\\n\", i);\n-\t\t\t\tgoto clean_up;\n-\t\t\t}\n \t\t} else if (!xudc->utmi_phy[i]) {\n \t\t\t/* if utmi phy is not available, ignore USB3 phy get */\n \t\t\tcontinue;\n \t\t}\n \n+\t\tindex = of_property_match_string(np, \"phy-names\", phy_name);\n+\t\tif (index < 0)\n+\t\t\tcontinue;\n+\n+\t\terr = of_parse_phandle_with_args(np, \"phys\", \"#phy-cells\",\n+\t\t\t\t\t\t index, &args);\n+\t\tif (err)\n+\t\t\tcontinue;\n+\n+\t\t/* Get usb-phy, if utmi phy is available */\n+\t\tusbphy = devm_usb_get_phy_by_node(xudc->dev, args.np, NULL);\n+\t\tof_node_put(args.np);\n+\t\tif (IS_ERR(usbphy)) {\n+\t\t\terr = PTR_ERR(usbphy);\n+\t\t\tdev_err_probe(xudc->dev, err,\n+\t\t\t\t      \"failed to get usbphy-%d\\n\", i);\n+\t\t\tgoto clean_up;\n+\t\t}\n+\t\txudc->usbphy[i] = usbphy;\n+\n \t\t/* Get USB3 phy */\n \t\tusb3_companion_port = tegra_xusb_padctl_get_usb3_companion(xudc->padctl, i);\n \t\tif (usb3_companion_port < 0)\n","prefixes":["v7","phy-next","14/27"]}