Message ID | 20211123133157.21829-1-biju.das.jz@bp.renesas.com (mailing list archive) |
---|---|
Headers | show |
Series | Add Rx checksum offload support | expand |
Hello! On 23.11.2021 16:31, Biju Das wrote: > TOE has hw support for calculating IP header checkum for IPV4 and hw == hardware? And checksum. :-) > TCP/UDP/ICMP checksum for both IPV4 and IPV6. > > This patch series aims to adds Rx checksum offload supported by TOE. > > For RX, The result of checksum calculation is attached to last 4byte > of ethernet frames. First 2bytes is result of IPV4 header checksum > and next 2 bytes is TCP/UDP/ICMP. > > if frame does not have error "0000" attached to checksum calculation > result. For unsupported frames "ffff" is attached to checksum calculation > result. Cases like IPV6, IPV4 header is always set to "FFFF". You just said IPv4 header checksum is supported? > we can test this functionality by the below commands > > ethtool -K eth0 rx on --> to turn on Rx checksum offload > ethtool -K eth0 rx off --> to turn off Rx checksum offload > > Biju Das (2): > ravb: Fillup ravb_set_features_gbeth() stub > ravb: Add Rx checksum offload support > > drivers/net/ethernet/renesas/ravb.h | 20 +++++++++ > drivers/net/ethernet/renesas/ravb_main.c | 55 +++++++++++++++++++++++- > 2 files changed, 74 insertions(+), 1 deletion(-) Dave, Jakub, I'll try reviewing these later today. MBR, Sergey
Hi Sergey Shtylyov, > Subject: Re: [RFC 0/2] Add Rx checksum offload support > > Hello! > > On 23.11.2021 16:31, Biju Das wrote: > > > TOE has hw support for calculating IP header checkum for IPV4 and > > hw == hardware? And checksum. :-) Oops typo. My mistake. > > > TCP/UDP/ICMP checksum for both IPV4 and IPV6. > > > > This patch series aims to adds Rx checksum offload supported by TOE. > > > > For RX, The result of checksum calculation is attached to last 4byte > > of ethernet frames. First 2bytes is result of IPV4 header checksum and > > next 2 bytes is TCP/UDP/ICMP. > > > > if frame does not have error "0000" attached to checksum calculation > > result. For unsupported frames "ffff" is attached to checksum > > calculation result. Cases like IPV6, IPV4 header is always set to > "FFFF". > > You just said IPv4 header checksum is supported? Yes you are correct. for IPV4, IPv4 header checksum is supported. If it is supported case and no error the result is set to "0000" by the hardware. Where as for IPv6, IPV4 header is unsupported case, so the result is always set to "ffff" by the hardware Cheers, Biju > > > we can test this functionality by the below commands > > > > ethtool -K eth0 rx on --> to turn on Rx checksum offload ethtool -K > > eth0 rx off --> to turn off Rx checksum offload > > > > Biju Das (2): > > ravb: Fillup ravb_set_features_gbeth() stub > > ravb: Add Rx checksum offload support > > > > drivers/net/ethernet/renesas/ravb.h | 20 +++++++++ > > drivers/net/ethernet/renesas/ravb_main.c | 55 +++++++++++++++++++++++- > > 2 files changed, 74 insertions(+), 1 deletion(-) > > Dave, Jakub, I'll try reviewing these later today. > > MBR, Sergey
On 11/23/21 4:31 PM, Biju Das wrote: > TOE has hw support for calculating IP header checkum for IPV4 and > TCP/UDP/ICMP checksum for both IPV4 and IPV6. > > This patch series aims to adds Rx checksum offload supported by TOE. > > For RX, The result of checksum calculation is attached to last 4byte > of ethernet frames. First 2bytes is result of IPV4 header checksum > and next 2 bytes is TCP/UDP/ICMP. > > if frame does not have error "0000" attached to checksum calculation > result. For unsupported frames "ffff" is attached to checksum calculation > result. Cases like IPV6, IPV4 header is always set to "FFFF". > > we can test this functionality by the below commands > > ethtool -K eth0 rx on --> to turn on Rx checksum offload > ethtool -K eth0 rx off --> to turn off Rx checksum offload > > Biju Das (2): > ravb: Fillup ravb_set_features_gbeth() stub > ravb: Add Rx checksum offload support That's all fine but why in the world did you separate these patches? MBR, Sergey
Hi Sergey Shtylyov, > Subject: Re: [RFC 0/2] Add Rx checksum offload support > > On 11/23/21 4:31 PM, Biju Das wrote: > > > TOE has hw support for calculating IP header checkum for IPV4 and > > TCP/UDP/ICMP checksum for both IPV4 and IPV6. > > > > This patch series aims to adds Rx checksum offload supported by TOE. > > > > For RX, The result of checksum calculation is attached to last 4byte > > of ethernet frames. First 2bytes is result of IPV4 header checksum and > > next 2 bytes is TCP/UDP/ICMP. > > > > if frame does not have error "0000" attached to checksum calculation > > result. For unsupported frames "ffff" is attached to checksum > > calculation result. Cases like IPV6, IPV4 header is always set to > "FFFF". > > > > we can test this functionality by the below commands > > > > ethtool -K eth0 rx on --> to turn on Rx checksum offload ethtool -K > > eth0 rx off --> to turn off Rx checksum offload > > > > Biju Das (2): > > ravb: Fillup ravb_set_features_gbeth() stub > > ravb: Add Rx checksum offload support > > That's all fine but why in the world did you separate these patches? OK, as you suggested will merge this patches and send an RFC for further feedback. Regards, Biju