baseband/fpga_5gnr_fec: fix crash with debug
authorMaxime Coquelin <maxime.coquelin@redhat.com>
Tue, 6 Oct 2020 10:04:20 +0000 (12:04 +0200)
committerAkhil Goyal <akhil.goyal@nxp.com>
Wed, 14 Oct 2020 19:32:11 +0000 (21:32 +0200)
commite309e9206123d07b7b3bf1e87a934fada636a87d
tree2033a4e69fb334338ddf6b1f04950ea3d9f3364d
parent99c886d3e3490207809bf276b37d734df7613c16
baseband/fpga_5gnr_fec: fix crash with debug

When RTE_LIBRTE_BBDEV_DEBUG is enabled, rte_device's driver
pointer is dereferenced twice in fpga_5gnr_fec's probe callback.
It causes a segmentation fault because this pointer is only
assigned after probe callback call.

This patch makes use of rte_pci_driver pointer instead.

Fixes: 0b5927cbcba7 ("baseband/fpga_5gnr_fec: add PMD for FPGA 5GNR FEC")
Cc: stable@dpdk.org
Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Acked-by: Nicolas Chautru <nicolas.chautru@intel.com>
drivers/baseband/fpga_5gnr_fec/rte_fpga_5gnr_fec.c