On 5/24/2018 10:20 AM, Andriy Berestovskyy wrote:
> Hi Shahaf,
> 
>> On 23 May 2018, at 07:21, Shahaf Shuler <shah...@mellanox.com> wrote:
>> I think this patch addressing just small issue in a bigger problem.
>> The way I see it all application needs to specify is the max packet size it 
>> expects to receive, nothing else(!). 
> 
> [...]
> 
>> IMO The "jumbo_frame" bit can be set by the underlying PMD directly to the 
>> device registers given the max_rx_pkt_len configuration. 
> 
> Sure, it can be deducted in PMD if max_rx_pkt_len is greater than the normal 
> frame size.
> 
> The background behind this patch was to fix some examples on some platforms 
> by allowing them to just set the jumbo bit in config and let the DPDK to 
> deduct the optimal jumbo max_rx_pkt_len.
> 
> There was also another patch which fixed those examples, so they first query 
> the max_rx_pkt_len and then pass it with the config:
> http://dpdk.org/commit/5e470a6654
> 
> That patch has been merged, so now we can fix/change the API in any way we 
> decide, there is no urgency anymore.
> 
> Looks like the jumbo bit in config is redundant, but there might be other 
> opinions.

Back to this old issue, the mentioned inconsistency is still exist in the
current code, and this or relevant ones mentioned a few times already.

What would you think about developing an unit test on 19.05 to test these on
ethdev, and ask vendors to run it and fix failures in next releases?
A more TDD approach, first right the test that fails, later fix it.
If there is a support I can start writing it but will require support.


And related issues:
max_rx_pkt_len
DEV_RX_OFFLOAD_JUMBO_FRAME
DEV_TX_OFFLOAD_MULTI_SEGS
scattered_rx
mtu


These are provided by user as config option, but some drivers updates some of
them, initial question is, are they input only or can be modified by drivers.

Like if user not requested JUMBO_FRAME but provided a large max_rx_pkt_len,
should user get an error or should PMD enable jumbo frame itself?


And another question around 'max_rx_pkt_len' / 'mtu', both are related and
close. 'max_rx_pkt_len' is frame size as far as I can understand, and since we
have capability to set 'mtu', this looks duplicate.
And I assume users are mostly will be interested in 'mtu', for given 'mtu'
driver can calculate 'max_rx_pkt_len' taking other config options into account
affecting frame size.

Reply via email to