Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp226171pxb; Mon, 2 Nov 2020 19:58:18 -0800 (PST) X-Google-Smtp-Source: ABdhPJzY5iA+kAZXCJbaGjl0ebJ1I01MbnGrtgkqlIe98vq8iwyFTHDDn5ZKLjPttBl01qCHs0vp X-Received: by 2002:a17:906:70cf:: with SMTP id g15mr17825361ejk.323.1604375898001; Mon, 02 Nov 2020 19:58:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604375897; cv=none; d=google.com; s=arc-20160816; b=SBMFDpuQDza71+8C+AH9H3u7q2UjfjzTlRNwkKxfBEU8JUW2yHmx7PEsSlpCB6hYMZ t5gfqiqZ8DxfIDO4PSF2ZnGt9ItSXXOXBQBRwcmjtls8lNhMGkyySSuY4E8+CNhj18o7 QyLJWTHzrBRvF6pAKjXempotf1uJ/scKM+RXlnTdqM9ZEfqiN9HX4Rx88+HCcqqPP6hL bgMXbs4UepHyp07oykXNTW/+IpEWsXj9i5mZquGpEqMUxSL++0PUm3b0RDnadpy2zFSd T18nPUqikOZRpiWzw121kwlUfEDIZS58+PxLf2ukpyA1t+6lNe+s7cPr8szVysCIV+ym rAmw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=SwK1bQtA3dhsn47NOkiZACrcQx2a12YjrBGCfk/t97I=; b=t95Ka7RzOqTpjuykXalEm6YeD5tsKQLBZXtQlUtaxFtelKz012bpzb9RJq23QxMc5l 9fEQvw4loo28zVVe1VUdrPlH8Zktwqm13MCbOyZeNuDfBEaw1CbNfdFpmAZbi4wtXt00 h8iFF1RMDrKUjpFcgZAiz3eMDvco2iBWpKuBRgX00XVFd97dqMkQ9JaFw8YcVGiIF/nS JZUxBen1/e8+ndFrzK797n+JFxcZp0avv9iuoQCSxcAJ2L6B1JHY59ntBJZvDSA3Du+L GXpu6xN0hoDHkT6ASQHeMYgfowuGg1hhBjcGzqiLG5xMVzwO2cD6xQ9PWMJ2JubzYeld aCAA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=q8aWQtyO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d10si4046581ejh.20.2020.11.02.19.57.55; Mon, 02 Nov 2020 19:58:17 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=q8aWQtyO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S1727396AbgKCD4Y (ORCPT + 99 others); Mon, 2 Nov 2020 22:56:24 -0500 Received: from fllv0016.ext.ti.com ([198.47.19.142]:39528 "EHLO fllv0016.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727186AbgKCD4W (ORCPT ); Mon, 2 Nov 2020 22:56:22 -0500 Received: from lelv0265.itg.ti.com ([10.180.67.224]) by fllv0016.ext.ti.com (8.15.2/8.15.2) with ESMTP id 0A33uIaI023695; Mon, 2 Nov 2020 21:56:18 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1604375778; bh=SwK1bQtA3dhsn47NOkiZACrcQx2a12YjrBGCfk/t97I=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=q8aWQtyO7qE4oZPKLSj0JZf2CIPSWt8mnkyO1pEx2WLb2k1+zXdDustd6lJaYPHAt P3xMdXXg/m45yGQeFqOHG4avwg0xzYs2MDXAflv8OQttkKYz1wLRFUAZnUC36Pgkz9 mySQXikeSzHxXFoul4qPkzcGUwlygxxiupR+Zvg8= Received: from DFLE102.ent.ti.com (dfle102.ent.ti.com [10.64.6.23]) by lelv0265.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 0A33uIL5112155 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 2 Nov 2020 21:56:18 -0600 Received: from DFLE111.ent.ti.com (10.64.6.32) by DFLE102.ent.ti.com (10.64.6.23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1979.3; Mon, 2 Nov 2020 21:56:07 -0600 Received: from fllv0039.itg.ti.com (10.64.41.19) by DFLE111.ent.ti.com (10.64.6.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1979.3 via Frontend Transport; Mon, 2 Nov 2020 21:56:07 -0600 Received: from a0393678-ssd.dal.design.ti.com (ileax41-snat.itg.ti.com [10.172.224.153]) by fllv0039.itg.ti.com (8.15.2/8.15.2) with ESMTP id 0A33tuqN101157; Mon, 2 Nov 2020 21:56:04 -0600 From: Kishon Vijay Abraham I To: Kishon Vijay Abraham I , Vinod Koul , Rob Herring , Philipp Zabel CC: Swapnil Kashinath Jakhade , Milind Parab , Yuti Suresh Amonkar , , Subject: [PATCH 2/9] phy: ti: j721e-wiz: Get PHY properties only for "phy" subnode Date: Tue, 3 Nov 2020 09:25:49 +0530 Message-ID: <20201103035556.21260-3-kishon@ti.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20201103035556.21260-1-kishon@ti.com> References: <20201103035556.21260-1-kishon@ti.com> MIME-Version: 1.0 Content-Type: text/plain X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org "serdes" node (child node of WIZ) can have sub-nodes for representing links or it can have sub-nodes for representing the various clocks within the serdes. Instead of trying to read "reg" from every child node used for assigning "lane_phy_type", read only if the child node's name is "phy". Signed-off-by: Kishon Vijay Abraham I --- drivers/phy/ti/phy-j721e-wiz.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/phy/ti/phy-j721e-wiz.c b/drivers/phy/ti/phy-j721e-wiz.c index c9cfafe89cbf..d57d29382ce4 100644 --- a/drivers/phy/ti/phy-j721e-wiz.c +++ b/drivers/phy/ti/phy-j721e-wiz.c @@ -787,6 +787,9 @@ static int wiz_get_lane_phy_types(struct device *dev, struct wiz *wiz) u32 reg, num_lanes = 1, phy_type = PHY_NONE; int ret, i; + if (!(of_node_name_eq(subnode, "phy"))) + continue; + ret = of_property_read_u32(subnode, "reg", ®); if (ret) { dev_err(dev, -- 2.17.1