[dpdk-dev] [PATCH v3] net/ipn3ke: setup MTU when HW init

Pei, Andy andy.pei at intel.com
Tue Sep 3 08:29:05 CEST 2019


Hi Xiaolong,

I tried, but compile issue exist.

-----Original Message-----
From: Ye, Xiaolong 
Sent: Tuesday, September 3, 2019 2:23 PM
To: Pei, Andy <andy.pei at intel.com>
Cc: dev at dpdk.org; Zhang, Qi Z <qi.z.zhang at intel.com>; Yigit, Ferruh <ferruh.yigit at intel.com>; Xu, Rosen <rosen.xu at intel.com>
Subject: Re: [PATCH v3] net/ipn3ke: setup MTU when HW init

On 09/03, Pei, Andy wrote:
[snip]
>	tmp = RTE_MAX(tmp, RTE_ETHER_MIN_MTU);
>
>>+	if (tmp > IPN3KE_MAC_FRAME_SIZE_MAX - IPN3KE_ETH_OVERHEAD)
>>+		tmp = IPN3KE_MAC_FRAME_SIZE_MAX - IPN3KE_ETH_OVERHEAD;
>
>	tmp = RTE_MIN(tmp, IPN3KE_MAC_FRAME_SIZE_MAX - IPN3KE_ETH_OVERHEAD);
>	
>in the definition of TRE_MIN and TRE_MAX, typeof() is used.
>RTE_ETHER_MIN_MTU is MACRO, your expression cause complie issue.
>

How about RTE_MAX(tmp, (uint32_t)RTE_ETHER_MIN_MTU)

Thanks,
Xiaolong


More information about the dev mailing list