Page MenuHomeFreeBSD

cc (Cheng Cui)
User

Projects

User Details

User Since
Nov 23 2015, 12:29 AM (534 w, 6 d)

Recent Activity

Thu, Feb 12

cc committed rG9778537b6738: igc: remove M_HASHTYPE when RSS is not enabled (authored by cc).
igc: remove M_HASHTYPE when RSS is not enabled
Thu, Feb 12, 2:34 PM
cc closed D55256: igc: remove M_HASHTYPE when RSS is not enabled.
Thu, Feb 12, 2:34 PM

Wed, Feb 11

cc added reviewers for D55256: igc: remove M_HASHTYPE when RSS is not enabled: Intel Networking, Restricted Owners Package.
Wed, Feb 11, 10:25 PM
cc requested review of D55256: igc: remove M_HASHTYPE when RSS is not enabled.
Wed, Feb 11, 10:24 PM

Tue, Feb 10

cc added a comment to D55143: igb: remove M_HASHTYPE when RSS is not enabled.
In D55143#1260975, @cc wrote:

Thanks. This matches i.e. http://iommu.com/datasheets/ethernet/controllers-nics/intel/e1000/ethernet-controller-i350-datasheet.pdf pg.313-314.

We can infer that igc needs a similar change based on lineage.

ixgbe uses the same hash function and nullification per http://iommu.com/datasheets/ethernet/controllers-nics/intel/ixgbe/333168-x540-datasheet-v3-1.pdf pg.290-291

I suspect this issue is now widespread in other drivers; M_HASHTYPE_OPAQUE and M_HASHTYPE_OPAQUE_HASH would only be suitable if the card is producing a unique but not tagged to one of the standard protocols (i.e. cxgb, ena are probably using it right, ixl, iavf, ice have one error).

I am afraid so. Maybe it's time to replace M_HASHTYPE_OPAQUE with M_HASHTYPE_NONE in default. I will bring this issue (together with the recently introduced sc_flowid) in Transport@.

Tue, Feb 10, 3:19 PM
cc committed rGa485399f8834: tcp: restrict flowtype copying to specific RSS TCP types (authored by cc).
tcp: restrict flowtype copying to specific RSS TCP types
Tue, Feb 10, 3:10 PM
cc closed D55196: tcp: restrict flowtype copying to specific RSS TCP types.
Tue, Feb 10, 3:09 PM

Mon, Feb 9

cc updated the diff for D55196: tcp: restrict flowtype copying to specific RSS TCP types.
  1. cancel the unnecessary change to sc_flowtype check in syncache_socket()
  2. for the rest, check RSS types by a new macro M_HASHTYPE_ISHASH_TCP
Mon, Feb 9, 10:43 PM
cc added a comment to D55196: tcp: restrict flowtype copying to specific RSS TCP types.

I think it's driver bugs that have flown under the radar until the recent RSS change so I'm not sure this is the place to do this.

In particular to this review, opaque and opaque_hash should both be usable hashes if they are implemented correctly in the driver.

Thinking about this more, I think when we are using the hash for setting flowtype, we should check for valid toeplitz hash types, since we're counting on being able to calculate the same hash in software. So I think this patch is probably the correct place to fix this. I think it would be shorter/cleaner to use M_HASHTYPE_ISHASH(). See https://reviews.freebsd.org/D52989

Question: Is M_HASHTYPE_RSS_IPV4 or M_HASHTYPE_RSS_IPV6 (a hash only on the src/dst address) acceptable or not? M_HASHTYPE_ISHASH() is true for them.

It should never happen. But to be safe, maybe make a new M_HASHTYPE_ISHASH_TCP ? At this point, my only objection is to the ugly comparisons :)

I totally agree. If we want such a hash, we should check for it.

Mon, Feb 9, 8:48 PM
cc added a comment to D55196: tcp: restrict flowtype copying to specific RSS TCP types.

I think it's driver bugs that have flown under the radar until the recent RSS change so I'm not sure this is the place to do this.

In particular to this review, opaque and opaque_hash should both be usable hashes if they are implemented correctly in the driver.

Mon, Feb 9, 5:45 PM
cc added a comment to D55196: tcp: restrict flowtype copying to specific RSS TCP types.

Slightly worried some NIC somwhere might not be setting this when it should. Is this solving a problem for you?

