Skip to content

Commit

Permalink
ethoc: Fix warning in ethoc_init_ring().
Browse files Browse the repository at this point in the history
Get rid of the pointless back-and-forth casting of dev->mem_start
from long to pointer back to long again.

Also fixes a warning reported by Stephen Rothwell:

drivers/net/ethoc.c: In function 'ethoc_init_ring':
drivers/net/ethoc.c:302: warning: assignment makes integer from pointer without a cast

Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
David S. Miller committed Jul 8, 2010
1 parent a038716 commit 5cf3e03
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/net/ethoc.c
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ static inline void ethoc_disable_rx_and_tx(struct ethoc *dev)
ethoc_write(dev, MODER, mode);
}

static int ethoc_init_ring(struct ethoc *dev, void* mem_start)
static int ethoc_init_ring(struct ethoc *dev, unsigned long mem_start)
{
struct ethoc_bd bd;
int i;
Expand Down Expand Up @@ -670,7 +670,7 @@ static int ethoc_open(struct net_device *dev)
if (ret)
return ret;

ethoc_init_ring(priv, (void*)dev->mem_start);
ethoc_init_ring(priv, dev->mem_start);
ethoc_reset(priv);

if (netif_queue_stopped(dev)) {
Expand Down

0 comments on commit 5cf3e03

Please sign in to comment.