Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp798937rwr; Wed, 26 Apr 2023 06:35:09 -0700 (PDT) X-Google-Smtp-Source: AKy350bDme3V0+C6Pu2m4aqpG4nCZ/QLa3ZWXclQKw7o3cHMcdR+2TQuWLOAvfVhHC3BpxhcuNss X-Received: by 2002:a17:902:dacc:b0:19e:ab29:1ec2 with SMTP id q12-20020a170902dacc00b0019eab291ec2mr28933509plx.65.1682516108776; Wed, 26 Apr 2023 06:35:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682516108; cv=none; d=google.com; s=arc-20160816; b=M6VyMPIMC6uFdf9GuDebfDYx/OKq8mPavKy7J4PIUBJnPqwKyDlkctitMcFBcU90ih zuFwtd/YYt/X94l5SL1155ddjm3zwEkAQHV3vsmpMZk5crRUAmmq7AgENQHJ+pLDxK9Y Pm73yNUfXoyHW3m5YSfd4CcQUIRdMittRvGHNQPvRNbBcLfa1PROSiJd3TeIoosgeGrn bHwST8NwUQxed27MgReYrKbV3+kzUCVmvtKAeaahzfIPapvFASEnJ/y6Q2ujx/Cq6iYW qSUfBo+nRNSABrdp/kMbk2rMIvkae/peHK5F7VNcTwWA2NvQZM7H/446svIA17PTf+31 XHMA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=QdepxYuSwTdOmEf8k5cCZjOM29OP5/kofyPKcNTFUVo=; b=Ewh2MIvaq63hRE+VU2BS6XxGbwLTev18gVWKsRm+FceV14CQcAP1Cyg+ThpaPyxzt+ +U5bf4r89s4SbShkgGtF4nD++YoE39IRIYcyky8RkZk7eXB/5yq25RrLBBgsY6caRV8T eu/dzAwRJ11fkFeZqrO2m1IyNwOiGheLqV24ujsGGevW6qtldEYj+M0OEcV36Cq6PLbc enCib7bmuSNXYjXLyr4k0Je36JGDIWHZWma+K2b8FztD3no5JsmNtdso2aYyFOaU9cj/ 6rwnqEMv6jGIMD05AEAlQ6/RDjSXHQyB6KSS/MeA1bFh6qGwdg6+OmSuchyt43XKanAX S0Mw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=k7thEKT9; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a17-20020a170902ecd100b001a6fce122basi17387389plh.322.2023.04.26.06.34.54; Wed, 26 Apr 2023 06:35:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=k7thEKT9; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241117AbjDZNV6 (ORCPT + 99 others); Wed, 26 Apr 2023 09:21:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53972 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241000AbjDZNVz (ORCPT ); Wed, 26 Apr 2023 09:21:55 -0400 Received: from fllv0016.ext.ti.com (fllv0016.ext.ti.com [198.47.19.142]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 87D1BC3; Wed, 26 Apr 2023 06:21:53 -0700 (PDT) Received: from lelv0265.itg.ti.com ([10.180.67.224]) by fllv0016.ext.ti.com (8.15.2/8.15.2) with ESMTP id 33QDLkW4096750; Wed, 26 Apr 2023 08:21:46 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1682515306; bh=QdepxYuSwTdOmEf8k5cCZjOM29OP5/kofyPKcNTFUVo=; h=Date:Subject:To:CC:References:From:In-Reply-To; b=k7thEKT9zPmrKcNVux/rKwIuW3iqOkvhengLrEOwOaV5GtVzjPD7gSEj+rMVe6KRZ QGF4D57JMY5EdrCSumYXs2M2kBqd0+iviDOj+jAtx2fiWvFRE32q6Y4l8dfHUHK2es yMYzjbH8BSG52dU74Z7vtxg9jr89NDVennyHlkPU= Received: from DLEE112.ent.ti.com (dlee112.ent.ti.com [157.170.170.23]) by lelv0265.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 33QDLku7022065 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Wed, 26 Apr 2023 08:21:46 -0500 Received: from DLEE112.ent.ti.com (157.170.170.23) by DLEE112.ent.ti.com (157.170.170.23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.16; Wed, 26 Apr 2023 08:21:45 -0500 Received: from lelv0327.itg.ti.com (10.180.67.183) by DLEE112.ent.ti.com (157.170.170.23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.16 via Frontend Transport; Wed, 26 Apr 2023 08:21:45 -0500 Received: from [10.250.35.77] (ileaxei01-snat.itg.ti.com [10.180.69.5]) by lelv0327.itg.ti.com (8.15.2/8.15.2) with ESMTP id 33QDLjfG001825; Wed, 26 Apr 2023 08:21:45 -0500 Message-ID: <163cfe60-4b14-fe5c-29d9-323e7ea495d5@ti.com> Date: Wed, 26 Apr 2023 08:21:45 -0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.9.0 Subject: Re: [RFC PATCH 1/2] arm64: dts: ti: k3-j721s2-main: Add main CPSW2G devicetree node Content-Language: en-US To: Nishanth Menon , Siddharth Vadapalli CC: , , , , , , , , References: <20230426105718.118806-1-s-vadapalli@ti.com> <20230426105718.118806-2-s-vadapalli@ti.com> <20230426125927.itfd76cpvy32zur7@scrimmage> From: Andrew Davis In-Reply-To: <20230426125927.itfd76cpvy32zur7@scrimmage> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-Spam-Status: No, score=-6.0 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_MED,SPF_HELO_PASS,SPF_PASS,T_SCC_BODY_TEXT_LINE, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 4/26/23 7:59 AM, Nishanth Menon wrote: > On 16:27-20230426, Siddharth Vadapalli wrote: >> From: Kishon Vijay Abraham I >> >> TI's J721S2 SoC has a MAIN CPSW2G instance of the CPSW Ethernet Switch. >> Add devicetree node for it. >> >> Signed-off-by: Kishon Vijay Abraham I >> Signed-off-by: Siddharth Vadapalli >> --- >> arch/arm64/boot/dts/ti/k3-j721s2-main.dtsi | 69 ++++++++++++++++++++++ >> 1 file changed, 69 insertions(+) >> >> diff --git a/arch/arm64/boot/dts/ti/k3-j721s2-main.dtsi b/arch/arm64/boot/dts/ti/k3-j721s2-main.dtsi >> index 6629b2989180..14dfef7b0758 100644 >> --- a/arch/arm64/boot/dts/ti/k3-j721s2-main.dtsi >> +++ b/arch/arm64/boot/dts/ti/k3-j721s2-main.dtsi >> @@ -51,6 +51,12 @@ usb_serdes_mux: mux-controller@0 { >> mux-reg-masks = <0x0 0x8000000>; /* USB0 to SERDES0 lane 1/3 mux */ >> }; >> >> + phy_gmii_sel_cpsw: phy@34 { >> + compatible = "ti,am654-phy-gmii-sel"; >> + reg = <0x34 0x4>; >> + #phy-cells = <1>; >> + }; > > > See this thread: https://lore.kernel.org/all/76da0b98-3274-b047-db11-ecabc117ae11@ti.com/ > "ti,am654-phy-gmii-sel" already has "reg", so this DT is good as is. Adding the driver fallback to use that when the parent is not a "syscon" node should be as easy as this: --- a/drivers/phy/ti/phy-gmii-sel.c +++ b/drivers/phy/ti/phy-gmii-sel.c @@ -435,9 +435,12 @@ static int phy_gmii_sel_probe(struct platform_device *pdev) priv->regmap = syscon_node_to_regmap(node->parent); if (IS_ERR(priv->regmap)) { - ret = PTR_ERR(priv->regmap); - dev_err(dev, "Failed to get syscon %d\n", ret); - return ret; + priv->regmap = device_node_to_regmap(node); + if (IS_ERR(priv->regmap)) { + ret = PTR_ERR(priv->regmap); + dev_err(dev, "Failed to get syscon %d\n", ret); + return ret; + } } I'll send this patch when the window opens. Andrew