diff options
author | Jiri Kosina <jkosina@suse.cz> | 2012-04-08 23:48:52 +0400 |
---|---|---|
committer | Jiri Kosina <jkosina@suse.cz> | 2012-04-08 23:48:52 +0400 |
commit | e75d660672ddd11704b7f0fdb8ff21968587b266 (patch) | |
tree | ccb9c107744c10b553c0373e450bee3971d16c00 /drivers/net/ethernet/toshiba/tc35815.c | |
parent | 61282f37927143e45b03153f3e7b48d6b702147a (diff) | |
parent | 0034102808e0dbbf3a2394b82b1bb40b5778de9e (diff) | |
download | linux-e75d660672ddd11704b7f0fdb8ff21968587b266.tar.xz |
Merge branch 'master' into for-next
Merge with latest Linus' tree, as I have incoming patches
that fix code that is newer than current HEAD of for-next.
Conflicts:
drivers/net/ethernet/realtek/r8169.c
Diffstat (limited to 'drivers/net/ethernet/toshiba/tc35815.c')
-rw-r--r-- | drivers/net/ethernet/toshiba/tc35815.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/net/ethernet/toshiba/tc35815.c b/drivers/net/ethernet/toshiba/tc35815.c index 71b785cd7563..651a70c55e6e 100644 --- a/drivers/net/ethernet/toshiba/tc35815.c +++ b/drivers/net/ethernet/toshiba/tc35815.c @@ -453,7 +453,7 @@ static struct sk_buff *alloc_rxbuf_skb(struct net_device *dev, dma_addr_t *dma_handle) { struct sk_buff *skb; - skb = dev_alloc_skb(RX_BUF_SIZE); + skb = netdev_alloc_skb(dev, RX_BUF_SIZE); if (!skb) return NULL; *dma_handle = pci_map_single(hwdev, skb->data, RX_BUF_SIZE, @@ -808,10 +808,9 @@ static int __devinit tc35815_init_one(struct pci_dev *pdev, /* dev zeroed in alloc_etherdev */ dev = alloc_etherdev(sizeof(*lp)); - if (dev == NULL) { - dev_err(&pdev->dev, "unable to alloc new ethernet\n"); + if (dev == NULL) return -ENOMEM; - } + SET_NETDEV_DEV(dev, &pdev->dev); lp = netdev_priv(dev); lp->dev = dev; @@ -850,7 +849,7 @@ static int __devinit tc35815_init_one(struct pci_dev *pdev, /* Retrieve the ethernet address. */ if (tc35815_init_dev_addr(dev)) { dev_warn(&pdev->dev, "not valid ether addr\n"); - random_ether_addr(dev->dev_addr); + eth_hw_addr_random(dev); } rc = register_netdev(dev); |