}
#ifdef CONFIG_DEBUG_FS
- ret = stmmac_init_fs(dev);
- if (ret < 0)
- pr_warn("%s: failed debugFS registration\n", __func__);
+ if (init_ptp) {
+ ret = stmmac_init_fs(dev);
+ if (ret < 0)
+ pr_warn("%s: failed debugFS registration\n", __func__);
+ }
#endif
/* Start the ball rolling... */
pr_debug("%s: DMA RX/TX processes started...\n", dev->name);
if (priv->phydev)
phy_stop(priv->phydev);
- spin_lock_irqsave(&priv->lock, flags);
-
netif_device_detach(ndev);
netif_stop_queue(ndev);
napi_disable(&priv->napi);
+ spin_lock_irqsave(&priv->lock, flags);
+
/* Stop TX/RX DMA */
priv->hw->dma->stop_tx(priv->ioaddr);
priv->hw->dma->stop_rx(priv->ioaddr);