Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp3370007pxj; Tue, 1 Jun 2021 03:51:09 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyiHr0q2VTF7QSfobOFXPuIT+Rg07t14Z/XJFEscS7G00RC0rDziO0w8MoBV47ArR0kZjF0 X-Received: by 2002:a17:907:1117:: with SMTP id qu23mr20260775ejb.71.1622544669422; Tue, 01 Jun 2021 03:51:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622544669; cv=none; d=google.com; s=arc-20160816; b=Gm9ZyqnrqYodGXG803Yi/t8eKJpHUH6Lu+g5N607pgDhqixpfExlTQQh5sm2Gsi2t9 BJkAF2a6Dyr6xi+0d5MhQQdzRtmoQiwMR5QQPQV1Eii24fUND5npqMKxox0hiiFyC6Ma v7j3kdBgHVoVSdFi3gardqBwc+6jZvvET8hoH5ES6O93FU/BXPFPeC6rMssdnhxghNtX 19QvEmkEjFsWee5HY/JAOfhvB8lc1uTxL5U3e7FtMp2DzHJjMCR3WOWqDTpdZYLfpk/7 RedC0opKadNp7ZB7ASoKgvfgv+GQfmH23QB1cHx40mJJ5gWOONH0NhPwOxa+2p5kAcU2 Wj6A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :ironport-sdr:ironport-sdr; bh=FXanfIYUC2h7BHMy22QM3DJGaDMyM9XqsPNOpgg9TyU=; b=a4udwYbsz6trdPPriKTkZ8n4U9eGvxSD7NVtTx+XR3ScyuDWZ+afJn0t+Fk2CpY6XV esCbNV8cWr452Owt8v5rQ0fusP7QjOv2rkTMnS5TCl5odHGfesOMZ4VOMuDcGap5RkcX 1jBh9ABc0lb4kGKjUy6BcOGb9zCa64S8UHzB+Q+A8M8dXFJ2tCLTwXzQe+9SxM9lIjKg EE+bLAK/DSSBA/HndmrMygBPFlgpCO/c4VBmN1q7EaLL87j/NnpEDFDeyBKbF8G1pKK4 06uL7fhJM18Gt4v4gzBItDoVQVf+khzU8bVYwLmAdaYjQtsugJlrodnLztsnEAESpXxm CWig== 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 q11si14055565edd.19.2021.06.01.03.50.45; Tue, 01 Jun 2021 03:51:09 -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 S233557AbhFAKtW (ORCPT + 99 others); Tue, 1 Jun 2021 06:49:22 -0400 Received: from mga06.intel.com ([134.134.136.31]:16965 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230282AbhFAKtV (ORCPT ); Tue, 1 Jun 2021 06:49:21 -0400 IronPort-SDR: +871oqcBKBUXNQaxC01aDNGFR6KYAsegNUpwo+Ww4MatVUDSBMQ1hA6mmsyvwfzzHaQjZJjFDq l/TD9t3srhNQ== X-IronPort-AV: E=McAfee;i="6200,9189,10001"; a="264704884" X-IronPort-AV: E=Sophos;i="5.83,239,1616482800"; d="scan'208";a="264704884" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 01 Jun 2021 03:47:39 -0700 IronPort-SDR: 4dz5RWE3XnQmA2D6YORw1o99YC7CHNzPDp/4/z3HvfNreZaDZNh+ASlL+6LhcBfk2sJXLGXbHE wazFijaQATsQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.83,239,1616482800"; d="scan'208";a="445285860" Received: from linux.intel.com ([10.54.29.200]) by orsmga008.jf.intel.com with ESMTP; 01 Jun 2021 03:47:39 -0700 Received: from linux.intel.com (unknown [10.88.229.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by linux.intel.com (Postfix) with ESMTPS id A2F245807FC; Tue, 1 Jun 2021 03:47:37 -0700 (PDT) Date: Tue, 1 Jun 2021 18:47:34 +0800 From: Wong Vee Khee To: Andrew Lunn Cc: Heiner Kallweit , Russell King , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [RFC net-next 0/2] Introduce MDIO probe order C45 over C22 Message-ID: <20210601104734.GA18984@linux.intel.com> References: <20210525055803.22116-1-vee.khee.wong@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.4 (2018-02-28) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, May 25, 2021 at 03:34:34PM +0200, Andrew Lunn wrote: > On Tue, May 25, 2021 at 01:58:03PM +0800, Wong Vee Khee wrote: > > 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] > > Is it possible to identify it is a Marvell PHY? Do any of the other > C22 registers return anything unique? I'm wondering if adding > .match_phy_device to genphy would work to identify it is a Marvell PHY > and not bind to it. Or we can turn it around, make the > .match_phy_device specifically look for the fixed-link device by > putting a magic number in one of the vendor registers. > I checked the Marvell and did not see any unique register values. Also, since get_phy_c22_id() returns a *phy_id== 0, it is not bind to any PHY driver, so I don't think adding the match_phy_device check in getphy would help. VK