Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 139820
b: refs/heads/master
c: da1aa63
h: refs/heads/master
v: v3
  • Loading branch information
Anton Vorontsov authored and David S. Miller committed Apr 2, 2009
1 parent f0db146 commit d40c750
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 12 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 050cc1f568e896a615110109999ed60ef75edf93
refs/heads/master: da1aa63ec3b4e9b4c5680f06288f57f44caa61b8
21 changes: 11 additions & 10 deletions trunk/drivers/net/ucc_geth.c
Original file line number Diff line number Diff line change
Expand Up @@ -222,10 +222,10 @@ static struct sk_buff *get_new_skb(struct ucc_geth_private *ugeth,
(((unsigned)skb->data) & (UCC_GETH_RX_DATA_BUF_ALIGNMENT -
1)));

skb->dev = ugeth->dev;
skb->dev = ugeth->ndev;

out_be32(&((struct qe_bd __iomem *)bd)->buf,
dma_map_single(&ugeth->dev->dev,
dma_map_single(ugeth->dev,
skb->data,
ugeth->ug_info->uf_info.max_rx_buf_length +
UCC_GETH_RX_DATA_BUF_ALIGNMENT,
Expand Down Expand Up @@ -1871,7 +1871,7 @@ static void ucc_geth_memclean(struct ucc_geth_private *ugeth)
continue;
for (j = 0; j < ugeth->ug_info->bdRingLenTx[i]; j++) {
if (ugeth->tx_skbuff[i][j]) {
dma_unmap_single(&ugeth->dev->dev,
dma_unmap_single(ugeth->dev,
in_be32(&((struct qe_bd __iomem *)bd)->buf),
(in_be32((u32 __iomem *)bd) &
BD_LENGTH_MASK),
Expand Down Expand Up @@ -1899,7 +1899,7 @@ static void ucc_geth_memclean(struct ucc_geth_private *ugeth)
bd = ugeth->p_rx_bd_ring[i];
for (j = 0; j < ugeth->ug_info->bdRingLenRx[i]; j++) {
if (ugeth->rx_skbuff[i][j]) {
dma_unmap_single(&ugeth->dev->dev,
dma_unmap_single(ugeth->dev,
in_be32(&((struct qe_bd __iomem *)bd)->buf),
ugeth->ug_info->
uf_info.max_rx_buf_length +
Expand Down Expand Up @@ -3070,7 +3070,7 @@ static int ucc_geth_start_xmit(struct sk_buff *skb, struct net_device *dev)

/* set up the buffer descriptor */
out_be32(&((struct qe_bd __iomem *)bd)->buf,
dma_map_single(&ugeth->dev->dev, skb->data,
dma_map_single(ugeth->dev, skb->data,
skb->len, DMA_TO_DEVICE));

/* printk(KERN_DEBUG"skb->data is 0x%x\n",skb->data); */
Expand Down Expand Up @@ -3126,7 +3126,7 @@ static int ucc_geth_rx(struct ucc_geth_private *ugeth, u8 rxQ, int rx_work_limit

ugeth_vdbg("%s: IN", __func__);

dev = ugeth->dev;
dev = ugeth->ndev;

/* collect received buffers */
bd = ugeth->rxBd[rxQ];
Expand Down Expand Up @@ -3160,7 +3160,7 @@ static int ucc_geth_rx(struct ucc_geth_private *ugeth, u8 rxQ, int rx_work_limit
skb_put(skb, length);

/* Tell the skb what kind of packet this is */
skb->protocol = eth_type_trans(skb, ugeth->dev);
skb->protocol = eth_type_trans(skb, ugeth->ndev);

dev->stats.rx_bytes += length;
/* Send the packet up the stack */
Expand Down Expand Up @@ -3431,7 +3431,7 @@ static int ucc_geth_close(struct net_device *dev)

ucc_geth_stop(ugeth);

free_irq(ugeth->ug_info->uf_info.irq, ugeth->dev);
free_irq(ugeth->ug_info->uf_info.irq, ugeth->ndev);

netif_stop_queue(dev);

Expand All @@ -3445,7 +3445,7 @@ static void ucc_geth_timeout_work(struct work_struct *work)
struct net_device *dev;

ugeth = container_of(work, struct ucc_geth_private, timeout_work);
dev = ugeth->dev;
dev = ugeth->ndev;

ugeth_vdbg("%s: IN", __func__);

Expand Down Expand Up @@ -3755,7 +3755,8 @@ static int ucc_geth_probe(struct of_device* ofdev, const struct of_device_id *ma
memcpy(dev->dev_addr, mac_addr, 6);

ugeth->ug_info = ug_info;
ugeth->dev = dev;
ugeth->dev = device;
ugeth->ndev = dev;
ugeth->node = np;

return 0;
Expand Down
3 changes: 2 additions & 1 deletion trunk/drivers/net/ucc_geth.h
Original file line number Diff line number Diff line change
Expand Up @@ -1128,7 +1128,8 @@ struct ucc_geth_info {
struct ucc_geth_private {
struct ucc_geth_info *ug_info;
struct ucc_fast_private *uccf;
struct net_device *dev;
struct device *dev;
struct net_device *ndev;
struct napi_struct napi;
struct work_struct timeout_work;
struct ucc_geth __iomem *ug_regs;
Expand Down

0 comments on commit d40c750

Please sign in to comment.