From nobody Wed Nov 27 00:29:05 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4XygKt0dsPz5fFxs; Wed, 27 Nov 2024 00:29:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4XygKs5H3fz4V6j; Wed, 27 Nov 2024 00:29:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1732667345; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AjgVEZ7g2UXHY84yGOwOKuu4+7PDEjYh32lDpqm2QJ4=; b=OW4kELUdkvcJ0Np2ENDlgE6t9PW4Tm7zEhkm0lASlyg5VnRkQCsor0LnWLla/wiA2Lt6Im es8p2rIptPkS25fYkzxH5q8q11FWI3zMtHq53CHs+Uy36CJl5rCWSANkahAZmCCYrrcCYv yoUw1HsTiytSXaekG/6QFrtXJ8/9HzZGy/IVQfgaNmAqos8QKM/g46qH/S6lG5Lyt0MNyv Slk58gItJNL6fJheImA4kFOL++GwJ5xfQxB2nN+BknR/jRgm1ZY33Xo5YKrlfDF+ZLkHVj Ui1SON6B2yBfOcv1hFOHA7SYCRdaN9bXyT8FWm4ihMBC11hF7PsHAPUHVTmahg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1732667345; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AjgVEZ7g2UXHY84yGOwOKuu4+7PDEjYh32lDpqm2QJ4=; b=iTqhZLJQZ22EwOzlv9xKn55ZLy3lcVwFP+clL26Ml3EOAaaLH+S17auJUFfw2d5n1W5D23 wmCLEdItPyZ4sE2aY7116PPC42RFG/m6te4MqnIk2cWIndVZGuvmg8A4F1y+Vz/BlaWDZB H7zkrNP9i4dE0oW1BKkCp+4l/xeDK0vIgABm4V4LB5ktQ4kG8Lpj4AdBYLTGjSE9M1PK5e ikgHftaP9eBcrDZJ04mgAuikLWa7BpSVgQMSr00ZFgtGeLvenoiZSvlzywoP8qsgkhMDUR SAP6bInjovy3nDkZuyaSVewpAy1RqzzvEOk5cYVsBSqZGIrWAs439E01r9/X/w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1732667345; a=rsa-sha256; cv=none; b=F5i1YJrQQWBoSq0aZoK+8I3LIsuPfKcg2uUV5SgueXUsvjj3wdaKw3FB3OQGMf4/4D+Pfz nmyrJxppuqZN3xmzV7As4umyOsty9bYlvfPLEQ8QPAptC86h+YMu5A17Qj0YU4TJZAVVWp MXqM6hxVYq8xv08lnT/3IZxPnwQjZKCWlsCbrSrT2et1bBkhS3m+jU+IlKiDMmT4CEU1po QIvjvMpfp0v+RZ8Y01aXOu2K9JVcwUubjHKMfR05DHQ2whZkFT6IZgW3LHLuBBoiDRqgoB 2udezBXXL7iR5njwqsOk811I8n4CwZBiLrvH0DN5W2LGjiwjinp6inMYIs2Fpg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4XygKs4vBkznDS; Wed, 27 Nov 2024 00:29:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 4AR0T515063973; Wed, 27 Nov 2024 00:29:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4AR0T5UI063970; Wed, 27 Nov 2024 00:29:05 GMT (envelope-from git) Date: Wed, 27 Nov 2024 00:29:05 GMT Message-Id: <202411270029.4AR0T5UI063970@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kevin Bowling Subject: git: cb9c9b0c35a0 - stable/14 - igc: Style pass igc_txrx List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kbowling X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: cb9c9b0c35a03915d235dfd4d1232db857a267ae Auto-Submitted: auto-generated The branch stable/14 has been updated by kbowling: URL: https://cgit.FreeBSD.org/src/commit/?id=cb9c9b0c35a03915d235dfd4d1232db857a267ae commit cb9c9b0c35a03915d235dfd4d1232db857a267ae Author: Kevin Bowling AuthorDate: 2024-11-24 07:27:12 +0000 Commit: Kevin Bowling CommitDate: 2024-11-27 00:28:21 +0000 igc: Style pass igc_txrx Fix up indentation and reflow long lines. Sponsored by: BBOX.io (cherry picked from commit c7fb7b5d9fcd1fc67794228820aa54df388d47b4) --- sys/dev/igc/igc_txrx.c | 45 +++++++++++++++++++++++++++------------------ 1 file changed, 27 insertions(+), 18 deletions(-) diff --git a/sys/dev/igc/igc_txrx.c b/sys/dev/igc/igc_txrx.c index 59f4725388ee..92ba81c79c58 100644 --- a/sys/dev/igc/igc_txrx.c +++ b/sys/dev/igc/igc_txrx.c @@ -97,15 +97,19 @@ igc_dump_rs(struct igc_softc *sc) cur = txr->tx_rsq[rs_cidx]; status = txr->tx_base[cur].upper.fields.status; if (!(status & IGC_TXD_STAT_DD)) - printf("qid[%d]->tx_rsq[%d]: %d clear ", qid, rs_cidx, cur); + printf("qid[%d]->tx_rsq[%d]: %d clear ", + qid, rs_cidx, cur); } else { rs_cidx = (rs_cidx-1)&(ntxd-1); cur = txr->tx_rsq[rs_cidx]; - printf("qid[%d]->tx_rsq[rs_cidx-1=%d]: %d ", qid, rs_cidx, cur); + printf("qid[%d]->tx_rsq[rs_cidx-1=%d]: %d ", + qid, rs_cidx, cur); } - printf("cidx_prev=%d rs_pidx=%d ",txr->tx_cidx_processed, txr->tx_rs_pidx); + printf("cidx_prev=%d rs_pidx=%d ",txr->tx_cidx_processed, + txr->tx_rs_pidx); for (i = 0; i < ntxd; i++) { - if (txr->tx_base[i].upper.fields.status & IGC_TXD_STAT_DD) + if (txr->tx_base[i].upper.fields.status & + IGC_TXD_STAT_DD) printf("%d set ", i); } printf("\n"); @@ -138,14 +142,15 @@ igc_tso_setup(struct tx_ring *txr, if_pkt_info_t pi, uint32_t *cmd_type_len, break; default: panic("%s: CSUM_TSO but no supported IP version (0x%04x)", - __func__, ntohs(pi->ipi_etype)); + __func__, ntohs(pi->ipi_etype)); break; } TXD = (struct igc_adv_tx_context_desc *) &txr->tx_base[pi->ipi_pidx]; /* This is used in the transmit desc in encap */ - paylen = pi->ipi_len - pi->ipi_ehdrlen - pi->ipi_ip_hlen - pi->ipi_tcp_hlen; + paylen = pi->ipi_len - pi->ipi_ehdrlen - pi->ipi_ip_hlen - + pi->ipi_tcp_hlen; /* VLAN MACLEN IPLEN */ if (pi->ipi_mflags & M_VLANTAG) { @@ -180,8 +185,8 @@ igc_tso_setup(struct tx_ring *txr, if_pkt_info_t pi, uint32_t *cmd_type_len, * **********************************************************************/ static int -igc_tx_ctx_setup(struct tx_ring *txr, if_pkt_info_t pi, uint32_t *cmd_type_len, - uint32_t *olinfo_status) +igc_tx_ctx_setup(struct tx_ring *txr, if_pkt_info_t pi, + uint32_t *cmd_type_len, uint32_t *olinfo_status) { struct igc_adv_tx_context_desc *TXD; uint32_t vlan_macip_lens, type_tucmd_mlhl; @@ -275,7 +280,7 @@ igc_isc_txd_encap(void *arg, if_pkt_info_t pi) pidx_last = olinfo_status = 0; /* Basic descriptor defines */ cmd_type_len = (IGC_ADVTXD_DTYP_DATA | - IGC_ADVTXD_DCMD_IFCS | IGC_ADVTXD_DCMD_DEXT); + IGC_ADVTXD_DCMD_IFCS | IGC_ADVTXD_DCMD_DEXT); if (pi->ipi_mflags & M_VLANTAG) cmd_type_len |= IGC_ADVTXD_DCMD_VLE; @@ -324,9 +329,9 @@ igc_isc_txd_encap(void *arg, if_pkt_info_t pi) static void igc_isc_txd_flush(void *arg, uint16_t txqid, qidx_t pidx) { - struct igc_softc *sc = arg; - struct igc_tx_queue *que = &sc->tx_queues[txqid]; - struct tx_ring *txr = &que->txr; + struct igc_softc *sc = arg; + struct igc_tx_queue *que = &sc->tx_queues[txqid]; + struct tx_ring *txr = &que->txr; IGC_WRITE_REG(&sc->hw, IGC_TDT(txr->me), pidx); } @@ -370,12 +375,13 @@ igc_isc_txd_credits_update(void *arg, uint16_t txqid, bool clear) MPASS(delta > 0); processed += delta; - prev = cur; + prev = cur; rs_cidx = (rs_cidx + 1) & (ntxd-1); - if (rs_cidx == txr->tx_rs_pidx) + if (rs_cidx == txr->tx_rs_pidx) break; cur = txr->tx_rsq[rs_cidx]; - status = ((union igc_adv_tx_desc *)&txr->tx_base[cur])->wb.status; + status = + ((union igc_adv_tx_desc *)&txr->tx_base[cur])->wb.status; } while ((status & IGC_TXD_STAT_DD)); txr->tx_rs_cidx = rs_cidx; @@ -411,7 +417,8 @@ igc_isc_rxd_refill(void *arg, if_rxd_update_t iru) } static void -igc_isc_rxd_flush(void *arg, uint16_t rxqid, uint8_t flid __unused, qidx_t pidx) +igc_isc_rxd_flush(void *arg, uint16_t rxqid, uint8_t flid __unused, + qidx_t pidx) { struct igc_softc *sc = arg; struct igc_rx_queue *que = &sc->rx_queues[rxqid]; @@ -477,7 +484,8 @@ igc_isc_rxd_pkt_get(void *arg, if_rxd_info_t ri) MPASS ((staterr & IGC_RXD_STAT_DD) != 0); len = le16toh(rxd->wb.upper.length); - ptype = le32toh(rxd->wb.lower.lo_dword.data) & IGC_PKTTYPE_MASK; + ptype = + le32toh(rxd->wb.lower.lo_dword.data) & IGC_PKTTYPE_MASK; ri->iri_len += len; rxr->rx_bytes += ri->iri_len; @@ -558,7 +566,8 @@ igc_rx_checksum(uint32_t staterr, if_rxd_info_t ri, uint32_t ptype) (ptype & IGC_RXDADV_PKTTYPE_SCTP) != 0)) { ri->iri_csum_flags |= CSUM_SCTP_VALID; } else { - ri->iri_csum_flags |= CSUM_DATA_VALID | CSUM_PSEUDO_HDR; + ri->iri_csum_flags |= + CSUM_DATA_VALID | CSUM_PSEUDO_HDR; ri->iri_csum_data = htons(0xffff); } }