[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <e77b032a-42cf-43df-809a-24b36dbcb95d@intel.com>
Date: Fri, 16 Feb 2024 14:41:10 -0800
From: Jacob Keller <jacob.e.keller@...el.com>
To: Florian Fainelli <florian.fainelli@...adcom.com>, <netdev@...r.kernel.org>
CC: Doug Berger <opendmb@...il.com>, Broadcom internal kernel review list
<bcm-kernel-feedback-list@...adcom.com>, "David S. Miller"
<davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski
<kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>, Andrew Lunn
<andrew@...n.ch>, Heiner Kallweit <hkallweit1@...il.com>, Russell King
<linux@...linux.org.uk>, open list <linux-kernel@...r.kernel.org>, "Justin
Chen" <justin.chen@...adcom.com>
Subject: Re: [PATCH net-next 2/3] net: bcmgenet: Pass "main" clock down to the
MDIO driver
On 2/16/2024 10:42 AM, Florian Fainelli wrote:
> GENET has historically had to create a MDIO platform device for its
> controller and pass some auxiliary data to it, like a MDIO completion
> callback. Now we also pass the "main" clock to allow for the MDIO bus
> controller to manage that clock adequately around I/O accesses.
>
> Signed-off-by: Florian Fainelli <florian.fainelli@...adcom.com>
> ---
> drivers/net/ethernet/broadcom/genet/bcmmii.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/net/ethernet/broadcom/genet/bcmmii.c b/drivers/net/ethernet/broadcom/genet/bcmmii.c
> index cbbe004621bc..7a21950da77c 100644
> --- a/drivers/net/ethernet/broadcom/genet/bcmmii.c
> +++ b/drivers/net/ethernet/broadcom/genet/bcmmii.c
> @@ -476,6 +476,10 @@ static int bcmgenet_mii_register(struct bcmgenet_priv *priv)
> ppd.wait_func = bcmgenet_mii_wait;
> ppd.wait_func_data = priv;
> ppd.bus_name = "bcmgenet MII bus";
> + /* Pass a reference to our "main" clock which is used for MDIO
> + * transfers
> + */
> + ppd.clk = priv->clk;
>
> /* Unimac MDIO bus controller starts at UniMAC offset + MDIO_CMD
> * and is 2 * 32-bits word long, 8 bytes total.
Is this missing a modification of the header file to add the clk field
to struct unimac_mdio_pdata? I don't see that field in the
include/linux/platform_data/mdio-bcm-unimac.h header currently...
Oh. you included that in the first patch of the series. I see.
It feels like the series would be more natural of this was 1/3 instead
of 2/3, since the current 1/3 patch depends on this clk value being set, no?
The result of the series makes sense tho:
Reviewed-by: Jacob Keller <jacob.e.keller@...el.com>
Powered by blists - more mailing lists