Lines Matching defs:ndev

2064 	struct net_device *ndev = platform_get_drvdata(pdev);
2065 struct smc_local *lp = netdev_priv(ndev);
2126 struct net_device *ndev)
2129 struct smc_local *lp __maybe_unused = netdev_priv(ndev);
2141 struct net_device *ndev)
2144 struct smc_local *lp __maybe_unused = netdev_priv(ndev);
2150 static inline void smc_request_datacs(struct platform_device *pdev, struct net_device *ndev)
2154 struct smc_local *lp = netdev_priv(ndev);
2160 netdev_info(ndev, "%s: failed to request datacs memory region.\n",
2169 static void smc_release_datacs(struct platform_device *pdev, struct net_device *ndev)
2172 struct smc_local *lp = netdev_priv(ndev);
2245 struct net_device *ndev;
2252 ndev = alloc_etherdev(sizeof(struct smc_local));
2253 if (!ndev) {
2257 SET_NETDEV_DEV(ndev, &pdev->dev);
2263 lp = netdev_priv(ndev);
2325 ndev->dma = (unsigned char)-1;
2341 ndev->irq = platform_get_irq(pdev, 0);
2342 if (ndev->irq <= 0) {
2351 irq_resflags = irqd_get_trigger_type(irq_get_irq_data(ndev->irq));
2355 ret = smc_request_attrib(pdev, ndev);
2361 platform_set_drvdata(pdev, ndev);
2374 struct smc_local *lp = netdev_priv(ndev);
2380 ret = smc_probe(ndev, addr, irq_flags);
2384 smc_request_datacs(pdev, ndev);
2391 smc_release_attrib(pdev, ndev);
2395 free_netdev(ndev);
2404 struct net_device *ndev = platform_get_drvdata(pdev);
2405 struct smc_local *lp = netdev_priv(ndev);
2408 unregister_netdev(ndev);
2410 free_irq(ndev->irq, ndev);
2413 if (ndev->dma != (unsigned char)-1)
2414 pxa_free_dma(ndev->dma);
2418 smc_release_datacs(pdev,ndev);
2419 smc_release_attrib(pdev,ndev);
2426 free_netdev(ndev);
2434 struct net_device *ndev = platform_get_drvdata(pdev);
2436 if (ndev) {
2437 if (netif_running(ndev)) {
2438 netif_device_detach(ndev);
2439 smc_shutdown(ndev);
2440 smc_phy_powerdown(ndev);
2449 struct net_device *ndev = platform_get_drvdata(pdev);
2451 if (ndev) {
2452 struct smc_local *lp = netdev_priv(ndev);
2454 if (netif_running(ndev)) {
2455 smc_reset(ndev);
2456 smc_enable(ndev);
2459 netif_device_attach(ndev);