diff options
author | Peng Li <lipeng321@huawei.com> | 2021-05-28 03:12:49 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2021-05-29 00:08:12 +0300 |
commit | 2744fa2dfdcd390c03056b50de8563da9d0f1660 (patch) | |
tree | 36c3e32fb57ee89a96529a1db44c158614cf5c67 /drivers/net/wan/hdlc_fr.c | |
parent | c9a2ca5d7e58860d56ce5e7b74f7621cebf819de (diff) | |
download | linux-2744fa2dfdcd390c03056b50de8563da9d0f1660.tar.xz |
net: hdlc_fr: 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 <lipeng321@huawei.com>
Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/wan/hdlc_fr.c')
-rw-r--r-- | drivers/net/wan/hdlc_fr.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/net/wan/hdlc_fr.c b/drivers/net/wan/hdlc_fr.c index de7fbdc77588..72250fe0a1df 100644 --- a/drivers/net/wan/hdlc_fr.c +++ b/drivers/net/wan/hdlc_fr.c @@ -474,10 +474,9 @@ static void fr_lmi_send(struct net_device *dev, int fullrep) } skb = dev_alloc_skb(len); - if (!skb) { - netdev_warn(dev, "Memory squeeze on fr_lmi_send()\n"); + if (!skb) return; - } + memset(skb->data, 0, len); skb_reserve(skb, 4); if (lmi == LMI_CISCO) |