aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/marvell/pxa168_eth.c
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2013-03-14 09:07:21 -0400
committerDavid S. Miller <davem@davemloft.net>2013-03-15 08:56:58 -0400
commitd0320f750093d012d3ed69fc1e8b385f654523d5 (patch)
tree1f9c25c892c33275fb85a993e9a274dc5618370b /drivers/net/ethernet/marvell/pxa168_eth.c
parent68c45a2da34cb44962c6a48f8e474ec6b7853641 (diff)
drivers:net: Remove dma_alloc_coherent OOM messages
I believe these error messages are already logged on allocation failure by warn_alloc_failed and so get a dump_stack on OOM. Remove the unnecessary additional error logging. Around these deletions: o Alignment neatening. o Remove unnecessary casts of dma_alloc_coherent. o Hoist assigns from ifs. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/marvell/pxa168_eth.c')
-rw-r--r--drivers/net/ethernet/marvell/pxa168_eth.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/drivers/net/ethernet/marvell/pxa168_eth.c b/drivers/net/ethernet/marvell/pxa168_eth.c
index 037ed866c22f..3ae4c7f0834d 100644
--- a/drivers/net/ethernet/marvell/pxa168_eth.c
+++ b/drivers/net/ethernet/marvell/pxa168_eth.c
@@ -1024,11 +1024,9 @@ static int rxq_init(struct net_device *dev)
1024 pep->rx_desc_area_size = size; 1024 pep->rx_desc_area_size = size;
1025 pep->p_rx_desc_area = dma_alloc_coherent(pep->dev->dev.parent, size, 1025 pep->p_rx_desc_area = dma_alloc_coherent(pep->dev->dev.parent, size,
1026 &pep->rx_desc_dma, GFP_KERNEL); 1026 &pep->rx_desc_dma, GFP_KERNEL);
1027 if (!pep->p_rx_desc_area) { 1027 if (!pep->p_rx_desc_area)
1028 printk(KERN_ERR "%s: Cannot alloc RX ring (size %d bytes)\n",
1029 dev->name, size);
1030 goto out; 1028 goto out;
1031 } 1029
1032 memset((void *)pep->p_rx_desc_area, 0, size); 1030 memset((void *)pep->p_rx_desc_area, 0, size);
1033 /* initialize the next_desc_ptr links in the Rx descriptors ring */ 1031 /* initialize the next_desc_ptr links in the Rx descriptors ring */
1034 p_rx_desc = pep->p_rx_desc_area; 1032 p_rx_desc = pep->p_rx_desc_area;
@@ -1087,11 +1085,8 @@ static int txq_init(struct net_device *dev)
1087 pep->tx_desc_area_size = size; 1085 pep->tx_desc_area_size = size;
1088 pep->p_tx_desc_area = dma_alloc_coherent(pep->dev->dev.parent, size, 1086 pep->p_tx_desc_area = dma_alloc_coherent(pep->dev->dev.parent, size,
1089 &pep->tx_desc_dma, GFP_KERNEL); 1087 &pep->tx_desc_dma, GFP_KERNEL);
1090 if (!pep->p_tx_desc_area) { 1088 if (!pep->p_tx_desc_area)
1091 printk(KERN_ERR "%s: Cannot allocate Tx Ring (size %d bytes)\n",
1092 dev->name, size);
1093 goto out; 1089 goto out;
1094 }
1095 memset((void *)pep->p_tx_desc_area, 0, pep->tx_desc_area_size); 1090 memset((void *)pep->p_tx_desc_area, 0, pep->tx_desc_area_size);
1096 /* Initialize the next_desc_ptr links in the Tx descriptors ring */ 1091 /* Initialize the next_desc_ptr links in the Tx descriptors ring */
1097 p_tx_desc = pep->p_tx_desc_area; 1092 p_tx_desc = pep->p_tx_desc_area;