aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wan/lapbether.c
diff options
context:
space:
mode:
authorPeng Li <[email protected]>2021-06-09 09:39:51 +0000
committerDavid S. Miller <[email protected]>2021-06-09 21:02:58 +0000
commitd5e686e8b66d513833e350ab776a8052b0f2ba9e (patch)
tree0da93760c0bdbb6ece68a2aece7ccc8549440876 /drivers/net/wan/lapbether.c
parentnet: lapbether: remove trailing whitespaces (diff)
downloadkernel-d5e686e8b66d513833e350ab776a8052b0f2ba9e.tar.gz
kernel-d5e686e8b66d513833e350ab776a8052b0f2ba9e.zip
net: lapbether: remove unnecessary out of memory message
This patch removes unnecessary out of memory message, to fix the following checkpatch.pl warning: "WARNING: Possible unnecessary 'out of memory' message" Signed-off-by: Peng Li <[email protected]> Signed-off-by: Guangbin Huang <[email protected]> Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'drivers/net/wan/lapbether.c')
-rw-r--r--drivers/net/wan/lapbether.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/drivers/net/wan/lapbether.c b/drivers/net/wan/lapbether.c
index 169b323733ac..705a8984e4d9 100644
--- a/drivers/net/wan/lapbether.c
+++ b/drivers/net/wan/lapbether.c
@@ -266,10 +266,8 @@ static void lapbeth_connected(struct net_device *dev, int reason)
unsigned char *ptr;
struct sk_buff *skb = __dev_alloc_skb(1, GFP_ATOMIC | __GFP_NOMEMALLOC);
- if (!skb) {
- pr_err("out of memory\n");
+ if (!skb)
return;
- }
ptr = skb_put(skb, 1);
*ptr = X25_IFACE_CONNECT;
@@ -286,10 +284,8 @@ static void lapbeth_disconnected(struct net_device *dev, int reason)
unsigned char *ptr;
struct sk_buff *skb = __dev_alloc_skb(1, GFP_ATOMIC | __GFP_NOMEMALLOC);
- if (!skb) {
- pr_err("out of memory\n");
+ if (!skb)
return;
- }
ptr = skb_put(skb, 1);
*ptr = X25_IFACE_DISCONNECT;