aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wan/ixp4xx_hss.c
diff options
context:
space:
mode:
authorXi Wang <xi.wang@gmail.com>2012-11-17 15:25:10 -0500
committerDavid S. Miller <davem@davemloft.net>2012-11-20 15:12:44 -0500
commit3e2f61cd7a4e7642dcac4371734426e572f10370 (patch)
treebffa38a47f0468e70f3bf53ae31a8edb761da6dc /drivers/net/wan/ixp4xx_hss.c
parent1a4901177574083c35fafc24c4d151c2a7c7647c (diff)
ixp4xx_hss: avoid calling dma_pool_create() with NULL dev
Use &port->netdev->dev instead of NULL since dma_pool_create() doesn't allow NULL dev. Signed-off-by: Xi Wang <xi.wang@gmail.com> Cc: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/wan/ixp4xx_hss.c')
-rw-r--r--drivers/net/wan/ixp4xx_hss.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/net/wan/ixp4xx_hss.c b/drivers/net/wan/ixp4xx_hss.c
index 3f575afd8cfc..e9a3da588e95 100644
--- a/drivers/net/wan/ixp4xx_hss.c
+++ b/drivers/net/wan/ixp4xx_hss.c
@@ -969,10 +969,12 @@ static int init_hdlc_queues(struct port *port)
969{ 969{
970 int i; 970 int i;
971 971
972 if (!ports_open) 972 if (!ports_open) {
973 if (!(dma_pool = dma_pool_create(DRV_NAME, NULL, 973 dma_pool = dma_pool_create(DRV_NAME, &port->netdev->dev,
974 POOL_ALLOC_SIZE, 32, 0))) 974 POOL_ALLOC_SIZE, 32, 0);
975 if (!dma_pool)
975 return -ENOMEM; 976 return -ENOMEM;
977 }
976 978
977 if (!(port->desc_tab = dma_pool_alloc(dma_pool, GFP_KERNEL, 979 if (!(port->desc_tab = dma_pool_alloc(dma_pool, GFP_KERNEL,
978 &port->desc_tab_phys))) 980 &port->desc_tab_phys)))