linux-brain/drivers/net/ethernet/qlogic
Tom Seewald 44fe392e1a qlcnic: Add null check after calling netdev_alloc_skb
commit 84460f01cba382553199bc1361f69a872d5abed4 upstream.

The function qlcnic_dl_lb_test() currently calls netdev_alloc_skb()
without checking afterwards that the allocation succeeded. Fix this by
checking if the skb is NULL and returning an error in such a case.
Breaking out of the loop if the skb is NULL is not correct as no error
would be reported to the caller and no message would be printed for the
user.

Cc: David S. Miller <davem@davemloft.net>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Tom Seewald <tseewald@gmail.com>
Link: https://lore.kernel.org/r/20210503115736.2104747-26-gregkh@linuxfoundation.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-05-26 12:05:20 +02:00
..
netxen netxen_nic: fix MSI/MSI-x interrupts 2021-01-23 15:57:57 +01:00
qed qed: fix error return code in qed_iwarp_ll2_start() 2020-11-24 13:28:59 +01:00
qede qede: fix offload for IPIP tunnel packets 2021-01-12 20:16:12 +01:00
qlcnic qlcnic: Add null check after calling netdev_alloc_skb 2021-05-26 12:05:20 +02:00
Kconfig qed: select CONFIG_CRC32 2021-01-17 14:05:36 +01:00
Makefile qlge: Move drivers/net/ethernet/qlogic/qlge/ to drivers/staging/qlge/ 2019-07-23 11:29:40 -07:00
qla3xxx.c net: qlogic: Fix error paths in ql_alloc_large_buffers() 2019-12-31 16:41:27 +01:00
qla3xxx.h