From patchwork Fri Apr 30 09:15:12 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiko Schocher X-Patchwork-Id: 12232825 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 35BC9C433B4 for ; Fri, 30 Apr 2021 09:17:12 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A7D4061456 for ; Fri, 30 Apr 2021 09:17:11 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A7D4061456 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version: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=7u3YBQ/5zpVgi5CVRcVo8TeBtWfBEuzGNrhfTmw7GwY=; b=Q9wVbWBmUo/rDWktxBBKNzKV05 0dxq8wYYvHEyT168tzZMlI2sl9rTSA10LdJdqdlxz85tIEtL46x9srButObAmwELg6uF0lX7Zpm3i qWWnP6V8qbdovwU8UlkzUo2JzDJJ+AGYNL7UrkSnWmkkKLfHoRDvt31FZsy0yacmk7mwDeCCt3QDi 4qR8dlI0ctm6VXnIjzxhL/Kj/kwRRfe5ZuLfmANiKWGlstX81EYPG9KQkjJQVJ8kmAUTAmbA0nuM5 x/C393Isp0pscfJmpEQFjUDMKVbYhh2hKzWj7PBAEzIdWX9u5nzlnUSTrLpGioCMuObPO5f1NArCb 0VxOOjeQ==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lcPFK-007abc-Mr; Fri, 30 Apr 2021 09:15:38 +0000 Received: from bombadil.infradead.org ([2607:7c80:54:e::133]) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lcPFG-007abO-NU for linux-arm-kernel@desiato.infradead.org; Fri, 30 Apr 2021 09:15:35 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type: Content-ID:Content-Description:In-Reply-To:References; bh=7jNtsVgB4SG/t7bVzmOnoK100qiLWUCRQWcjzl5Jnro=; b=0n1I+UTdWkoy7KL1IaG76Ftw4d LI7JKMyJX9pc5+w0AThF3MvxSZHEXuqWmZYFqByuTSt8Qbu+nsXQ8Go/9ry+YLfBSPbIb0GxQt2Ch MN5L1y6nyhnBSAP+0WaNDQnOt0/TtBGEx8Ak1DSGhs9C7kcOc7KmIOYAwAuMKsya7/jehOv10woku qLGUCevYwDir/Uyk38xy60JkZUDUAdktL3XhsWl0bf7pENBlw3taK40oPgS/cTvHuyb1rFkf3mO07 TRVVtGYJ32ucqL0boCWJTgy1nXSNEykwkThj66MGK+UslJznwTp+B9Etlamv/6OQ8GmPpeKH3z4KE 7TqrAkwg==; Received: from phobos.denx.de ([2a01:238:438b:c500:173d:9f52:ddab:ee01]) by bombadil.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lcPFC-001GYp-Tu for linux-arm-kernel@lists.infradead.org; Fri, 30 Apr 2021 09:15:33 +0000 Received: from mail-internal.denx.de (p578adb1c.dip0.t-ipconnect.de [87.138.219.28]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: noc@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 3E9A282A9E; Fri, 30 Apr 2021 11:15:25 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1619774125; bh=7jNtsVgB4SG/t7bVzmOnoK100qiLWUCRQWcjzl5Jnro=; h=From:To:Cc:Subject:Date:From; b=S0i44PnolwKiZ+ZZ7Oj2jpqyhtzRSqWrQpQzLqM3PIjVDXgZngRHbXkTj48mGudly vbAec1SehaT5tA8pcqhDsmWVtSDTjo+jlKpmw64zq/66YvPWDtd65a4BS/RMWPcKQa QBF2djjytVcrspocME2je2aqIwZeXbIlJvFMx1CfVKTjygf7fojVfyPyKA/vNO1nV0 zt0YaP1hI7CGhPub8ZtQEGULnzA/Aclpt/D/BTJbEZIJdNi+sO9gt0fcVuU+RyjeDd LWPcl1gUsAXpdw+OYYpoC3ieM0AqLJGyeO1BtdB74IYju86BCvRgx/JSSMDA0+WQAC XZKojyAN6LDHA== Received: from pollux.denx.de (pollux [192.168.1.1]) by mail-internal.denx.de (Postfix) with ESMTP id 93C91182B81; Fri, 30 Apr 2021 11:15:16 +0200 (CEST) Received: by pollux.denx.de (Postfix, from userid 515) id 58BCD1A8BAD; Fri, 30 Apr 2021 11:15:16 +0200 (CEST) From: Heiko Schocher To: linux-arm-kernel@lists.infradead.org Cc: Heiko Schocher , Fabio Estevam , Felipe Balbi , Greg Kroah-Hartman , NXP Linux Team , Pengutronix Kernel Team , Sascha Hauer , Shawn Guo , Teresa Remmet , Zhen Lei , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org Subject: [PATCH] usb: dwc3: imx8mp: detect dwc3 child nodes with name "usb*" Date: Fri, 30 Apr 2021 11:15:12 +0200 Message-Id: <20210430091512.1026996-1-hs@denx.de> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 X-Virus-Scanned: clamav-milter 0.102.4 at phobos.denx.de X-Virus-Status: Clean X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210430_021532_109245_0BD4D790 X-CRM114-Status: GOOD ( 11.79 ) 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 commit: d1689cd3c0f4: ("arm64: dts: imx8mp: Use the correct name for child node "snps, dwc3") renamed "dwc3@3*" nodes in imx8mp.dtsi to "usb@3*" glue layer dwc3-imx8mp.c searches for "dwc3" and so drop failure on boot: imx8mp-dwc3 32f10100.usb: failed to find dwc3 core child imx8mp-dwc3: probe of 32f10100.usb failed with error 1 imx8mp-dwc3 32f10108.usb: failed to find dwc3 core child imx8mp-dwc3: probe of 32f10108.usb failed with error 1 now. Fix this (and allow old style too) Tested on "PHYTEC phyBOARD-Pollux i.MX8MP" board. fixes: d1689cd3c0f4: ("arm64: dts: imx8mp: Use the correct name for child node "snps, dwc3") Signed-off-by: Heiko Schocher --- drivers/usb/dwc3/dwc3-imx8mp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/usb/dwc3/dwc3-imx8mp.c b/drivers/usb/dwc3/dwc3-imx8mp.c index b13cfab89d532..eb85ddc50f7c7 100644 --- a/drivers/usb/dwc3/dwc3-imx8mp.c +++ b/drivers/usb/dwc3/dwc3-imx8mp.c @@ -165,7 +165,8 @@ static int dwc3_imx8mp_probe(struct platform_device *pdev) if (err < 0) goto disable_rpm; - dwc3_np = of_get_child_by_name(node, "dwc3"); + dwc3_np = of_get_child_by_name(node, "usb") ? : + of_get_child_by_name(node, "dwc3"); if (!dwc3_np) { dev_err(dev, "failed to find dwc3 core child\n"); goto disable_rpm;