net/octeontx2: fix loopback config return for VF
authorSunil Kumar Kori <skori@marvell.com>
Tue, 26 Nov 2019 07:03:58 +0000 (12:33 +0530)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 26 Nov 2019 17:05:15 +0000 (18:05 +0100)
loopback mode is not supported for VFs so returning error if
VF is being configured with loopback mode.

Fixes: 920717e4d8ba ("net/octeontx2: add device start operation")
Cc: stable@dpdk.org
Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
drivers/net/octeontx2/otx2_ethdev.c

index eaf7ba9..ed32927 100644 (file)
@@ -205,7 +205,7 @@ cgx_intlbk_enable(struct otx2_eth_dev *dev, bool en)
        struct otx2_mbox *mbox = dev->mbox;
 
        if (otx2_dev_is_vf_or_sdp(dev))
-               return 0;
+               return -ENOTSUP;
 
        if (en)
                otx2_mbox_alloc_msg_cgx_intlbk_enable(mbox);