Mon, Feb 9, 5:25 PM
cc retitled D55196: tcp: restrict flowtype copying to specific RSS TCP types from tcp_syncache: Restrict flowtype copying to specific RSS TCP types to tcp: restrict flowtype copying to specific RSS TCP types.
Mon, Feb 9, 5:19 PM
cc requested review of D55196: tcp: restrict flowtype copying to specific RSS TCP types.
Mon, Feb 9, 5:11 PM

Fri, Feb 6

cc added a comment to D55143: igb: remove M_HASHTYPE when RSS is not enabled.

Thanks. This matches i.e. http://iommu.com/datasheets/ethernet/controllers-nics/intel/e1000/ethernet-controller-i350-datasheet.pdf pg.313-314.

We can infer that igc needs a similar change based on lineage.

ixgbe uses the same hash function and nullification per http://iommu.com/datasheets/ethernet/controllers-nics/intel/ixgbe/333168-x540-datasheet-v3-1.pdf pg.290-291

I suspect this issue is now widespread in other drivers; M_HASHTYPE_OPAQUE and M_HASHTYPE_OPAQUE_HASH would only be suitable if the card is producing a unique but not tagged to one of the standard protocols (i.e. cxgb, ena are probably using it right, ixl, iavf, ice have one error).

Fri, Feb 6, 8:55 PM
cc closed D55143: igb: remove M_HASHTYPE when RSS is not enabled.
Fri, Feb 6, 8:34 PM
cc committed rG21dd554d1697: igb: remove M_HASHTYPE when RSS is not enabled (authored by cc).
igb: remove M_HASHTYPE when RSS is not enabled
Fri, Feb 6, 8:33 PM
cc added a comment to D55137: em: remove M_HASHTYPE when RSS is not enabled.
In D55137#1260494, @cc wrote:

Looking at the linked change.. em can have two queues in one hw case. Does it matter?

My understanding is that if only one rx queue, RSS is not needed, so no hash value is needed. In a case of two rx queues, does not the hw enable RSS and provide RSS hash values?

I think that jives with pg.140: http://iommu.com/datasheets/ethernet/controllers-nics/intel/e1000/82574.pdf, the stipulation being we are seeing '0' in an error case and also no hw RSS?

igb_txrx might need the same fix

Fri, Feb 6, 2:48 PM
cc requested review of D55143: igb: remove M_HASHTYPE when RSS is not enabled.
Fri, Feb 6, 2:45 PM
cc committed rGefcc0423d80e: em: remove M_HASHTYPE when RSS is not enabled (authored by cc).
em: remove M_HASHTYPE when RSS is not enabled
Fri, Feb 6, 2:35 PM
cc closed D55137: em: remove M_HASHTYPE when RSS is not enabled.
Fri, Feb 6, 2:35 PM

Thu, Feb 5

cc added a comment to D55137: em: remove M_HASHTYPE when RSS is not enabled.

Looking at the linked change.. em can have two queues in one hw case. Does it matter?

Thu, Feb 5, 9:49 PM
cc updated the test plan for D55137: em: remove M_HASHTYPE when RSS is not enabled.
Thu, Feb 5, 9:19 PM
cc updated the test plan for D55137: em: remove M_HASHTYPE when RSS is not enabled.
Thu, Feb 5, 9:19 PM
cc requested review of D55137: em: remove M_HASHTYPE when RSS is not enabled.
Thu, Feb 5, 9:15 PM

Wed, Jan 28

cc closed D54929: vtnet: remove M_HASHTYPE when there is only one pair of rx/tx queue.
Wed, Jan 28, 9:51 PM
cc committed rG20285cad7a55: vtnet: remove M_HASHTYPE when there is only one pair of rx/tx queue (authored by cc).
vtnet: remove M_HASHTYPE when there is only one pair of rx/tx queue
Wed, Jan 28, 9:51 PM
cc updated the diff for D54929: vtnet: remove M_HASHTYPE when there is only one pair of rx/tx queue.

use the macro M_HASHTYPE_CLEAR instead, no functional change

Wed, Jan 28, 9:43 PM
cc updated the summary of D54929: vtnet: remove M_HASHTYPE when there is only one pair of rx/tx queue.
Wed, Jan 28, 7:15 PM
cc requested review of D54929: vtnet: remove M_HASHTYPE when there is only one pair of rx/tx queue.
Wed, Jan 28, 5:38 PM
cc abandoned D54896: tcp: report MSS correctly that subtracts TCP option length.

