linux_dsm_epyc7002/drivers/net/ethernet/huawei/hinic
Colin Ian King e159e59287 net: hinic: fix null pointer dereference on pointer hwdev
Pointer hwdev is being dereferenced when declaring hwif , however, later
on hwdev is being null checked, hence we have dereference before null
check error. Fix this by assigning hwif and pdef only once hwdev has
been null checked.

Detected by CoverityScan, CID#1485581 ("Dereference before null check")

Fixes: 4a61abb100 ("net-next/hinic:add rx checksum offload for HiNIC")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2018-11-23 17:22:02 -08:00
..
hinic_common.c net-next/hinic: Add cmdq commands 2017-08-22 10:48:53 -07:00
hinic_common.h net-next/hinic: Add cmdq commands 2017-08-22 10:48:53 -07:00
hinic_dev.h net-next/hinic: Add ethtool and stats 2017-08-22 10:48:54 -07:00
hinic_hw_api_cmd.c hinic: uninitialized variable in hinic_api_cmd_init() 2017-08-24 21:47:11 -07:00
hinic_hw_api_cmd.h net-next/hinic: Add api cmd commands 2017-08-22 10:48:53 -07:00
hinic_hw_cmdq.c treewide: Use array_size() in vzalloc() 2018-06-12 16:19:22 -07:00
hinic_hw_cmdq.h hinic: Replace PCI pool old API 2018-01-02 16:14:49 -06:00
hinic_hw_csr.h net-next/hinic: Add Rx handler 2017-08-22 10:48:54 -07:00
hinic_hw_dev.c net: hinic: remove redundant pointer pfhwdev 2018-07-04 22:39:11 +09:00
hinic_hw_dev.h net-next/hinic:add rx checksum offload for HiNIC 2018-11-20 10:38:08 -08:00
hinic_hw_eqs.c net: hinic: make functions set_ctrl0 and set_ctrl1 static 2017-08-23 22:20:28 -07:00
hinic_hw_eqs.h net-next/hinic: Add ceqs 2017-08-22 10:48:53 -07:00
hinic_hw_if.c net-next/hinic: Add Rx handler 2017-08-22 10:48:54 -07:00
hinic_hw_if.h net-next/hinic: Add Rx handler 2017-08-22 10:48:54 -07:00
hinic_hw_io.c net-next/hinic: Add ceqs 2017-08-22 10:48:53 -07:00
hinic_hw_io.h net-next/hinic: Add cmdq commands 2017-08-22 10:48:53 -07:00
hinic_hw_mgmt.c net-next/hinic: Add Rx mode and link event handler 2017-08-22 10:48:53 -07:00
hinic_hw_mgmt.h net-next/hinic: Add Rx handler 2017-08-22 10:48:54 -07:00
hinic_hw_qp_ctxt.h net-next/hinic: Set qp context 2017-08-22 10:48:53 -07:00
hinic_hw_qp.c hinic: Fix l4_type parameter in hinic_task_set_tunnel_l4 2018-10-29 20:43:40 -07:00
hinic_hw_qp.h hinic: Fix l4_type parameter in hinic_task_set_tunnel_l4 2018-10-29 20:43:40 -07:00
hinic_hw_wq.c net-next/hinic:replace multiply and division operators 2018-11-20 10:38:08 -08:00
hinic_hw_wq.h net-next/hinic:replace multiply and division operators 2018-11-20 10:38:08 -08:00
hinic_hw_wqe.h net-next/hinic:add rx checksum offload for HiNIC 2018-11-20 10:38:08 -08:00
hinic_main.c net-next/hinic:fix a bug in set mac address 2018-11-20 10:38:08 -08:00
hinic_port.c net: hinic: fix null pointer dereference on pointer hwdev 2018-11-23 17:22:02 -08:00
hinic_port.h net-next/hinic:add rx checksum offload for HiNIC 2018-11-20 10:38:08 -08:00
hinic_rx.c net-next/hinic: fix a bug in rx data flow 2018-11-20 10:38:08 -08:00
hinic_rx.h net-next/hinic:add rx checksum offload for HiNIC 2018-11-20 10:38:08 -08:00
hinic_tx.c net-next/hinic: add checksum offload and TSO support 2018-10-18 16:44:37 -07:00
hinic_tx.h net-next/hinic: Add ethtool and stats 2017-08-22 10:48:54 -07:00
Kconfig net-next/hinic: add arm64 support 2018-04-19 13:34:44 -04:00
Makefile net-next/hinic: Set qp context 2017-08-22 10:48:53 -07:00