This brings some benefit of a tcp flow identification for some kernel
modules, such as siftr.
Details
- Reviewers
rscheff tuexen rrs - Group Reviewers
transport - Commits
- rGe5738ee04bf0: Under RSS, assign a TCP flow's inp_flowid anyway.
Tested in an Emulab testbed.
before this change:
cc@s1:~ % netstat -nRp tcp
Active Internet connections
Proto Recv-Q Send-Q Local Address Foreign Address flowid ftype
tcp6 28 0 fd00::2.41352 fd00::3.5001 00000000 0
tcp6 28 0 fd00::2.10845 fd00::3.5001 00000000 0
tcp6 28 0 fd00::2.28532 fd00::3.5001 00000000 0
tcp6 28 0 fd00::2.34124 fd00::3.5001 00000000 0
tcp4 0 0 127.0.0.1.16505 127.0.0.1.57268 00000000 0
tcp4 0 0 127.0.0.1.57268 127.0.0.1.16505 00000000 0
tcp4 0 0 127.0.0.1.16505 127.0.0.1.37918 00000000 0
tcp4 0 0 127.0.0.1.37918 127.0.0.1.16505 00000000 0
after this change:
cc@s1:~ % netstat -nRp tcp
Active Internet connections
Proto Recv-Q Send-Q Local Address Foreign Address flowid ftype
tcp6 28 0 fd00::2.43004 fd00::3.5001 8458ef94 132
tcp6 28 0 fd00::2.59450 fd00::3.5001 f96e24cf 132
tcp6 28 0 fd00::2.25706 fd00::3.5001 70119d2f 132
tcp6 28 0 fd00::2.27760 fd00::3.5001 8a1ed781 132
tcp4 0 0 127.0.0.1.16505 127.0.0.1.30417 e34c3361 130
tcp4 0 0 127.0.0.1.30417 127.0.0.1.16505 58b6e0bb 130
tcp4 0 0 127.0.0.1.16505 127.0.0.1.18519 c47bf08d 130
tcp4 0 0 127.0.0.1.18519 127.0.0.1.16505 9b5a6416 130
Diff Detail
- Repository
- rG FreeBSD src repository
- Lint
Lint Passed - Unit
No Test Coverage - Build Status
Buildable 51445 Build 48336: arc lint + arc unit
Event Timeline
sys/netinet/tcp_input.c | ||
---|---|---|
948 | Would it make sense to organize the code above and below like: if ((inp->inp_flowtype == M_HASHTYPE_NONE) && !SOLISTENING(inp->inp_socket)) { if (M_HASHTYPE_GET(m) != M_HASHTYPE_NONE) { inp->inp_flowid = m->m_pkthdr.flowid; inp->inp_flowtype = M_HASHTYPE_GET(m); #ifdef RSS } else { /* assign flowid by software RSS hash */ ... #endif } } |
sys/netinet/tcp_input.c | ||
---|---|---|
948 | Good idea. Will change. Thanks. |
sys/netinet/tcp_input.c | ||
---|---|---|
949 | Why not do #ifdef RSS } else { ... #endif } |
sys/netinet/tcp_input.c | ||
---|---|---|
949 | I see what you mean now. I will clean it up. Thanks. |