]> git.baikalelectronics.ru Git - kernel.git/commit
net: qlogic: check the return value of dma_alloc_coherent() in qed_vf_hw_prepare()
authorJia-Ju Bai <baijiaju1990@gmail.com>
Sat, 5 Mar 2022 09:14:11 +0000 (01:14 -0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 7 Mar 2022 11:28:38 +0000 (11:28 +0000)
commitb80059a74cc6c636d4bdf30ad19f967944dfa6e0
tree7f2d8a9ef75a5d2279c949bc17f86cac7c93176d
parentdf95eff33f10ea4970d23d18832336b68700314a
net: qlogic: check the return value of dma_alloc_coherent() in qed_vf_hw_prepare()

The function dma_alloc_coherent() in qed_vf_hw_prepare() can fail, so
its return value should be checked.

Fixes: 797fbcd52983 ("qed: Introduce VFs")
Reported-by: TOTE Robot <oslab@tsinghua.edu.cn>
Signed-off-by: Jia-Ju Bai <baijiaju1990@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qed/qed_vf.c