As discussed, this change is not necessary.

Wed, Jan 28, 2:31 PM

Tue, Jan 27

cc added a comment to D54896: tcp: report MSS correctly that subtracts TCP option length.

The latest FreeBSD MAN page for TCP(4) shows the TCP_MAXSEG allows to determine the result of negotiation between sender and receiver.

Tue, Jan 27, 4:12 PM

Mon, Jan 26

cc retitled D54896: tcp: report MSS correctly that subtracts TCP option length from report MSS correctly that subtracts TCP option length to tcp: report MSS correctly that subtracts TCP option length.
Mon, Jan 26, 7:53 PM
cc updated the test plan for D54896: tcp: report MSS correctly that subtracts TCP option length.
Mon, Jan 26, 5:15 PM
cc requested review of D54896: tcp: report MSS correctly that subtracts TCP option length.
Mon, Jan 26, 5:10 PM

Fri, Jan 23

cc abandoned D47213: cc_cubic: use newreno to emulate AIMD in TCP-friendly region.

Does not seem to be needed as the abandon reason is in https://reviews.freebsd.org/D47218#1253529.

Fri, Jan 23, 1:53 PM
cc added a comment to D47218: tcp cc: re-organize newreno functions into parts that can be re-used.
In D47218#1253522, @rrs wrote:

What other CC modules are you contemplating using this for?

My one comment on the change is that now you will always be setting something into the cwnd.. the old code only
did it when there was a change. Have not looked at the cache line layout of the data, I suspect it makes no difference
since you probably have the cwnd in cache anyway :)

Fri, Jan 23, 1:50 PM

Jan 18 2026

cc abandoned D47218: tcp cc: re-organize newreno functions into parts that can be re-used.

Does not seem to be needed.

Jan 18 2026, 9:47 PM

Dec 4 2025

cc accepted D54072: tcp: retire do_newsack - always adhere to RFC6675.
Dec 4 2025, 10:18 PM

Oct 30 2025

cc accepted D53104: tcp: Enable symmetric hashing by setting hash on outgoing conns.
Oct 30 2025, 5:45 PM
cc requested changes to D53104: tcp: Enable symmetric hashing by setting hash on outgoing conns.
Oct 30 2025, 4:11 PM

Oct 24 2025

cc added a comment to D53104: tcp: Enable symmetric hashing by setting hash on outgoing conns.

ok, so this looks fine, but I'm trying to remember where I used to assign the flowid/flowtype for a connection back in the day. On the mbuf side it used to be done in the driver side and then overriden by the network stack input path if it didn't match what was required (eg the magic required in ip reassembly, which is still there, but also to support completely software flow hashing.)

