Date: Wed, 17 Jul 2024 14:21:36 GMT From: Navdeep Parhar <np@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: git: 1089f5755e11 - stable/14 - cxgbe(4): Remove tx_modq lookup table. Message-ID: <202407171421.46HELaIi026767@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch stable/14 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=1089f5755e1131ad13adea0d2c7ac17be024c494 commit 1089f5755e1131ad13adea0d2c7ac17be024c494 Author: Navdeep Parhar <np@FreeBSD.org> AuthorDate: 2024-03-29 05:49:32 +0000 Commit: Navdeep Parhar <np@FreeBSD.org> CommitDate: 2024-07-17 06:27:14 +0000 cxgbe(4): Remove tx_modq lookup table. The driver always uses the same modulation queue as the channel and the table is unnecessary. Sponsored by: Chelsio Communications (cherry picked from commit f76effed14b25bfa0c47b10f6d8a076104c48d94) --- sys/dev/cxgbe/common/common.h | 4 +++- sys/dev/cxgbe/common/t4_hw.c | 5 ----- sys/dev/cxgbe/crypto/t6_kern_tls.c | 4 ++-- sys/dev/cxgbe/tom/t4_tom.c | 2 +- 4 files changed, 6 insertions(+), 9 deletions(-) diff --git a/sys/dev/cxgbe/common/common.h b/sys/dev/cxgbe/common/common.h index 0871ca8c40f1..634474470e17 100644 --- a/sys/dev/cxgbe/common/common.h +++ b/sys/dev/cxgbe/common/common.h @@ -252,7 +252,6 @@ struct tp_params { unsigned int tre; /* log2 of core clocks per TP tick */ unsigned int dack_re; /* DACK timer resolution */ unsigned int la_mask; /* what events are recorded by TP LA */ - unsigned short tx_modq[MAX_NCHAN]; /* channel to modulation queue map */ uint16_t filter_mode; uint16_t filter_mask; /* Used by TOE and hashfilters */ @@ -273,6 +272,9 @@ struct tp_params { int8_t frag_shift; }; +/* Use same modulation queue as the tx channel. */ +#define TX_MODQ(tx_chan) (tx_chan) + struct vpd_params { unsigned int cclk; u8 ec[EC_LEN + 1]; diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index c428fd2720cd..30dedd91262c 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -9800,7 +9800,6 @@ read_filter_mode_and_ingress_config(struct adapter *adap) */ int t4_init_tp_params(struct adapter *adap) { - int chan; u32 tx_len, rx_len, r, v; struct tp_params *tpp = &adap->params.tp; @@ -9808,10 +9807,6 @@ int t4_init_tp_params(struct adapter *adap) tpp->tre = G_TIMERRESOLUTION(v); tpp->dack_re = G_DELAYEDACKRESOLUTION(v); - /* MODQ_REQ_MAP defaults to setting queues 0-3 to chan 0-3 */ - for (chan = 0; chan < MAX_NCHAN; chan++) - tpp->tx_modq[chan] = chan; - read_filter_mode_and_ingress_config(adap); if (chip_id(adap) > CHELSIO_T5) { diff --git a/sys/dev/cxgbe/crypto/t6_kern_tls.c b/sys/dev/cxgbe/crypto/t6_kern_tls.c index 6b684c952647..2173cb670874 100644 --- a/sys/dev/cxgbe/crypto/t6_kern_tls.c +++ b/sys/dev/cxgbe/crypto/t6_kern_tls.c @@ -171,7 +171,7 @@ mk_ktls_act_open_req(struct adapter *sc, struct vi_info *vi, struct inpcb *inp, options |= F_NON_OFFLOAD; cpl->opt0 = htobe64(options); - options = V_TX_QUEUE(sc->params.tp.tx_modq[vi->pi->tx_chan]); + options = V_TX_QUEUE(TX_MODQ(vi->pi->tx_chan)); if (tp->t_flags & TF_REQ_TSTMP) options |= F_TSTAMPS_EN; cpl->opt2 = htobe32(options); @@ -206,7 +206,7 @@ mk_ktls_act_open_req6(struct adapter *sc, struct vi_info *vi, options |= F_NON_OFFLOAD; cpl->opt0 = htobe64(options); - options = V_TX_QUEUE(sc->params.tp.tx_modq[vi->pi->tx_chan]); + options = V_TX_QUEUE(TX_MODQ(vi->pi->tx_chan)); if (tp->t_flags & TF_REQ_TSTMP) options |= F_TSTAMPS_EN; cpl->opt2 = htobe32(options); diff --git a/sys/dev/cxgbe/tom/t4_tom.c b/sys/dev/cxgbe/tom/t4_tom.c index 4d4400512ef5..b2d0b85e4832 100644 --- a/sys/dev/cxgbe/tom/t4_tom.c +++ b/sys/dev/cxgbe/tom/t4_tom.c @@ -1202,7 +1202,7 @@ calc_options2(struct vi_info *vi, struct conn_params *cp) /* XXX: F_RX_CHANNEL for multiple rx c-chan support goes here. */ - opt2 |= V_TX_QUEUE(sc->params.tp.tx_modq[pi->tx_chan]); + opt2 |= V_TX_QUEUE(TX_MODQ(pi->tx_chan)); opt2 |= V_PACE(0); opt2 |= F_RSS_QUEUE_VALID; opt2 |= V_RSS_QUEUE(sc->sge.ofld_rxq[cp->rxq_idx].iq.abs_id);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202407171421.46HELaIi026767>