X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;ds=inline;f=drivers%2Fnet%2Fqede%2Fbase%2Fecore_vf.c;h=161b31764d50744ffbb3fabd819a752b47c3182f;hb=3eb0add0c2f356bae45c8d03619953233f566e5a;hp=634e2bb98f4a19f803b4cf3ab9aa0f5aa270ffeb;hpb=22d07d939c3cfdf9c62f48bd34f99ab708e9635d;p=dpdk.git diff --git a/drivers/net/qede/base/ecore_vf.c b/drivers/net/qede/base/ecore_vf.c index 634e2bb98f..161b31764d 100644 --- a/drivers/net/qede/base/ecore_vf.c +++ b/drivers/net/qede/base/ecore_vf.c @@ -296,6 +296,14 @@ static enum _ecore_status_t ecore_vf_pf_acquire(struct ecore_hwfn *p_hwfn) VFPF_ACQUIRE_CAP_PRE_FP_HSI; } } + + /* If PF/VF are using same Major, PF must have had + * it's reasons. Simply fail. + */ + DP_NOTICE(p_hwfn, false, + "PF rejected acquisition by VF\n"); + rc = ECORE_INVAL; + goto exit; } else { DP_ERR(p_hwfn, "PF returned err %d to VF acquisition request\n", @@ -336,7 +344,7 @@ static enum _ecore_status_t ecore_vf_pf_acquire(struct ecore_hwfn *p_hwfn) /* Learn of the possibility of CMT */ if (IS_LEAD_HWFN(p_hwfn)) { if (resp->pfdev_info.capabilities & PFVF_ACQUIRE_CAP_100G) { - DP_NOTICE(p_hwfn, false, "100g VF\n"); + DP_INFO(p_hwfn, "100g VF\n"); p_hwfn->p_dev->num_hwfns = 2; } } @@ -1382,6 +1390,15 @@ void ecore_vf_get_num_mac_filters(struct ecore_hwfn *p_hwfn, *num_mac = p_vf->acquire_resp.resc.num_mac_filters; } +void ecore_vf_get_num_sbs(struct ecore_hwfn *p_hwfn, + u32 *num_sbs) +{ + struct ecore_vf_iov *p_vf; + + p_vf = p_hwfn->vf_iov_info; + *num_sbs = (u32)p_vf->acquire_resp.resc.num_sbs; +} + bool ecore_vf_check_mac(struct ecore_hwfn *p_hwfn, u8 *mac) { struct ecore_bulletin_content *bulletin;