summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Carpenter <error27@gmail.com>2010-08-24 08:55:05 +0200
committerDavid S. Miller <davem@davemloft.net>2010-08-24 23:50:27 +0200
commitb2bc85631e72485b984bcd202a104591874babba (patch)
tree142155d21b8f1244ed7e69f07da517c12f62e798
parentpxa168_eth: update call to phy_mii_ioctl() (diff)
downloadlinux-b2bc85631e72485b984bcd202a104591874babba.tar.xz
linux-b2bc85631e72485b984bcd202a104591874babba.zip
pxa168_eth: silence gcc warnings
Casting "pep->tx_desc_dma" to to a struct tx_desc pointer makes gcc complain: drivers/net/pxa168_eth.c:657: warning: cast to pointer from integer of different size Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/pxa168_eth.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/pxa168_eth.c b/drivers/net/pxa168_eth.c
index f324b767f685..410ea0a61371 100644
--- a/drivers/net/pxa168_eth.c
+++ b/drivers/net/pxa168_eth.c
@@ -654,15 +654,15 @@ static void eth_port_start(struct net_device *dev)
/* Assignment of Tx CTRP of given queue */
tx_curr_desc = pep->tx_curr_desc_q;
wrl(pep, ETH_C_TX_DESC_1,
- (u32) ((struct tx_desc *)pep->tx_desc_dma + tx_curr_desc));
+ (u32) (pep->tx_desc_dma + tx_curr_desc * sizeof(struct tx_desc)));
/* Assignment of Rx CRDP of given queue */
rx_curr_desc = pep->rx_curr_desc_q;
wrl(pep, ETH_C_RX_DESC_0,
- (u32) ((struct rx_desc *)pep->rx_desc_dma + rx_curr_desc));
+ (u32) (pep->rx_desc_dma + rx_curr_desc * sizeof(struct rx_desc)));
wrl(pep, ETH_F_RX_DESC_0,
- (u32) ((struct rx_desc *)pep->rx_desc_dma + rx_curr_desc));
+ (u32) (pep->rx_desc_dma + rx_curr_desc * sizeof(struct rx_desc)));
/* Clear all interrupts */
wrl(pep, INT_CAUSE, 0);