Skip to content

Commit 3a21bf5

Browse files
elfringholtmann
authored andcommitted
ieee802154: ca8210: Delete an error message for a failed memory allocation in ca8210_skb_rx()
Omit an extra message for a memory allocation failure in this function. This issue was detected by using the Coccinelle software. Link: http://events.linuxfoundation.org/sites/events/files/slides/LCJ16-Refactor_Strings-WSang_0.pdf Signed-off-by: Markus Elfring <[email protected]> Signed-off-by: Marcel Holtmann <[email protected]>
1 parent 8ec4a1e commit 3a21bf5

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

drivers/net/ieee802154/ca8210.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1808,10 +1808,9 @@ static int ca8210_skb_rx(
18081808

18091809
/* Allocate mtu size buffer for every rx packet */
18101810
skb = dev_alloc_skb(IEEE802154_MTU + sizeof(hdr));
1811-
if (!skb) {
1812-
dev_crit(&priv->spi->dev, "dev_alloc_skb failed\n");
1811+
if (!skb)
18131812
return -ENOMEM;
1814-
}
1813+
18151814
skb_reserve(skb, sizeof(hdr));
18161815

18171816
msdulen = data_ind[22]; /* msdu_length */

0 commit comments

Comments
 (0)