Re: [net-next,v2] net: ethernet: rtsn: Add support for Renesas Ethernet-TSN

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2024-05-08 02:55:44 +0200, Andrew Lunn wrote:
> > +static int rtsn_probe(struct platform_device *pdev)
> > +{
> 
> 
> > +	pm_runtime_enable(&pdev->dev);
> > +	pm_runtime_get_sync(&pdev->dev);
> 
> 
> > +static int rtsn_remove(struct platform_device *pdev)
> > +{
> > +	struct rtsn_private *priv = platform_get_drvdata(pdev);
> > +
> > +	unregister_netdev(priv->ndev);
> > +	rtsn_mdio_free(priv);
> > +	rcar_gen4_ptp_unregister(priv->ptp_priv);
> > +	rtsn_change_mode(priv, OCR_OPC_DISABLE);
> > +	netif_napi_del(&priv->napi);
> > +
> > +	pm_runtime_put_sync(&pdev->dev);
> > +	pm_runtime_disable(&pdev->dev);
> 
> These appear to be the only two places you do any pm_ stuff. So it
> seems pointless. Maybe delete this for the moment, and come back later
> to add proper runtime power management?

I agree enable more PM stuff is a good candidate to follow initial 
entablement. But these pm_ calls are not pointless, I still need to deal 
with power. If I remove the pm_ calls things starts to fail. Maybe I can 
substitute the pm_ calls with something else, but I rather keep the pm_ 
stuff as adding suspend/resume support is high on the list of things to 
do. And reworking this now just to restore it later seems pointless as 
more PM is the way forward.

> 
>        Andrew

-- 
Kind Regards,
Niklas Söderlund




[Index of Archives]     [Linux Samsung SOC]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux