[dpdk-dev] [PATCH v6 2/2] net/ixgbe: add callback to user app on VF to PF mbox msg

Thomas Monjalon thomas.monjalon at 6wind.com
Fri Oct 7 14:14:02 CEST 2016


2016-10-06 17:48, Bernard Iremonger:
> call _rte_eth_dev_callback_process from ixgbe_rcv_msg_from_vf function.
> 
> The callback asks the user application if it is allowed to perform
> the function.
> If the cb_param.retval is RTE_PMD_IXGBE_MB_EVENT_PROCEED then continue,
> if 0, do nothing and send ACK to VF
> if > 1, do nothing and send NAK to VF.
[...]
> --- a/drivers/net/ixgbe/ixgbe_ethdev.c
> +++ b/drivers/net/ixgbe/ixgbe_ethdev.c
> @@ -3559,7 +3559,7 @@ ixgbe_dev_interrupt_delayed_handler(void *param)
>  		ixgbe_dev_link_update(dev, 0);
>  		intr->flags &= ~IXGBE_FLAG_NEED_LINK_UPDATE;
>  		ixgbe_dev_link_status_print(dev);
> -		_rte_eth_dev_callback_process(dev, RTE_ETH_EVENT_INTR_LSC);
> +		_rte_eth_dev_callback_process(dev, RTE_ETH_EVENT_INTR_LSC, NULL);
>  	}
>  
>  	PMD_DRV_LOG(DEBUG, "enable intr in delayed handler S[%08x]", eicr);
> @@ -7525,7 +7525,7 @@ static void ixgbevf_mbx_process(struct rte_eth_dev *dev)
>  
>  	/* PF reset VF event */
>  	if (in_msg == IXGBE_PF_CONTROL_MSG)
> -		_rte_eth_dev_callback_process(dev, RTE_ETH_EVENT_INTR_RESET);
> +		_rte_eth_dev_callback_process(dev, RTE_ETH_EVENT_INTR_RESET, NULL);
>  }

This piece should go into the patch 1.


More information about the dev mailing list