[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID:
<SEYPR06MB51344C50BA08B5204102BDA29D272@SEYPR06MB5134.apcprd06.prod.outlook.com>
Date: Mon, 18 Nov 2024 10:44:05 +0000
From: Jacky Chou <jacky_chou@...eedtech.com>
To: Philipp Zabel <p.zabel@...gutronix.de>, "andrew+netdev@...n.ch"
<andrew+netdev@...n.ch>, "davem@...emloft.net" <davem@...emloft.net>,
"edumazet@...gle.com" <edumazet@...gle.com>, "kuba@...nel.org"
<kuba@...nel.org>, "pabeni@...hat.com" <pabeni@...hat.com>, "robh@...nel.org"
<robh@...nel.org>, "krzk+dt@...nel.org" <krzk+dt@...nel.org>,
"conor+dt@...nel.org" <conor+dt@...nel.org>, "netdev@...r.kernel.org"
<netdev@...r.kernel.org>, "devicetree@...r.kernel.org"
<devicetree@...r.kernel.org>, "linux-kernel@...r.kernel.org"
<linux-kernel@...r.kernel.org>
Subject:
回覆: [net-next v2 3/7] net: ftgmac100: Add reset toggling for Aspeed SOCs
Hi Philipp
Thank you for your reply.
> > Toggle the SCU reset before hardware initialization.
> >
> > Signed-off-by: Jacky Chou <jacky_chou@...eedtech.com>
> > ---
> > drivers/net/ethernet/faraday/ftgmac100.c | 21 +++++++++++++++++++++
> > 1 file changed, 21 insertions(+)
> >
> > diff --git a/drivers/net/ethernet/faraday/ftgmac100.c
> b/drivers/net/ethernet/faraday/ftgmac100.c
> > index 17ec35e75a65..cae23b712a6d 100644
> > --- a/drivers/net/ethernet/faraday/ftgmac100.c
> > +++ b/drivers/net/ethernet/faraday/ftgmac100.c
> > @@ -9,6 +9,7 @@
> > #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
> >
> > #include <linux/clk.h>
> > +#include <linux/reset.h>
> > #include <linux/dma-mapping.h>
> > #include <linux/etherdevice.h>
> > #include <linux/ethtool.h>
> > @@ -98,6 +99,7 @@ struct ftgmac100 {
> > struct work_struct reset_task;
> > struct mii_bus *mii_bus;
> > struct clk *clk;
> > + struct reset_control *rst;
> >
> > /* AST2500/AST2600 RMII ref clock gate */
> > struct clk *rclk;
> > @@ -1969,10 +1971,29 @@ static int ftgmac100_probe(struct
> platform_device *pdev)
> > }
> >
> > if (priv->is_aspeed) {
> > + struct reset_control *rst;
> > +
> > err = ftgmac100_setup_clk(priv);
> > if (err)
> > goto err_phy_connect;
> >
> > + rst = devm_reset_control_get_optional(priv->dev, NULL);
>
> Please use devm_reset_control_get_optional_exclusive() directly.
Got it.
Thanks,
Jacky
Powered by blists - more mailing lists