[dpdk-dev] [PATCH v2 1/3] net/af_packet: set_mtu() decrements sockaddr twice

2018-11-20 Thread Tiago Lam
When setting the MTU, eth_dev_mtu_set() is called to validate the provided MTU. As part of that, it calculates the useful area to store data and compares it against the MTU, to guarantee that there's enough space to store the data. It calculates that as: "tp_frame_size - TPACKET2_HDRLEN - sizeo

Re: [dpdk-dev] [PATCH v2 1/3] net/af_packet: set_mtu() decrements sockaddr twice

2018-12-21 Thread Ferruh Yigit
On 11/20/2018 10:26 AM, Tiago Lam wrote: > When setting the MTU, eth_dev_mtu_set() is called to validate the > provided MTU. As part of that, it calculates the useful area to store > data and compares it against the MTU, to guarantee that there's enough > space to store the data. It calculates that

Re: [dpdk-dev] [PATCH v2 1/3] net/af_packet: set_mtu() decrements sockaddr twice

2018-11-20 Thread Kevin Traynor
On 11/20/2018 10:26 AM, Tiago Lam wrote: > When setting the MTU, eth_dev_mtu_set() is called to validate the > provided MTU. As part of that, it calculates the useful area to store > data and compares it against the MTU, to guarantee that there's enough > space to store the data. It calculates that

Re: [dpdk-dev] [PATCH v2 1/3] net/af_packet: set_mtu() decrements sockaddr twice

2018-11-20 Thread Lam, Tiago
On 20/11/2018 10:29, Kevin Traynor wrote: > On 11/20/2018 10:26 AM, Tiago Lam wrote: >> When setting the MTU, eth_dev_mtu_set() is called to validate the >> provided MTU. As part of that, it calculates the useful area to store >> data and compares it against the MTU, to guarantee that there's en

Re: [dpdk-dev] [PATCH v2 1/3] net/af_packet: set_mtu() decrements sockaddr twice

2018-11-27 Thread Ferruh Yigit
On 11/20/2018 10:26 AM, Tiago Lam wrote: > When setting the MTU, eth_dev_mtu_set() is called to validate the > provided MTU. As part of that, it calculates the useful area to store > data and compares it against the MTU, to guarantee that there's enough > space to store the data. It calculates that