Skip to content

Commit 184fb40

Browse files
sumang-mrvlPaolo Abeni
authored andcommitted
octeontx2-pf: Avoid adding dcbnl_ops for LBK and SDP vf
Priority flow control is not supported for LBK and SDP vf. This patch adds support to not add dcbnl_ops for LBK and SDP vf. Fixes: 8e67558 ("octeontx2-pf: PFC config support with DCBx") Signed-off-by: Suman Ghosh <[email protected]> Reviewed-by: Simon Horman <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Paolo Abeni <[email protected]>
1 parent 625b40d commit 184fb40

File tree

1 file changed

+6
-3
lines changed
  • drivers/net/ethernet/marvell/octeontx2/nic

1 file changed

+6
-3
lines changed

drivers/net/ethernet/marvell/octeontx2/nic/otx2_vf.c

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -729,9 +729,12 @@ static int otx2vf_probe(struct pci_dev *pdev, const struct pci_device_id *id)
729729
}
730730

731731
#ifdef CONFIG_DCB
732-
err = otx2_dcbnl_set_ops(netdev);
733-
if (err)
734-
goto err_free_zc_bmap;
732+
/* Priority flow control is not supported for LBK and SDP vf(s) */
733+
if (!(is_otx2_lbkvf(vf->pdev) || is_otx2_sdp_rep(vf->pdev))) {
734+
err = otx2_dcbnl_set_ops(netdev);
735+
if (err)
736+
goto err_free_zc_bmap;
737+
}
735738
#endif
736739
otx2_qos_init(vf, qos_txqs);
737740

0 commit comments

Comments
 (0)