aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2012-01-29 12:56:23 +0000
committerDavid S. Miller <davem@davemloft.net>2012-01-31 16:20:21 -0500
commite404decb0fb017be80552adee894b35307b6c7b4 (patch)
tree19b2324328eb1f8cef599f9f164dc9ca6e5699c9 /drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
parenttcp: md5: use sock_kmalloc() to limit md5 keys (diff)
downloadlinux-dev-e404decb0fb017be80552adee894b35307b6c7b4.tar.xz
linux-dev-e404decb0fb017be80552adee894b35307b6c7b4.zip
drivers/net: Remove unnecessary k.alloc/v.alloc OOM messages
alloc failures use dump_stack so emitting an additional out-of-memory message is an unnecessary duplication. Remove the allocation failure messages. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/stmicro/stmmac/stmmac_main.c')
-rw-r--r--drivers/net/ethernet/stmicro/stmmac/stmmac_main.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
index 96fa2da30763..ffc7581879b1 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
@@ -954,10 +954,9 @@ static int stmmac_open(struct net_device *dev)
#ifdef CONFIG_STMMAC_TIMER
priv->tm = kzalloc(sizeof(struct stmmac_timer *), GFP_KERNEL);
- if (unlikely(priv->tm == NULL)) {
- pr_err("%s: ERROR: timer memory alloc failed\n", __func__);
+ if (unlikely(priv->tm == NULL))
return -ENOMEM;
- }
+
priv->tm->freq = tmrate;
/* Test if the external timer can be actually used.