Imported Upstream version 16.07-rc2
[deb_dpdk.git] / drivers / net / bnx2x / bnx2x.c
index 3095d2b..95fbad8 100644 (file)
@@ -22,7 +22,6 @@
 #include "ecore_init_ops.h"
 
 #include "rte_version.h"
-#include "rte_pci_dev_ids.h"
 
 #include <sys/types.h>
 #include <sys/stat.h>
@@ -9572,7 +9571,7 @@ void bnx2x_load_firmware(struct bnx2x_softc *sc)
        int f;
        struct stat st;
 
-       fwname = sc->devinfo.device_id == BNX2X_DEV_ID_57711
+       fwname = sc->devinfo.device_id == CHIP_NUM_57711
                ? FW_NAME_57711 : FW_NAME_57810;
        f = open(fwname, O_RDONLY);
        if (f < 0) {
@@ -9682,9 +9681,6 @@ int bnx2x_attach(struct bnx2x_softc *sc)
 
        sc->state = BNX2X_STATE_CLOSED;
 
-       /* Init RTE stuff */
-       bnx2x_init_rte(sc);
-
        pci_write_long(sc, PCICFG_GRC_ADDRESS, PCICFG_VENDOR_ID_OFFSET);
 
        sc->igu_base_addr = IS_VF(sc) ? PXP_VF_ADDR_IGU_START : BAR_IGU_INTMEM;
@@ -9702,6 +9698,9 @@ int bnx2x_attach(struct bnx2x_softc *sc)
                sc->igu_sb_cnt = 1;
        }
 
+       /* Init RTE stuff */
+       bnx2x_init_rte(sc);
+
        if (IS_PF(sc)) {
 /* get device info and set params */
                if (bnx2x_get_device_info(sc) != 0) {