goto err1;
        }
 
-       if (p_hwfn == ECORE_LEADING_HWFN(p_dev) && !p_dev->recov_in_prog) {
-               rc = ecore_mcp_initiate_pf_flr(p_hwfn, p_hwfn->p_main_ptt);
-               if (rc != ECORE_SUCCESS)
-                       DP_NOTICE(p_hwfn, false, "Failed to initiate PF FLR\n");
-       }
-
        /* Read the device configuration information from the HW and SHMEM */
        rc = ecore_get_hw_info(p_hwfn, p_hwfn->p_main_ptt,
                               p_params->personality, p_params->drv_resc_alloc);
                goto err2;
        }
 
+       /* Sending a mailbox to the MFW should be after ecore_get_hw_info() is
+        * called, since among others it sets the ports number in an engine.
+        */
+       if (p_params->initiate_pf_flr && p_hwfn == ECORE_LEADING_HWFN(p_dev) &&
+           !p_dev->recov_in_prog) {
+               rc = ecore_mcp_initiate_pf_flr(p_hwfn, p_hwfn->p_main_ptt);
+               if (rc != ECORE_SUCCESS)
+                       DP_NOTICE(p_hwfn, false, "Failed to initiate PF FLR\n");
+       }
+
        /* Allocate the init RT array and initialize the init-ops engine */
        rc = ecore_init_alloc(p_hwfn);
        if (rc) {
 
        bool drv_resc_alloc;
        /* check the reg_fifo after any register access */
        bool chk_reg_fifo;
+       /* request the MFW to initiate PF FLR */
+       bool initiate_pf_flr;
 };
 
 /**
 
 {
        u32 mcp_resp, mcp_param;
 
-       return ecore_mcp_cmd(p_hwfn, p_ptt, DRV_MSG_CODE_INITIATE_PF_FLR,
-                            0, &mcp_resp, &mcp_param);
+       return ecore_mcp_cmd(p_hwfn, p_ptt, DRV_MSG_CODE_INITIATE_PF_FLR, 0,
+                            &mcp_resp, &mcp_param);
 }
 
 enum _ecore_status_t ecore_mcp_mdump_get_info(struct ecore_hwfn *p_hwfn,
                                              struct ecore_ptt *p_ptt);
 
+/**
+ * @brief - Gets the MFW allocation info for the given resource
+ *
+ *  @param p_hwfn
+ *  @param p_ptt
+ *  @param p_resc_info
+ *  @param p_mcp_resp
+ *  @param p_mcp_param
+ *
+ * @return enum _ecore_status_t - ECORE_SUCCESS - operation was successful.
+ */
 enum _ecore_status_t ecore_mcp_get_resc_info(struct ecore_hwfn *p_hwfn,
                                             struct ecore_ptt *p_ptt,
                                             struct resource_info *p_resc_info,
 
        hw_prepare_params.personality = ECORE_PCI_ETH;
        hw_prepare_params.drv_resc_alloc = false;
        hw_prepare_params.chk_reg_fifo = false;
+       hw_prepare_params.initiate_pf_flr = true;
        rc = ecore_hw_prepare(edev, &hw_prepare_params);
        if (rc) {
                DP_ERR(edev, "hw prepare failed\n");