| .. | .. |
|---|
| 776 | 776 | #ifdef CONFIG_PCI |
|---|
| 777 | 777 | static int vortex_ioctl(struct net_device *dev, struct ifreq *rq, int cmd); |
|---|
| 778 | 778 | #endif |
|---|
| 779 | | -static void vortex_tx_timeout(struct net_device *dev); |
|---|
| 779 | +static void vortex_tx_timeout(struct net_device *dev, unsigned int txqueue); |
|---|
| 780 | 780 | static void acpi_set_WOL(struct net_device *dev); |
|---|
| 781 | 781 | static const struct ethtool_ops vortex_ethtool_ops; |
|---|
| 782 | 782 | static void set_8021q_mode(struct net_device *dev, int enable); |
|---|
| .. | .. |
|---|
| 847 | 847 | |
|---|
| 848 | 848 | static int vortex_suspend(struct device *dev) |
|---|
| 849 | 849 | { |
|---|
| 850 | | - struct pci_dev *pdev = to_pci_dev(dev); |
|---|
| 851 | | - struct net_device *ndev = pci_get_drvdata(pdev); |
|---|
| 850 | + struct net_device *ndev = dev_get_drvdata(dev); |
|---|
| 852 | 851 | |
|---|
| 853 | 852 | if (!ndev || !netif_running(ndev)) |
|---|
| 854 | 853 | return 0; |
|---|
| .. | .. |
|---|
| 861 | 860 | |
|---|
| 862 | 861 | static int vortex_resume(struct device *dev) |
|---|
| 863 | 862 | { |
|---|
| 864 | | - struct pci_dev *pdev = to_pci_dev(dev); |
|---|
| 865 | | - struct net_device *ndev = pci_get_drvdata(pdev); |
|---|
| 863 | + struct net_device *ndev = dev_get_drvdata(dev); |
|---|
| 866 | 864 | int err; |
|---|
| 867 | 865 | |
|---|
| 868 | 866 | if (!ndev || !netif_running(ndev)) |
|---|
| .. | .. |
|---|
| 1151 | 1149 | |
|---|
| 1152 | 1150 | print_info = (vortex_debug > 1); |
|---|
| 1153 | 1151 | if (print_info) |
|---|
| 1154 | | - pr_info("See Documentation/networking/vortex.txt\n"); |
|---|
| 1152 | + pr_info("See Documentation/networking/device_drivers/ethernet/3com/vortex.rst\n"); |
|---|
| 1155 | 1153 | |
|---|
| 1156 | 1154 | pr_info("%s: 3Com %s %s at %p.\n", |
|---|
| 1157 | 1155 | print_name, |
|---|
| .. | .. |
|---|
| 1550 | 1548 | struct vortex_private *vp = netdev_priv(dev); |
|---|
| 1551 | 1549 | void __iomem *ioaddr = vp->ioaddr; |
|---|
| 1552 | 1550 | unsigned int config; |
|---|
| 1553 | | - int i, mii_reg1, mii_reg5, err = 0; |
|---|
| 1551 | + int i, mii_reg5, err = 0; |
|---|
| 1554 | 1552 | |
|---|
| 1555 | 1553 | if (VORTEX_PCI(vp)) { |
|---|
| 1556 | 1554 | pci_set_power_state(VORTEX_PCI(vp), PCI_D0); /* Go active */ |
|---|
| .. | .. |
|---|
| 1607 | 1605 | window_write32(vp, config, 3, Wn3_Config); |
|---|
| 1608 | 1606 | |
|---|
| 1609 | 1607 | if (dev->if_port == XCVR_MII || dev->if_port == XCVR_NWAY) { |
|---|
| 1610 | | - mii_reg1 = mdio_read(dev, vp->phys[0], MII_BMSR); |
|---|
| 1608 | + mdio_read(dev, vp->phys[0], MII_BMSR); |
|---|
| 1611 | 1609 | mii_reg5 = mdio_read(dev, vp->phys[0], MII_LPA); |
|---|
| 1612 | 1610 | vp->partner_flow_ctrl = ((mii_reg5 & 0x0400) != 0); |
|---|
| 1613 | 1611 | vp->mii.full_duplex = vp->full_duplex; |
|---|
| .. | .. |
|---|
| 1879 | 1877 | iowrite16(FakeIntr, ioaddr + EL3_CMD); |
|---|
| 1880 | 1878 | } |
|---|
| 1881 | 1879 | |
|---|
| 1882 | | -static void vortex_tx_timeout(struct net_device *dev) |
|---|
| 1880 | +static void vortex_tx_timeout(struct net_device *dev, unsigned int txqueue) |
|---|
| 1883 | 1881 | { |
|---|
| 1884 | 1882 | struct vortex_private *vp = netdev_priv(dev); |
|---|
| 1885 | 1883 | void __iomem *ioaddr = vp->ioaddr; |
|---|
| .. | .. |
|---|
| 1956 | 1954 | dev->name, tx_status); |
|---|
| 1957 | 1955 | if (tx_status == 0x82) { |
|---|
| 1958 | 1956 | pr_err("Probably a duplex mismatch. See " |
|---|
| 1959 | | - "Documentation/networking/vortex.txt\n"); |
|---|
| 1957 | + "Documentation/networking/device_drivers/ethernet/3com/vortex.rst\n"); |
|---|
| 1960 | 1958 | } |
|---|
| 1961 | 1959 | dump_tx_ring(dev); |
|---|
| 1962 | 1960 | } |
|---|
| .. | .. |
|---|
| 2175 | 2173 | |
|---|
| 2176 | 2174 | dma_addr = skb_frag_dma_map(vp->gendev, frag, |
|---|
| 2177 | 2175 | 0, |
|---|
| 2178 | | - frag->size, |
|---|
| 2176 | + skb_frag_size(frag), |
|---|
| 2179 | 2177 | DMA_TO_DEVICE); |
|---|
| 2180 | 2178 | if (dma_mapping_error(vp->gendev, dma_addr)) { |
|---|
| 2181 | 2179 | for(i = i-1; i >= 0; i--) |
|---|
| .. | .. |
|---|
| 2307 | 2305 | dma_unmap_single(vp->gendev, vp->tx_skb_dma, (vp->tx_skb->len + 3) & ~3, DMA_TO_DEVICE); |
|---|
| 2308 | 2306 | pkts_compl++; |
|---|
| 2309 | 2307 | bytes_compl += vp->tx_skb->len; |
|---|
| 2310 | | - dev_kfree_skb_irq(vp->tx_skb); /* Release the transferred buffer */ |
|---|
| 2308 | + dev_consume_skb_irq(vp->tx_skb); /* Release the transferred buffer */ |
|---|
| 2311 | 2309 | if (ioread16(ioaddr + TxFree) > 1536) { |
|---|
| 2312 | 2310 | /* |
|---|
| 2313 | 2311 | * AKPM: FIXME: I don't think we need this. If the queue was stopped due to |
|---|
| .. | .. |
|---|
| 2449 | 2447 | #endif |
|---|
| 2450 | 2448 | pkts_compl++; |
|---|
| 2451 | 2449 | bytes_compl += skb->len; |
|---|
| 2452 | | - dev_kfree_skb_irq(skb); |
|---|
| 2450 | + dev_consume_skb_irq(skb); |
|---|
| 2453 | 2451 | vp->tx_skbuff[entry] = NULL; |
|---|
| 2454 | 2452 | } else { |
|---|
| 2455 | 2453 | pr_debug("boomerang_interrupt: no skb!\n"); |
|---|