From: Dimitri Fedrau <dima.fedrau@gmail.com>
To: Andrew Lunn <andrew@lunn.ch>
Cc: Stefan Eichenberger <eichest@gmail.com>,
Heiner Kallweit <hkallweit1@gmail.com>,
Russell King <linux@armlinux.org.uk>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 4/4] net: phy: marvell-88q2xxx: add driver for the Marvell 88Q2220 PHY
Date: Thu, 21 Dec 2023 15:45:42 +0100 [thread overview]
Message-ID: <20231221144542.GA122328@debian> (raw)
In-Reply-To: <59fed161-6c08-4537-b02d-19e67e342dd8@lunn.ch>
Am Thu, Dec 21, 2023 at 03:25:56PM +0100 schrieb Andrew Lunn:
> > Without setting the master-slave option it didn't work. I think its
> > mandatory.
>
> I don't think it is. The PHY should have a default setting for
> master-slave. Often its based on the typical use case. If its
> typically inside a switch, then it should default to prefer-master. If
> its typically in an end system, then it should be prefer-slave.
>
That would be the case if you use a forced configuration. I think this
is already implemented by reading out the MDIO_PMA_PMD_BT1_CTRL in
genphy_c45_pma_baset1_read_master_slave. Probably the problem arises
with following lines which prevents an inital read of the configuration:
static int mv88q2xxx_config_init(struct phy_device *phydev)
{
int ret;
/* The 88Q2XXX PHYs do have the extended ability register available, but
* register MDIO_PMA_EXTABLE where they should signalize it does not
* work according to specification. Therefore, we force it here.
*/
phydev->pma_extable = MDIO_PMA_EXTABLE_BT1;
if (phydev->drv->phy_id == MARVELL_PHY_ID_88Q2220)
return 0;
/* Read the current PHY configuration */
ret = genphy_c45_read_pma(phydev);
if (ret)
return ret;
return mv88q2xxx_config_aneg(phydev);
}
If I type in "ethtool -s eth0 autoneg on" I don't have to set the
master-slave option. Is the assumption here that we always start with a
forced configuration ? If yes, then I have to fix it.
> Andrew
Dimitri
next prev parent reply other threads:[~2023-12-21 14:45 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-15 21:31 [PATCH] net: phy: marvell-88q2xxx: add driver for the Marvell 88Q2220 PHY Dimitri Fedrau
2023-12-16 16:46 ` Andrew Lunn
2023-12-16 22:11 ` Dimitri Fedrau
2023-12-17 9:22 ` Andrew Lunn
2023-12-17 11:15 ` Dimitri Fedrau
2023-12-17 13:50 ` Stefan Eichenberger
2023-12-18 9:09 ` Dimitri Fedrau
2023-12-18 11:19 ` Stefan Eichenberger
2023-12-19 8:11 ` Dimitri Fedrau
2023-12-19 9:19 ` Stefan Eichenberger
2023-12-19 9:35 ` Dimitri Fedrau
2023-12-21 7:28 ` [PATCH v3 0/4] " Dimitri Fedrau
2023-12-21 7:28 ` [PATCH v3 1/4] net: phy: Add BaseT1 auto-negotiation constants Dimitri Fedrau
2023-12-21 9:45 ` Andrew Lunn
2023-12-21 7:28 ` [PATCH v3 2/4] net: phy: Support 100/1000BT1 linkmode advertisements Dimitri Fedrau
2023-12-21 9:45 ` Andrew Lunn
2023-12-21 7:28 ` [PATCH v3 3/4] net: phy: c45: detect 100/1000BASE-T1 " Dimitri Fedrau
2023-12-21 9:46 ` Andrew Lunn
2023-12-21 7:28 ` [PATCH v3 4/4] net: phy: marvell-88q2xxx: add driver for the Marvell 88Q2220 PHY Dimitri Fedrau
2023-12-21 9:53 ` Andrew Lunn
2023-12-21 11:40 ` Dimitri Fedrau
2023-12-21 13:47 ` Stefan Eichenberger
2023-12-21 14:16 ` Dimitri Fedrau
2023-12-21 14:25 ` Andrew Lunn
2023-12-21 14:45 ` Dimitri Fedrau [this message]
2024-01-02 11:36 ` Russell King (Oracle)
2023-12-21 9:44 ` [PATCH v3 0/4] " Andrew Lunn
2023-12-21 11:45 ` Dimitri Fedrau
2023-12-19 15:57 ` [PATCH] " Andrew Lunn
2024-01-05 12:42 ` Dimitri Fedrau
2024-01-05 14:00 ` Andrew Lunn
2024-01-05 15:43 ` Dimitri Fedrau
2024-01-05 16:06 ` Andrew Lunn
2024-01-05 22:20 ` Dimitri Fedrau
2023-12-16 22:41 ` [PATCH v2] " Dimitri Fedrau
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20231221144542.GA122328@debian \
--to=dima.fedrau@gmail.com \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=eichest@gmail.com \
--cc=hkallweit1@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.