lkml.org 
[lkml]   [2013]   [Mar]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] ixp4xx_eth: set the device dma_coherent_mask
Date
Without the mask it is impossible to take the network interface up
since it returns the following error:

> net eth1: coherent DMA mask is unset
> ifconfig: SIOCSIFFLAGS: Cannot allocate memory

Tested on an out-of-tree ixp425 based board.

Signed-off-by: Christophe Aeschlimann <c.aeschlimann@acn-group.ch>
---
drivers/net/ethernet/xscale/ixp4xx_eth.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/net/ethernet/xscale/ixp4xx_eth.c b/drivers/net/ethernet/xscale/ixp4xx_eth.c
index 6958a5e..ff23c5c 100644
--- a/drivers/net/ethernet/xscale/ixp4xx_eth.c
+++ b/drivers/net/ethernet/xscale/ixp4xx_eth.c
@@ -1398,6 +1398,7 @@ static int eth_init_one(struct platform_device *pdev)
return -ENOMEM;

SET_NETDEV_DEV(dev, &pdev->dev);
+ dev->dev.coherent_dma_mask = DMA_BIT_MASK(32);
port = netdev_priv(dev);
port->netdev = dev;
port->id = pdev->id;
--
1.7.9


\
 
 \ /
  Last update: 2013-03-19 18:01    [W:0.040 / U:0.156 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site