Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 20 Nov 2025 15:52:43 +0100
From:      Kristof Provost <kp@FreeBSD.org>
To:        Navdeep Parhar <np@FreeBSD.org>
Cc:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   Re: git: 17b4a0acfaf5 - main - cxgbe(4): T7 related updates  to shared code
Message-ID:  <0DA16B91-A32E-443D-8FF3-45183117ABB6@FreeBSD.org>
In-Reply-To: <202511130041.5AD0fYXA077222@gitrepo.freebsd.org>
References:  <202511130041.5AD0fYXA077222@gitrepo.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help

[-- Attachment #1 --]


On 13 Nov 2025, at 1:41, Navdeep Parhar wrote:

> The branch main has been updated by np:
>
> URL: 
> https://cgit.FreeBSD.org/src/commit/?id=17b4a0acfaf5e58a04232c756a79d73649ead231
>
> commit 17b4a0acfaf5e58a04232c756a79d73649ead231
> Author:     Navdeep Parhar <np@FreeBSD.org>
> AuthorDate: 2025-10-15 19:29:06 +0000
> Commit:     Navdeep Parhar <np@FreeBSD.org>
> CommitDate: 2025-11-13 00:32:38 +0000
>
>     cxgbe(4): T7 related updates to shared code
>
>     - Avoid some more registers with read side-effects during regdump.
>     - mps_tcam_size is 3x the size of T6/T5.
>     - Update rss_rd_row to work with T7.
>
>     Obtained from:  Chelsio Communications
>     MFC after:      1 week
>     Sponsored by:   Chelsio Communications
> ---
>  sys/dev/cxgbe/common/t4_hw.c     |  98 +++++--
>  sys/dev/cxgbe/common/t4_msg.h    | 566 
> +++++++++++++++++++++++++++++++++------
>  sys/dev/cxgbe/common/t4_regs.h   | 100 ++++++-
>  sys/dev/cxgbe/tom/t4_cpl_io.c    |   2 +-
>  usr.sbin/cxgbetool/reg_defs_t7.c | 126 +++++----
>  5 files changed, 723 insertions(+), 169 deletions(-)
>
…
> +struct cpl_rx_phys_addr {
> +        __be32 RSS[2];
> +        __be32 op_to_tid;
> +        __be32 pci_rlx_order_to_len;
> +        __be64 phys_addr;
> +};
This fails to build on ‘options RSS’ kernels (which does `#define 
RSS 1`):

	--- t4_main.o ---
	In file included from /usr/src/sys/dev/cxgbe/t4_main.c:79:
	In file included from /usr/src/sys/dev/cxgbe/common/common.h:525:
	In file included from /usr/src/sys/dev/cxgbe/adapter.h:62:
	/usr/src/sys/dev/cxgbe/common/t4_msg.h:2481:16: error: expected member 
name or ';' after declaration specifiers
	 2481 |         __be32 RSS[2];
	      |         ~~~~~~ ^
	./opt_rss.h:1:13: note: expanded from macro 'RSS'
	    1 | #define RSS 1
	      |             ^
	In file included from /usr/src/sys/dev/cxgbe/t4_main.c:79:
	In file included from /usr/src/sys/dev/cxgbe/common/common.h:525:
	In file included from /usr/src/sys/dev/cxgbe/adapter.h:62:
	/usr/src/sys/dev/cxgbe/common/t4_msg.h:2481:15: error: expected ';' at 
end of declaration list
	 2481 |         __be32 RSS[2];
	      |               ^
	      |               ;
	2 errors generated.
	*** [t4_main.o] Error code 1

Something simple like this appears to be enough to fix that:

	diff --git a/sys/dev/cxgbe/common/t4_msg.h 
b/sys/dev/cxgbe/common/t4_msg.h
	index 214080964fbb..19a9af25ca5d 100644
	--- a/sys/dev/cxgbe/common/t4_msg.h
	+++ b/sys/dev/cxgbe/common/t4_msg.h
	@@ -2478,7 +2478,7 @@ struct cpl_rx_data_ack_core {
	 #define F_RX_DACK_CHANGE    V_RX_DACK_CHANGE(1U)

	 struct cpl_rx_phys_addr {
	-        __be32 RSS[2];
	+        __be32 rssid[2];
	         __be32 op_to_tid;
	         __be32 pci_rlx_order_to_len;
	         __be64 phys_addr;

Best regards,
Kristof
[-- Attachment #2 --]
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/xhtml; charset=utf-8">
</head>
<body><div style="font-family: sans-serif;"><div class="markdown" style="white-space: normal;">
<p dir="auto">On 13 Nov 2025, at 1:41, Navdeep Parhar wrote:</p>
</div><div class="plaintext" style="white-space: normal;"><blockquote style="margin: 0 0 5px; padding-left: 5px; border-left: 2px solid #136BCE; color: #136BCE;"><p dir="auto">The branch main has been updated by np:</p>
<p dir="auto">URL: <a href="https://cgit.FreeBSD.org/src/commit/?id=17b4a0acfaf5e58a04232c756a79d73649ead231">https://cgit.FreeBSD.org/src/commit/?id=17b4a0acfaf5e58a04232c756a79d73649ead231</a></p>;
<p dir="auto">commit 17b4a0acfaf5e58a04232c756a79d73649ead231
<br>
Author:     Navdeep Parhar &lt;np@FreeBSD.org&gt;
<br>
AuthorDate: 2025-10-15 19:29:06 +0000
<br>
Commit:     Navdeep Parhar &lt;np@FreeBSD.org&gt;
<br>
CommitDate: 2025-11-13 00:32:38 +0000</p>
<p dir="auto">    cxgbe(4): T7 related updates to shared code</p>
<p dir="auto">    - Avoid some more registers with read side-effects during regdump.
<br>
    - mps_tcam_size is 3x the size of T6/T5.
<br>
    - Update rss_rd_row to work with T7.</p>
<p dir="auto">    Obtained from:  Chelsio Communications
<br>
    MFC after:      1 week
<br>
    Sponsored by:   Chelsio Communications
<br>
---
<br>
 sys/dev/cxgbe/common/t4_hw.c     |  98 +++++--
<br>
 sys/dev/cxgbe/common/t4_msg.h    | 566 +++++++++++++++++++++++++++++++++------
<br>
 sys/dev/cxgbe/common/t4_regs.h   | 100 ++++++-
<br>
 sys/dev/cxgbe/tom/t4_cpl_io.c    |   2 +-
<br>
 usr.sbin/cxgbetool/reg_defs_t7.c | 126 +++++----
<br>
 5 files changed, 723 insertions(+), 169 deletions(-)</p>
<br></blockquote></div>
<div class="markdown" style="white-space: normal;">
<p dir="auto">…</p>
</div><div class="plaintext" style="white-space: normal;"><blockquote style="margin: 0 0 5px; padding-left: 5px; border-left: 2px solid #136BCE; color: #136BCE;"><p dir="auto">+struct cpl_rx_phys_addr {
<br>
+        __be32 RSS[2];
<br>
+        __be32 op_to_tid;
<br>
+        __be32 pci_rlx_order_to_len;
<br>
+        __be64 phys_addr;
<br>
+};</p>
</blockquote></div>
<div class="markdown" style="white-space: normal;">
<p dir="auto">This fails to build on ‘options RSS’ kernels (which does <code style="padding: 0 0.25em; background-color: #E4E4E4;">#define RSS 1</code>):</p>
<pre style="margin-left: 15px; margin-right: 15px; padding: 5px; border: thin solid gray; overflow-x: auto; max-width: 90vw; background-color: #E4E4E4;"><code style="padding: 0 0.25em; background-color: #E4E4E4;">--- t4_main.o ---
In file included from /usr/src/sys/dev/cxgbe/t4_main.c:79:
In file included from /usr/src/sys/dev/cxgbe/common/common.h:525:
In file included from /usr/src/sys/dev/cxgbe/adapter.h:62:
/usr/src/sys/dev/cxgbe/common/t4_msg.h:2481:16: error: expected member name or ';' after declaration specifiers
 2481 |         __be32 RSS[2];
      |         ~~~~~~ ^
./opt_rss.h:1:13: note: expanded from macro 'RSS'
    1 | #define RSS 1
      |             ^
In file included from /usr/src/sys/dev/cxgbe/t4_main.c:79:
In file included from /usr/src/sys/dev/cxgbe/common/common.h:525:
In file included from /usr/src/sys/dev/cxgbe/adapter.h:62:
/usr/src/sys/dev/cxgbe/common/t4_msg.h:2481:15: error: expected ';' at end of declaration list
 2481 |         __be32 RSS[2];
      |               ^
      |               ;
2 errors generated.
*** [t4_main.o] Error code 1
</code></pre>
<p dir="auto">Something simple like this appears to be enough to fix that:</p>
<pre style="margin-left: 15px; margin-right: 15px; padding: 5px; border: thin solid gray; overflow-x: auto; max-width: 90vw; background-color: #E4E4E4;"><code style="padding: 0 0.25em; background-color: #E4E4E4;">diff --git a/sys/dev/cxgbe/common/t4_msg.h b/sys/dev/cxgbe/common/t4_msg.h
index 214080964fbb..19a9af25ca5d 100644
--- a/sys/dev/cxgbe/common/t4_msg.h
+++ b/sys/dev/cxgbe/common/t4_msg.h
@@ -2478,7 +2478,7 @@ struct cpl_rx_data_ack_core {
 #define F_RX_DACK_CHANGE    V_RX_DACK_CHANGE(1U)

 struct cpl_rx_phys_addr {
-        __be32 RSS[2];
+        __be32 rssid[2];
         __be32 op_to_tid;
         __be32 pci_rlx_order_to_len;
         __be64 phys_addr;
</code></pre>
<p dir="auto">Best regards,<br>
Kristof</p>

</div>
</div>
</body>

</html>

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?0DA16B91-A32E-443D-8FF3-45183117ABB6>