[dpdk-stable] [dpdk-dev] [PATCH v11 3/4] raw/ifpga: add OPAE API for OpenStack Cyborg

Ferruh Yigit ferruh.yigit at intel.com
Thu Jan 21 17:33:36 CET 2021


On 1/21/2021 6:03 AM, Wei Huang wrote:
> +int opae_init(int eal_init_result)
> +{
> +	int ret = 0;
> +
> +	if (!check_eal(0))
> +		return 0;
> +
> +	if (eal_init_result < 0) {
> +		if (rte_errno == EALREADY) {
> +			eal_inited = 1;
> +			opae_log_info("EAL already initialized\n");
> +		} else {
> +			opae_log_err("Cannot initialize EAL\n");
> +			ret = -1;
> +		}
> +	} else {
> +		eal_inited = 1;
> +		opae_log_info("Initialize EAL done\n");
> +	}
> +
> +	return ret;
> +}

Why an PMD API needs to know eal initialization status? This may be pointing a 
bad design, is it possible that most of the 'opae_' API code should go to the 
application?


More information about the stable mailing list