Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp4060999pxj; Mon, 24 May 2021 22:55:14 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxCF7djadJHvsyFM8uPwGnJrA0MMzITB9kb5dQazzQc4+ZkTM4yFI1tJHwyql12k7rojtke X-Received: by 2002:a17:906:1311:: with SMTP id w17mr28172449ejb.182.1621922113988; Mon, 24 May 2021 22:55:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621922113; cv=none; d=google.com; s=arc-20160816; b=K5NzCaz861RpvL+yaHeO21Qyvi4NFPmrLBeTlryWZCi5CgjU0Af0amn/xJPIQllxud XYHHb6kREmiFE9ffVuswDA/cgEvD2tkIBRycRmbIUEygdqsjhDAFL90tf+qt1jzJPaYL YCUJjqCUko/3rpzndMGLPVZuNuTPOCfa3EI5oUlTW/rON+0F3+XyycKRD622refseNJ2 HzLpn7VZK2IpZFSMQpupXq5svaBFpEiQR9XX3GcgP/sIDwc9bgwSNNtHz5t4opz2WprM qLtExft88K2AherXyb4JV/dtRt14KW6oX8NmqP+7lOirlJ4gwSaWhk1IYqDy0LUywFI/ 7bxQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:ironport-sdr:ironport-sdr; bh=mK2Vfaqof5bq99LXPtVclJtv0kDyxe4SHfcO2YNC56s=; b=u3RvhscEkz7K0bwrE2WtxOv5rZZu73bWj+xSrLxyLDJusVdY/bXNKJYyYtTOtCK3R6 JAtkbUAhMGpdIgBuPTsilL2L0D+Nn1GXuOSDBQ6O8Lv99vMN46Ufv/RWHlHwB7gjKCFG OURrFRuKWL+D8E/ZpdGZx45EUEybu+e5pSh7dcpzuTybcxdbVTMAfXsY8HCQp4SAH5cv 6SEGFQ5L+SD+6TN4/cIsUFJZ5zDbnrhFFn1OLG9WD9z2cncNiRVDbes38Tzt1945x22G MzqOywogpRxMPCITRau51bd+ir8v1EkTrxJ8EigR/3SkEuCPubhw2hvweQ1+WlT/r1Va IbRw== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id rl19si14160602ejb.50.2021.05.24.22.54.50; Mon, 24 May 2021 22:55:13 -0700 (PDT) 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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229612AbhEYFy3 (ORCPT + 99 others); Tue, 25 May 2021 01:54:29 -0400 Received: from mga14.intel.com ([192.55.52.115]:6192 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230218AbhEYFy2 (ORCPT ); Tue, 25 May 2021 01:54:28 -0400 IronPort-SDR: mk8xeAO3w08ihiIf/P9orMz9H8wfrn5tlnOF0XnL3TsWUCrAH/hyRRdFcumHL2p1IEmgPlgS+u VM6ua0/CCPoA== X-IronPort-AV: E=McAfee;i="6200,9189,9994"; a="201859993" X-IronPort-AV: E=Sophos;i="5.82,327,1613462400"; d="scan'208";a="201859993" Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 May 2021 22:52:58 -0700 IronPort-SDR: dZ5C0inDdbv+mXAVzHPrvk6zdDzAaviFQY2bh4fRteUlvryOhRU6dLhTjBxhBWOIgZQB0B62z+ QSHX3PwOWTkQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.82,327,1613462400"; d="scan'208";a="546369985" Received: from linux.intel.com ([10.54.29.200]) by fmsmga001.fm.intel.com with ESMTP; 24 May 2021 22:52:58 -0700 Received: from glass.png.intel.com (glass.png.intel.com [10.158.65.59]) by linux.intel.com (Postfix) with ESMTP id 44EE4580911; Mon, 24 May 2021 22:52:57 -0700 (PDT) From: Wong Vee Khee To: Andrew Lunn , Heiner Kallweit , Russell King Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [RFC net-next 0/2] Introduce MDIO probe order C45 over C22 Date: Tue, 25 May 2021 13:58:03 +0800 Message-Id: <20210525055803.22116-1-vee.khee.wong@linux.intel.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Synopsys MAC controller is capable of pairing with external PHY devices that accessible via Clause-22 and Clause-45. There is a problem when it is paired with Marvell 88E2110 which returns PHY ID of 0 using get_phy_c22_id(). We can add this check in that function, but this will break swphy, as swphy_reg_reg() return 0. [1] Hence, we introduce MDIOBUS_CAP_C45_C22 which allow us to probe using Clause-45, if it fails, we then proceed to try with Clause-22. [1]: https://lkml.org/lkml/2021/3/18/584 Wong Vee Khee (2): net: phy: allow mdio bus to probe for c45 devices before c22 net: stmmac: allow gmac4 to probe for c45 devices before c22 drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c | 2 +- include/linux/phy.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) -- 2.25.1