(remember way WAY back in the day the flowid/flowtype was also used by kip's flowdirector stuff for doing more explicit control over where flows went, and RSS just 'also' used it.)

Oct 24 2025, 1:29 PM

Oct 2 2025

cc added a comment to D52871: tcp: bump max rcv buffer size for autoscaling.

For reference, the Linux kernel recently changed it from 6MB to 32MB.

Oct 2 2025, 10:18 PM
cc accepted D52872: tcp: bump max snd buffer size for autoscaling.
Oct 2 2025, 7:52 PM

Sep 30 2025

cc accepted D52754: tcp: apply rate limits to challenge ACKs.
Sep 30 2025, 6:29 PM
cc added inline comments to D52754: tcp: apply rate limits to challenge ACKs.
Sep 30 2025, 1:34 PM

Sep 25 2025

cc accepted D52717: tcp: refactor tcp_send_challenge_ack().
Sep 25 2025, 1:31 PM

Sep 15 2025

cc accepted D52547: tcp: improve compilation of cc and their helper modules.
Sep 15 2025, 10:49 PM

Sep 4 2025

cc accepted D52383: tcp: add gone_in note for net.inet.tcp.sack.revised for fbsd16.
Sep 4 2025, 6:58 PM

Aug 29 2025

cc accepted D52225: tcp: improve sending of SYN-cookies.

Looks good to me. I only have two minor suggestions.

Aug 29 2025, 2:43 PM

Aug 13 2025

cc accepted D51884: systat: improve reporting of UDP statistics.
Aug 13 2025, 1:43 PM

Aug 12 2025

cc accepted D51881: netstat: report undelivered multi and broadcast UDP packets correctly.
Aug 12 2025, 9:54 PM

Aug 11 2025

cc added a comment to D7986: Simplify cubic_ack_received.

@imp if I recall this was something we were looking at on my team at LLNW, if it were in Bugzilla I'd say "Close - OBE" is appropriate.

@cc since you've been working on CUBIC lately, the only thing possibly still relevant here is turning the first level if into the early returns.. it removes one level of indention which might help justify a couple other nearby style(9) fixes but it's not worth holding this review open.

Aug 11 2025, 6:05 PM · srcmgr

Aug 8 2025

cc accepted D51426: tcp: improve the condition for detecting duplicate ACKs.

Thanks for the following improvements:

Aug 8 2025, 9:35 PM

Aug 6 2025

cc added inline comments to D51426: tcp: improve the condition for detecting duplicate ACKs.
Aug 6 2025, 10:22 PM

Aug 5 2025

cc added a comment to D51725: tcp: ensure that SACK hole->rxmit never ends up left of the hole with LRD.

I am ok with this patch. But I want to be sure how snd_recover shrinks. Is it because tp->snd_recover = tp->snd_recover_prev in CC_RTO_ERR? But that shall not be in SACK recovery.

Aug 5 2025, 4:57 PM

Jul 21 2025

cc accepted D51437: tcp: remove trailing whitespaces.
Jul 21 2025, 7:13 PM

Jul 7 2025

cc accepted D51125: tcp: don't allow to connect a TCP/IPv6 endpoint in TIME WAIT state.

Other than the fd is not used in the test code, I am good with this change.

Jul 7 2025, 4:31 PM

Jun 30 2025

cc added a comment to D51090: tcp: remove an invalid KASSERT.

Thanks for the elaboration. Looks good to me now.

Jun 30 2025, 11:20 PM
cc accepted D51090: tcp: remove an invalid KASSERT.
Jun 30 2025, 11:20 PM
cc added a comment to D51090: tcp: remove an invalid KASSERT.

Looks I am missing the context. Given the fact that the socket is in TCPS_TIME_WAIT while switching to the default stack, was this assert a day one issue that was not test covered before? Or was this panic caused by recent changes?

Jun 30 2025, 2:10 PM

Jun 16 2025

cc accepted D50840: tcp: cleanup timer initialisations.
Jun 16 2025, 7:46 PM
cc committed rGa2f579635f67: cc_cubic: sync to the new specification of RFC9438 for TCP CUBIC. (authored by cc).
cc_cubic: sync to the new specification of RFC9438 for TCP CUBIC.
Jun 16 2025, 4:55 PM
cc closed D49540: cc_cubic: sync to the new specification of RFC9438 for TCP CUBIC..
Jun 16 2025, 4:55 PM
cc updated the test plan for D49540: cc_cubic: sync to the new specification of RFC9438 for TCP CUBIC..
Jun 16 2025, 4:33 PM

Jun 13 2025

cc accepted D50830: tcp: fix handling of TIME WAIT for local TCP connections.
Jun 13 2025, 1:01 PM
cc accepted D50829: udp: fix local blackholing.
Jun 13 2025, 1:01 PM
cc accepted D50828: tcp: fix local blackholing.
Jun 13 2025, 12:57 PM

Jun 11 2025

cc added inline comments to D50637: tcp: allow specifying a MSL for local communications.
Jun 11 2025, 9:22 PM

May 14 2025

cc updated the test plan for D49540: cc_cubic: sync to the new specification of RFC9438 for TCP CUBIC..
May 14 2025, 4:04 PM

May 1 2025

cc accepted D49922: tcp: improve KASSERT in limited retransmit.
May 1 2025, 3:29 PM
cc updated the test plan for D49540: cc_cubic: sync to the new specification of RFC9438 for TCP CUBIC..
May 1 2025, 1:04 PM
cc updated the test plan for D49540: cc_cubic: sync to the new specification of RFC9438 for TCP CUBIC..
May 1 2025, 12:53 PM

Apr 21 2025

cc accepted D49941: netstat: fix table header alignment for -x.
Apr 21 2025, 1:16 PM

Mar 27 2025

cc updated the summary of D49540: cc_cubic: sync to the new specification of RFC9438 for TCP CUBIC..
Mar 27 2025, 7:06 PM
cc updated the summary of D49540: cc_cubic: sync to the new specification of RFC9438 for TCP CUBIC..
Mar 27 2025, 7:04 PM
cc updated the test plan for D49540: cc_cubic: sync to the new specification of RFC9438 for TCP CUBIC..
Mar 27 2025, 5:24 PM
cc requested review of D49540: cc_cubic: sync to the new specification of RFC9438 for TCP CUBIC..
Mar 27 2025, 5:20 PM

Mar 20 2025

cc accepted D48652: tcp: revert rxtshift too on a spurious timeout (RTO).
Mar 20 2025, 8:17 PM
cc accepted D49414: tcp: fix detection of bad RTOs.

This is for the fast path fix. Just want to confirm with your that a second patch may be around to improve both of the fast and slow path?

Mar 20 2025, 3:43 PM

Mar 17 2025

cc closed D49247: tcp cc: use tcp_compute_pipe() for pipe in xx_post_recovery() directly.
Mar 17 2025, 1:03 PM
cc committed rGa8d2bccb87d0: tcp cc: use tcp_compute_pipe() for pipe in xx_post_recovery() directly (authored by cc).
tcp cc: use tcp_compute_pipe() for pipe in xx_post_recovery() directly
Mar 17 2025, 1:03 PM

Mar 5 2025

cc updated the test plan for D49247: tcp cc: use tcp_compute_pipe() for pipe in xx_post_recovery() directly.
Mar 5 2025, 4:47 PM
cc requested review of D49247: tcp cc: use tcp_compute_pipe() for pipe in xx_post_recovery() directly.
Mar 5 2025, 4:45 PM

Feb 28 2025

cc closed D49047: tcp: make inflight data (pipe) calculation consistent.
Feb 28 2025, 8:56 PM
cc committed rG67787d200488: tcp: make inflight data (pipe) calculation consistent (authored by cc).
tcp: make inflight data (pipe) calculation consistent
Feb 28 2025, 8:56 PM
cc added a comment to D49047: tcp: make inflight data (pipe) calculation consistent.

Didn't see any surprising regression from my test result for this patch:
testD49047

Feb 28 2025, 8:42 PM

Feb 21 2025

cc updated the diff for D49047: tcp: make inflight data (pipe) calculation consistent.

code update based on Richard's comments

Feb 21 2025, 8:53 PM
cc added inline comments to D49047: tcp: make inflight data (pipe) calculation consistent.
Feb 21 2025, 4:07 PM
cc updated the diff for D49047: tcp: make inflight data (pipe) calculation consistent.

re-base, add a missing part and update based on Richard's comment in the meeting

Feb 21 2025, 4:01 PM

Feb 20 2025

cc committed rG7f9ef5c75fd1: cc_cubic: remove redundant code (authored by cc).
cc_cubic: remove redundant code
Feb 20 2025, 4:01 PM
cc closed D49008: cc_cubic: remove redundant code.
Feb 20 2025, 4:01 PM
cc added inline comments to D49047: tcp: make inflight data (pipe) calculation consistent.
Feb 20 2025, 3:40 PM

Feb 19 2025

cc added a comment to D49047: tcp: make inflight data (pipe) calculation consistent.

Question: why does this function returns signed value? And why some of the sackhint counters are signed?

There are several calls to tcp_compute_pipe() that did not check the V_tcp_do_newsack: 2 in tcp_output and 1 in tcp_input. Their behavior will change with revised SACK turned off. Commit message should explain why this is okay.

Feb 19 2025, 11:22 PM

Feb 18 2025

cc requested review of D49047: tcp: make inflight data (pipe) calculation consistent.
Feb 18 2025, 6:13 PM

Feb 14 2025

cc updated the summary of D49008: cc_cubic: remove redundant code.
Feb 14 2025, 4:19 PM
cc requested review of D49008: cc_cubic: remove redundant code.
Feb 14 2025, 4:15 PM

Feb 12 2025

cc committed rG6156da866e7d: cc_cubic: remove redundant calls of tcp_fixed_maxseg() (authored by cc).
cc_cubic: remove redundant calls of tcp_fixed_maxseg()
Feb 12 2025, 10:50 PM
cc closed D48967: cc_cubic: remove redundant calls of tcp_fixed_maxseg().
Feb 12 2025, 10:50 PM
cc updated the summary of D48967: cc_cubic: remove redundant calls of tcp_fixed_maxseg().
Feb 12 2025, 4:50 PM
cc requested review of D48967: cc_cubic: remove redundant calls of tcp_fixed_maxseg().
Feb 12 2025, 4:43 PM