From: Yuri Chipchev Date: Wed, 27 Jan 2021 16:09:39 +0000 (+0200) Subject: net/mvpp2: update flow control autoneg disable handling X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=c0e5d09e8169cb845a46002c24fddcd992232756;p=dpdk.git net/mvpp2: update flow control autoneg disable handling Flow control autoneg disable is not supported Signed-off-by: Yuri Chipchev Reviewed-by: Liron Himi --- diff --git a/drivers/net/mvpp2/mrvl_ethdev.c b/drivers/net/mvpp2/mrvl_ethdev.c index fde6533f1f..c5431372f8 100644 --- a/drivers/net/mvpp2/mrvl_ethdev.c +++ b/drivers/net/mvpp2/mrvl_ethdev.c @@ -2138,6 +2138,7 @@ mrvl_flow_ctrl_get(struct rte_eth_dev *dev, struct rte_eth_fc_conf *fc_conf) if (!priv) return -EPERM; + fc_conf->autoneg = 1; ret = pp2_ppio_get_rx_pause(priv->ppio, &en); if (ret) { MRVL_LOG(ERR, "Failed to read rx pause state"); @@ -2187,13 +2188,17 @@ mrvl_flow_ctrl_set(struct rte_eth_dev *dev, struct rte_eth_fc_conf *fc_conf) if (fc_conf->high_water || fc_conf->low_water || fc_conf->pause_time || - fc_conf->mac_ctrl_frame_fwd || - fc_conf->autoneg) { + fc_conf->mac_ctrl_frame_fwd) { MRVL_LOG(ERR, "Flowctrl parameter is not supported"); return -EINVAL; } + if (fc_conf->autoneg == 0) { + MRVL_LOG(ERR, "Flowctrl Autoneg disable is not supported"); + return -EINVAL; + } + switch (fc_conf->mode) { case RTE_FC_FULL: rx_en = 1;