Lines Matching refs:dev
52 static void regdump(struct net_device *dev) in regdump() argument
55 int ioaddr = dev->base_addr; in regdump()
58 netdev_dbg(dev, "register dump:\n"); in regdump()
66 netdev_dbg(dev, "buffer0 dump:\n"); in regdump()
114 struct net_device *dev; in com20020_probe() local
118 dev_dbg(&p_dev->dev, "com20020_attach()\n"); in com20020_probe()
125 dev = alloc_arcdev(""); in com20020_probe()
126 if (!dev) in com20020_probe()
129 lp = netdev_priv(dev); in com20020_probe()
137 arcnet_set_addr(dev, node); in com20020_probe()
143 info->dev = dev; in com20020_probe()
153 free_arcdev(dev); in com20020_probe()
163 struct net_device *dev = info->dev; in com20020_detach() local
165 dev_dbg(&link->dev, "detach...\n"); in com20020_detach()
167 dev_dbg(&link->dev, "com20020_detach\n"); in com20020_detach()
169 dev_dbg(&link->dev, "unregister...\n"); in com20020_detach()
171 unregister_netdev(dev); in com20020_detach()
176 if (dev->irq) in com20020_detach()
177 free_irq(dev->irq, dev); in com20020_detach()
182 dev_dbg(&link->dev, "unlinking...\n"); in com20020_detach()
184 dev = info->dev; in com20020_detach()
185 if (dev) { in com20020_detach()
186 dev_dbg(&link->dev, "kfree...\n"); in com20020_detach()
187 free_arcdev(dev); in com20020_detach()
189 dev_dbg(&link->dev, "kfree2...\n"); in com20020_detach()
199 struct net_device *dev; in com20020_config() local
204 dev = info->dev; in com20020_config()
206 dev_dbg(&link->dev, "config...\n"); in com20020_config()
208 dev_dbg(&link->dev, "com20020_config\n"); in com20020_config()
210 dev_dbg(&link->dev, "baseport1 is %Xh\n", in com20020_config()
228 dev_dbg(&link->dev, "requestIO failed totally!\n"); in com20020_config()
232 ioaddr = dev->base_addr = link->resource[0]->start; in com20020_config()
233 dev_dbg(&link->dev, "got ioaddr %Xh\n", ioaddr); in com20020_config()
235 dev_dbg(&link->dev, "request IRQ %d\n", in com20020_config()
238 dev_dbg(&link->dev, "requestIRQ failed totally!\n"); in com20020_config()
242 dev->irq = link->irq; in com20020_config()
248 if (com20020_check(dev)) { in com20020_config()
249 regdump(dev); in com20020_config()
253 lp = netdev_priv(dev); in com20020_config()
257 SET_NETDEV_DEV(dev, &link->dev); in com20020_config()
259 i = com20020_found(dev, 0); /* calls register_netdev */ in com20020_config()
262 dev_notice(&link->dev, in com20020_config()
267 netdev_dbg(dev, "port %#3lx, irq %d\n", in com20020_config()
268 dev->base_addr, dev->irq); in com20020_config()
272 dev_dbg(&link->dev, "com20020_config failed...\n"); in com20020_config()
279 dev_dbg(&link->dev, "com20020_release\n"); in com20020_release()
286 struct net_device *dev = info->dev; in com20020_suspend() local
289 netif_device_detach(dev); in com20020_suspend()
297 struct net_device *dev = info->dev; in com20020_resume() local
300 int ioaddr = dev->base_addr; in com20020_resume()
301 struct arcnet_local *lp = netdev_priv(dev); in com20020_resume()