]> git.baikalelectronics.ru Git - kernel.git/commit
hv_netvsc: Add ethtool handler to set and get TCP hash levels
authorHaiyang Zhang <haiyangz@microsoft.com>
Fri, 6 Oct 2017 15:33:58 +0000 (08:33 -0700)
committerDavid S. Miller <davem@davemloft.net>
Sun, 8 Oct 2017 17:11:01 +0000 (10:11 -0700)
commit0237723267513653bb2b05ace7fcff66dbb54675
tree9cbaf22e7c8d211c4d49d329f3973daef160beb2
parent8ed348b8594cac7b5a6f3326a1c803c12c166a92
hv_netvsc: Add ethtool handler to set and get TCP hash levels

The patch supports the options to switch TCP hash level between
L3 and L4 by ethtool command. TCP over IPv4 and v6 can be set
differently. The default hash level is L4. We currently only
allow switching TX hash level from within the guests.

For example, for TCP over IPv4 on eth0:
To include TCP port numbers in hashing:
ethtool -N eth0 rx-flow-hash tcp4 sdfn
To exclude TCP port numbers in hashing:
ethtool -N eth0 rx-flow-hash tcp4 sd
To show TCP hash level:
ethtool -n eth0 rx-flow-hash tcp4

Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/hyperv/netvsc_drv.c