From: Mika Westerberg <mika.westerberg@linux.intel.com>
To: linux-usb@vger.kernel.org
Cc: Yehezkel Bernat <YehezkelShB@gmail.com>,
Lukas Wunner <lukas@wunner.de>,
Andreas Noever <andreas.noever@gmail.com>,
Gil Fine <gil.fine@linux.intel.com>,
Rene Sapiens <rene.sapiens@linux.intel.com>,
Pooja Katiyar <pooja.katiyar@intel.com>,
Mika Westerberg <mika.westerberg@linux.intel.com>
Subject: [PATCH 18/18] thunderbolt: Add KUnit tests for shared buffering
Date: Thu, 19 Nov 2026 18:12:32 +0100 [thread overview]
Message-ID: <20261119171232.1616316-19-mika.westerberg@linux.intel.com> (raw)
In-Reply-To: <20261119171232.1616316-1-mika.westerberg@linux.intel.com>
From: "Mika Westerberg (Intel)" <westeri@kernel.org>
This adds various test cases to check the shared buffering support.
While there, check the per-hop flow control settings in the existing
credit allocation and tunnel test cases too. Egress flow control
follows the ingress flow control of the next hop except on the last hop
where it depends on the protocol, so make sure that is covered as well.
Signed-off-by: Mika Westerberg (Intel) <westeri@kernel.org>
---
drivers/thunderbolt/test.c | 598 +++++++++++++++++++++++++++++++++++++
1 file changed, 598 insertions(+)
diff --git a/drivers/thunderbolt/test.c b/drivers/thunderbolt/test.c
index d6679bcc4ac3..3fa9c4661541 100644
--- a/drivers/thunderbolt/test.c
+++ b/drivers/thunderbolt/test.c
@@ -1381,6 +1381,30 @@ static void tb_test_path_mixed_chain_reverse(struct kunit *test)
tb_path_free(path);
}
+static void tb_test_check_path_fc(struct kunit *test,
+ const struct tb_path *path, bool last_efc)
+{
+ int i;
+
+ for (i = 0; i < path->path_length; i++) {
+ bool efc = i < path->path_length - 1 ? true : last_efc;
+
+ KUNIT_EXPECT_TRUE(test, path->hops[i].ingress_fc_enable);
+ KUNIT_EXPECT_EQ(test, path->hops[i].egress_fc_enable, efc);
+ }
+}
+
+static void tb_test_check_path_nfc(struct kunit *test,
+ const struct tb_path *path)
+{
+ int i;
+
+ for (i = 0; i < path->path_length; i++) {
+ KUNIT_EXPECT_FALSE(test, path->hops[i].ingress_fc_enable);
+ KUNIT_EXPECT_FALSE(test, path->hops[i].egress_fc_enable);
+ }
+}
+
static void tb_test_tunnel_pcie(struct kunit *test)
{
struct tb_switch *host, *dev1, *dev2;
@@ -1523,6 +1547,10 @@ static void tb_test_tunnel_dp_chain(struct kunit *test)
KUNIT_ASSERT_EQ(test, tunnel->paths[2]->path_length, 3);
KUNIT_EXPECT_PTR_EQ(test, tunnel->paths[2]->hops[0].in_port, out);
KUNIT_EXPECT_PTR_EQ(test, tunnel->paths[2]->hops[2].out_port, in);
+ tb_test_check_path_nfc(test, tunnel->paths[0]);
+ tb_test_check_path_fc(test, tunnel->paths[1], false);
+ tb_test_check_path_fc(test, tunnel->paths[2], false);
+
tb_tunnel_put(tunnel);
}
@@ -1655,6 +1683,10 @@ static void tb_test_tunnel_dp_max_length(struct kunit *test)
KUNIT_EXPECT_PTR_EQ(test, tunnel->paths[2]->hops[6].out_port,
&host->ports[1]);
KUNIT_EXPECT_PTR_EQ(test, tunnel->paths[2]->hops[12].out_port, in);
+ tb_test_check_path_nfc(test, tunnel->paths[0]);
+ tb_test_check_path_fc(test, tunnel->paths[1], false);
+ tb_test_check_path_fc(test, tunnel->paths[2], false);
+
tb_tunnel_put(tunnel);
}
@@ -1948,6 +1980,8 @@ static void tb_test_tunnel_dma_rx(struct kunit *test)
KUNIT_EXPECT_PTR_EQ(test, tunnel->paths[0]->hops[0].out_port, nhi);
KUNIT_EXPECT_EQ(test, tunnel->paths[0]->hops[0].next_hop_index, 2);
+ tb_test_check_path_fc(test, tunnel->paths[0], false);
+
tb_tunnel_put(tunnel);
}
@@ -1985,6 +2019,8 @@ static void tb_test_tunnel_dma_tx(struct kunit *test)
KUNIT_EXPECT_PTR_EQ(test, tunnel->paths[0]->hops[0].out_port, port);
KUNIT_EXPECT_EQ(test, tunnel->paths[0]->hops[0].next_hop_index, 15);
+ tb_test_check_path_fc(test, tunnel->paths[0], true);
+
tb_tunnel_put(tunnel);
}
@@ -2051,6 +2087,9 @@ static void tb_test_tunnel_dma_chain(struct kunit *test)
KUNIT_EXPECT_PTR_EQ(test, tunnel->paths[1]->hops[2].out_port, port);
KUNIT_EXPECT_EQ(test, tunnel->paths[1]->hops[2].next_hop_index, 8);
+ tb_test_check_path_fc(test, tunnel->paths[0], false);
+ tb_test_check_path_fc(test, tunnel->paths[1], true);
+
tb_tunnel_put(tunnel);
}
@@ -2123,6 +2162,7 @@ static void tb_test_credit_alloc_legacy_not_bonded(struct kunit *test)
path = tunnel->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2130,6 +2170,7 @@ static void tb_test_credit_alloc_legacy_not_bonded(struct kunit *test)
path = tunnel->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2156,6 +2197,7 @@ static void tb_test_credit_alloc_legacy_bonded(struct kunit *test)
path = tunnel->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2163,6 +2205,7 @@ static void tb_test_credit_alloc_legacy_bonded(struct kunit *test)
path = tunnel->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2192,6 +2235,7 @@ static void tb_test_credit_alloc_pcie(struct kunit *test)
path = tunnel->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2199,6 +2243,7 @@ static void tb_test_credit_alloc_pcie(struct kunit *test)
path = tunnel->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2409,6 +2454,7 @@ static void tb_test_credit_alloc_without_dp(struct kunit *test)
/* PCIe downstream path */
path = tunnel->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2417,6 +2463,7 @@ static void tb_test_credit_alloc_without_dp(struct kunit *test)
/* PCIe upstream path */
path = tunnel->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2452,6 +2499,7 @@ static void tb_test_credit_alloc_dp(struct kunit *test)
/* Video (main) path */
path = tunnel->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_nfc(test, path);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 18U);
@@ -2460,6 +2508,7 @@ static void tb_test_credit_alloc_dp(struct kunit *test)
/* AUX TX */
path = tunnel->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2468,6 +2517,7 @@ static void tb_test_credit_alloc_dp(struct kunit *test)
/* AUX RX */
path = tunnel->paths[2];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2500,6 +2550,7 @@ static void tb_test_credit_alloc_usb3(struct kunit *test)
path = tunnel->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2507,6 +2558,7 @@ static void tb_test_credit_alloc_usb3(struct kunit *test)
path = tunnel->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2597,6 +2649,7 @@ static void tb_test_credit_alloc_dma(struct kunit *test)
/* DMA RX */
path = tunnel->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 14U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2605,6 +2658,7 @@ static void tb_test_credit_alloc_dma(struct kunit *test)
/* DMA TX */
path = tunnel->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, true);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2664,6 +2718,7 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
path = tunnel1->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 14U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2671,6 +2726,7 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
path = tunnel1->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, true);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2682,6 +2738,7 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
path = tunnel2->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 14U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2689,6 +2746,7 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
path = tunnel2->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, true);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2700,6 +2758,7 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
path = tunnel3->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 14U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2707,6 +2766,7 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
path = tunnel3->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, true);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2718,6 +2778,7 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
path = tunnel4->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 4U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2725,6 +2786,7 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
path = tunnel4->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, true);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2736,6 +2798,7 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
path = tunnel5->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 1U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2743,6 +2806,7 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
path = tunnel5->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, true);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2759,6 +2823,7 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
path = tunnel6->paths[0];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, false);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 14U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2766,6 +2831,7 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
path = tunnel6->paths[1];
KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_path_fc(test, path, true);
KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U);
KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U);
@@ -2781,6 +2847,531 @@ static void tb_test_credit_alloc_dma_multiple(struct kunit *test)
usb4_switch_free_credit_pools(host);
}
+static void tb_switch_enable_shared_buffering(struct tb_switch *sw)
+{
+ struct tb_port *port;
+
+ tb_switch_for_each_port(sw, port) {
+ if (tb_port_is_null(port))
+ port->shared_buffering = true;
+ }
+}
+
+static void tb_switch_disable_shared_buffering(struct tb_switch *sw)
+{
+ struct tb_port *port;
+
+ tb_switch_for_each_port(sw, port)
+ port->shared_buffering = false;
+}
+
+static void tb_test_check_hop(struct kunit *test, const struct tb_path_hop *hop,
+ unsigned int initial_credits, bool ingress_shared,
+ bool egress_shared)
+{
+ KUNIT_EXPECT_EQ(test, hop->nfc_credits, 0U);
+ KUNIT_EXPECT_EQ(test, hop->initial_credits, initial_credits);
+ KUNIT_EXPECT_EQ(test, hop->ingress_shared_buffer, ingress_shared);
+ KUNIT_EXPECT_EQ(test, hop->egress_shared_buffer, egress_shared);
+}
+
+static void tb_test_check_shared(struct kunit *test, const struct tb_port *port,
+ unsigned int shared_credits,
+ unsigned int shared_users)
+{
+ KUNIT_EXPECT_EQ(test, port->shared_credits, shared_credits);
+ KUNIT_EXPECT_EQ(test, port->shared_users, shared_users);
+}
+
+static void tb_test_check_dma_tunnel(struct kunit *test,
+ const struct tb_tunnel *tunnel,
+ unsigned int ingress_dev,
+ unsigned int ingress_host,
+ unsigned int egress_dev, bool shared)
+{
+ const struct tb_path *path;
+
+ KUNIT_ASSERT_NOT_NULL(test, tunnel);
+ KUNIT_ASSERT_EQ(test, tunnel->npaths, (size_t)2);
+
+ /* DMA RX */
+ path = tunnel->paths[0];
+ KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_hop(test, &path->hops[0], ingress_dev, false, shared);
+ tb_test_check_hop(test, &path->hops[1], ingress_host, shared, false);
+ tb_test_check_path_fc(test, path, false);
+
+ /* DMA TX */
+ path = tunnel->paths[1];
+ KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_hop(test, &path->hops[0], 0, false, shared);
+ tb_test_check_hop(test, &path->hops[1], egress_dev, shared, false);
+ tb_test_check_path_fc(test, path, true);
+}
+
+static void tb_test_credit_alloc_dma_shared(struct kunit *test)
+{
+ struct tb_switch *host, *dev;
+ struct tb_port *nhi, *port;
+ struct tb_tunnel *tunnel;
+
+ host = alloc_host_usb4(test);
+ dev = alloc_dev_usb4(test, host, 0x1, true);
+
+ tb_switch_enable_shared_buffering(host);
+ tb_switch_enable_shared_buffering(dev);
+
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(host), 0);
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(dev), 0);
+
+ nhi = &host->ports[7];
+ port = &dev->ports[3];
+
+ /*
+ * The link between the host and the device uses shared
+ * buffering in both directions. The device ingress lane adapter
+ * (port 3) is not part of the link so it uses dedicated
+ * buffers.
+ */
+ tunnel = tb_tunnel_alloc_dma(NULL, nhi, port, 8, 1, 8, 1);
+ tb_test_check_dma_tunnel(test, tunnel, 14, 14, 14, true);
+
+ tb_test_check_shared(test, &host->ports[1], 14, 1);
+ tb_test_check_shared(test, &dev->ports[1], 14, 1);
+ tb_test_check_shared(test, &dev->ports[3], 0, 0);
+
+ tb_tunnel_put(tunnel);
+
+ tb_test_check_shared(test, &host->ports[1], 0, 0);
+ tb_test_check_shared(test, &dev->ports[1], 0, 0);
+
+ usb4_switch_free_credit_pools(dev);
+ usb4_switch_free_credit_pools(host);
+}
+
+static void tb_test_credit_alloc_dma_multiple_shared(struct kunit *test)
+{
+ struct tb_tunnel *tunnel1, *tunnel2, *tunnel3, *tunnel4;
+ struct tb_tunnel *tunnel5, *tunnel6;
+ struct tb_switch *host, *dev;
+ struct tb_port *nhi, *port;
+
+ host = alloc_host_br(test);
+ dev = alloc_dev_usb4(test, host, 0x1, true);
+
+ tb_switch_enable_shared_buffering(host);
+ tb_switch_enable_shared_buffering(dev);
+
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(host), 0);
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(dev), 0);
+
+ nhi = &host->ports[7];
+ port = &dev->ports[3];
+
+ /*
+ * Same as tb_test_credit_alloc_dma_multiple() but intra-domain
+ * links use shared buffering so they get the full credits. The
+ * dev ingress port (3) is still using dedicated for the
+ * inter-domain link (and runs out of credits the same way).
+ */
+ tunnel1 = tb_tunnel_alloc_dma(NULL, nhi, port, 8, 1, 8, 1);
+ tb_test_check_dma_tunnel(test, tunnel1, 14, 14, 14, true);
+ tunnel2 = tb_tunnel_alloc_dma(NULL, nhi, port, 9, 2, 9, 2);
+ tb_test_check_dma_tunnel(test, tunnel2, 14, 14, 14, true);
+ tunnel3 = tb_tunnel_alloc_dma(NULL, nhi, port, 10, 3, 10, 3);
+ tb_test_check_dma_tunnel(test, tunnel3, 14, 14, 14, true);
+ tunnel4 = tb_tunnel_alloc_dma(NULL, nhi, port, 11, 4, 11, 4);
+ tb_test_check_dma_tunnel(test, tunnel4, 4, 14, 14, true);
+ tunnel5 = tb_tunnel_alloc_dma(NULL, nhi, port, 12, 5, 12, 5);
+ tb_test_check_dma_tunnel(test, tunnel5, 1, 14, 14, true);
+
+ tb_test_check_shared(test, &host->ports[1], 14, 5);
+ tb_test_check_shared(test, &dev->ports[1], 14, 5);
+
+ /*
+ * This fails at the first hop of the RX path, before any of the
+ * shared buffers are allocated. Releasing the failed tunnel
+ * must not drop the users of the shared buffers.
+ */
+ tunnel6 = tb_tunnel_alloc_dma(NULL, nhi, port, 13, 6, 13, 6);
+ KUNIT_ASSERT_NULL(test, tunnel6);
+
+ tb_test_check_shared(test, &host->ports[1], 14, 5);
+ tb_test_check_shared(test, &dev->ports[1], 14, 5);
+
+ tb_tunnel_put(tunnel1);
+
+ tb_test_check_shared(test, &host->ports[1], 14, 4);
+ tb_test_check_shared(test, &dev->ports[1], 14, 4);
+
+ tunnel6 = tb_tunnel_alloc_dma(NULL, nhi, port, 13, 6, 13, 6);
+ tb_test_check_dma_tunnel(test, tunnel6, 14, 14, 14, true);
+
+ tb_test_check_shared(test, &host->ports[1], 14, 5);
+ tb_test_check_shared(test, &dev->ports[1], 14, 5);
+
+ tb_tunnel_put(tunnel6);
+ tb_tunnel_put(tunnel5);
+ tb_tunnel_put(tunnel4);
+ tb_tunnel_put(tunnel3);
+ tb_tunnel_put(tunnel2);
+
+ tb_test_check_shared(test, &host->ports[1], 0, 0);
+ tb_test_check_shared(test, &dev->ports[1], 0, 0);
+
+ /*
+ * All the shared buffers must have been returned to the common
+ * pool so with dedicated buffering we should get the same
+ * allocation as in tb_test_credit_alloc_dma_multiple().
+ */
+ tb_switch_disable_shared_buffering(host);
+ tb_switch_disable_shared_buffering(dev);
+
+ tunnel1 = tb_tunnel_alloc_dma(NULL, nhi, port, 8, 1, 8, 1);
+ tb_test_check_dma_tunnel(test, tunnel1, 14, 14, 14, false);
+ tunnel2 = tb_tunnel_alloc_dma(NULL, nhi, port, 9, 2, 9, 2);
+ tb_test_check_dma_tunnel(test, tunnel2, 14, 14, 14, false);
+ tunnel3 = tb_tunnel_alloc_dma(NULL, nhi, port, 10, 3, 10, 3);
+ tb_test_check_dma_tunnel(test, tunnel3, 14, 14, 14, false);
+ tunnel4 = tb_tunnel_alloc_dma(NULL, nhi, port, 11, 4, 11, 4);
+ tb_test_check_dma_tunnel(test, tunnel4, 4, 14, 10, false);
+ tunnel5 = tb_tunnel_alloc_dma(NULL, nhi, port, 12, 5, 12, 5);
+ tb_test_check_dma_tunnel(test, tunnel5, 1, 14, 1, false);
+ tunnel6 = tb_tunnel_alloc_dma(NULL, nhi, port, 13, 6, 13, 6);
+ KUNIT_ASSERT_NULL(test, tunnel6);
+
+ tb_tunnel_put(tunnel5);
+ tb_tunnel_put(tunnel4);
+ tb_tunnel_put(tunnel3);
+ tb_tunnel_put(tunnel2);
+ tb_tunnel_put(tunnel1);
+
+ usb4_switch_free_credit_pools(dev);
+ usb4_switch_free_credit_pools(host);
+}
+
+static void tb_test_credit_alloc_dma_shared_partial(struct kunit *test)
+{
+ struct tb_tunnel *tunnel1, *tunnel2, *tunnel3, *tunnel4;
+ struct tb_tunnel *tunnel5;
+ struct tb_switch *host, *dev;
+ struct tb_port *nhi, *port;
+
+ host = alloc_host_br(test);
+ dev = alloc_dev_usb4(test, host, 0x1, true);
+
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(host), 0);
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(dev), 0);
+
+ nhi = &host->ports[7];
+ port = &dev->ports[3];
+
+ /*
+ * First take most of the device upstream port common pool
+ * with dedicated buffers. This leaves 52 - 3 * 14 = 10 credits
+ * there.
+ */
+ tunnel1 = tb_tunnel_alloc_dma(NULL, nhi, port, 8, 1, 8, 1);
+ tb_test_check_dma_tunnel(test, tunnel1, 14, 14, 14, false);
+ tunnel2 = tb_tunnel_alloc_dma(NULL, nhi, port, 9, 2, 9, 2);
+ tb_test_check_dma_tunnel(test, tunnel2, 14, 14, 14, false);
+ tunnel3 = tb_tunnel_alloc_dma(NULL, nhi, port, 10, 3, 10, 3);
+ tb_test_check_dma_tunnel(test, tunnel3, 14, 14, 14, false);
+
+ /*
+ * Now enable shared buffering. The host side still has plenty
+ * so it gets 14 shared buffers but the device side only gets
+ * the remaining 10 and the path cannot use more than that.
+ */
+ tb_switch_enable_shared_buffering(host);
+ tb_switch_enable_shared_buffering(dev);
+
+ tunnel4 = tb_tunnel_alloc_dma(NULL, nhi, port, 11, 4, 11, 4);
+ tb_test_check_dma_tunnel(test, tunnel4, 4, 14, 10, true);
+
+ tb_test_check_shared(test, &host->ports[1], 14, 1);
+ tb_test_check_shared(test, &dev->ports[1], 10, 1);
+
+ /* This one joins the existing shared buffers */
+ tunnel5 = tb_tunnel_alloc_dma(NULL, nhi, port, 12, 5, 12, 5);
+ tb_test_check_dma_tunnel(test, tunnel5, 1, 14, 10, true);
+
+ tb_test_check_shared(test, &host->ports[1], 14, 2);
+ tb_test_check_shared(test, &dev->ports[1], 10, 2);
+
+ tb_tunnel_put(tunnel4);
+
+ tb_test_check_shared(test, &host->ports[1], 14, 1);
+ tb_test_check_shared(test, &dev->ports[1], 10, 1);
+
+ tb_tunnel_put(tunnel5);
+
+ tb_test_check_shared(test, &host->ports[1], 0, 0);
+ tb_test_check_shared(test, &dev->ports[1], 0, 0);
+
+ /*
+ * The 10 credits must be back in the device common pool so the
+ * dedicated allocation continues as in
+ * tb_test_credit_alloc_dma_multiple().
+ */
+ tb_switch_disable_shared_buffering(host);
+ tb_switch_disable_shared_buffering(dev);
+
+ tunnel4 = tb_tunnel_alloc_dma(NULL, nhi, port, 11, 4, 11, 4);
+ tb_test_check_dma_tunnel(test, tunnel4, 4, 14, 10, false);
+ tunnel5 = tb_tunnel_alloc_dma(NULL, nhi, port, 12, 5, 12, 5);
+ tb_test_check_dma_tunnel(test, tunnel5, 1, 14, 1, false);
+
+ tb_tunnel_put(tunnel5);
+ tb_tunnel_put(tunnel4);
+ tb_tunnel_put(tunnel3);
+ tb_tunnel_put(tunnel2);
+ tb_tunnel_put(tunnel1);
+
+ usb4_switch_free_credit_pools(dev);
+ usb4_switch_free_credit_pools(host);
+}
+
+static void tb_test_credit_alloc_dma_shared_reserved(struct kunit *test)
+{
+ struct tb_tunnel *tunnel1, *tunnel2, *tunnel3, *tunnel4;
+ struct tb_tunnel *tunnel5, *tunnel6;
+ struct usb4_credit_pool *common, *dma;
+ struct tb_port *nhi, *port, *up;
+ struct tb_switch *host, *dev;
+ unsigned int common_used;
+
+ host = alloc_host_br(test);
+ dev = alloc_dev_usb4(test, host, 0x1, true);
+
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(host), 0);
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(dev), 0);
+
+ nhi = &host->ports[7];
+ port = &dev->ports[3];
+ up = &dev->ports[1];
+ common = &up->credit_pool[USB4_CREDIT_POOL_COMMON];
+ dma = &up->credit_pool[USB4_CREDIT_POOL_DMA];
+
+ tunnel1 = tb_tunnel_alloc_dma(NULL, nhi, port, 8, 1, 8, 1);
+ tb_test_check_dma_tunnel(test, tunnel1, 14, 14, 14, false);
+ tunnel2 = tb_tunnel_alloc_dma(NULL, nhi, port, 9, 2, 9, 2);
+ tb_test_check_dma_tunnel(test, tunnel2, 14, 14, 14, false);
+ tunnel3 = tb_tunnel_alloc_dma(NULL, nhi, port, 10, 3, 10, 3);
+ tb_test_check_dma_tunnel(test, tunnel3, 14, 14, 14, false);
+ tunnel4 = tb_tunnel_alloc_dma(NULL, nhi, port, 11, 4, 11, 4);
+ tb_test_check_dma_tunnel(test, tunnel4, 4, 14, 10, false);
+
+ KUNIT_EXPECT_EQ(test, usb4_credit_pool_available(common), 0U);
+ KUNIT_EXPECT_EQ(test, usb4_credit_pool_used(dma), 0U);
+ common_used = usb4_credit_pool_used(common);
+
+ tb_switch_enable_shared_buffering(host);
+ tb_switch_enable_shared_buffering(dev);
+
+ /*
+ * The common pool of the device upstream port is exhausted so
+ * the shared buffers get the minimum from the DMA pool, same as
+ * the dedicated buffers would.
+ */
+ tunnel5 = tb_tunnel_alloc_dma(NULL, nhi, port, 12, 5, 12, 5);
+ tb_test_check_dma_tunnel(test, tunnel5, 1, 14, 1, true);
+ tb_test_check_shared(test, up, 1, 1);
+ KUNIT_EXPECT_PTR_EQ(test, up->shared_pool, dma);
+ KUNIT_EXPECT_PTR_EQ(test, tunnel5->paths[1]->hops[1].credit_pool, dma);
+ KUNIT_EXPECT_EQ(test, usb4_credit_pool_used(dma), 1U);
+
+ /* Port 3 has run out so this one goes through port 5 instead */
+ tunnel6 = tb_tunnel_alloc_dma(NULL, nhi, &dev->ports[5], 8, 6, 8, 6);
+ tb_test_check_dma_tunnel(test, tunnel6, 14, 14, 1, true);
+ tb_test_check_shared(test, up, 1, 2);
+ KUNIT_EXPECT_PTR_EQ(test, tunnel6->paths[1]->hops[1].credit_pool, dma);
+ KUNIT_EXPECT_EQ(test, usb4_credit_pool_used(dma), 1U);
+
+ /*
+ * Release the tunnel that allocated the shared buffers first so
+ * that the joiner returns them.
+ */
+ tb_tunnel_put(tunnel5);
+ tb_test_check_shared(test, up, 1, 1);
+ KUNIT_EXPECT_EQ(test, usb4_credit_pool_used(dma), 1U);
+
+ tb_tunnel_put(tunnel6);
+ tb_test_check_shared(test, up, 0, 0);
+ KUNIT_EXPECT_NULL(test, up->shared_pool);
+ KUNIT_EXPECT_EQ(test, usb4_credit_pool_used(dma), 0U);
+ KUNIT_EXPECT_EQ(test, usb4_credit_pool_used(common), common_used);
+
+ tb_tunnel_put(tunnel4);
+ tb_tunnel_put(tunnel3);
+ tb_tunnel_put(tunnel2);
+ tb_tunnel_put(tunnel1);
+
+ usb4_switch_free_credit_pools(dev);
+ usb4_switch_free_credit_pools(host);
+}
+
+static void tb_test_credit_alloc_dma_shared_mixed(struct kunit *test)
+{
+ struct tb_switch *host, *dev1, *dev2;
+ struct tb_port *nhi, *port;
+ struct tb_tunnel *tunnel;
+ struct tb_path *path;
+
+ /*
+ * Host <-> Dev1 link supports shared buffering but Dev1 <-> Dev2
+ * does not because Dev2 lacks support so that link must use
+ * dedicated buffers.
+ */
+ host = alloc_host_usb4(test);
+ dev1 = alloc_dev_usb4(test, host, 0x1, true);
+ dev2 = alloc_dev_usb4(test, dev1, 0x301, true);
+
+ tb_switch_enable_shared_buffering(host);
+ tb_switch_enable_shared_buffering(dev1);
+
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(host), 0);
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(dev1), 0);
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(dev2), 0);
+
+ nhi = &host->ports[7];
+ port = &dev2->ports[3];
+
+ tunnel = tb_tunnel_alloc_dma(NULL, nhi, port, 8, 1, 8, 1);
+ KUNIT_ASSERT_NOT_NULL(test, tunnel);
+ KUNIT_ASSERT_EQ(test, tunnel->npaths, (size_t)2);
+
+ /* DMA RX */
+ path = tunnel->paths[0];
+ KUNIT_ASSERT_EQ(test, path->path_length, 3);
+ tb_test_check_hop(test, &path->hops[0], 14, false, false);
+ tb_test_check_hop(test, &path->hops[1], 14, false, true);
+ tb_test_check_hop(test, &path->hops[2], 14, true, false);
+ tb_test_check_path_fc(test, path, false);
+
+ /* DMA TX */
+ path = tunnel->paths[1];
+ KUNIT_ASSERT_EQ(test, path->path_length, 3);
+ tb_test_check_hop(test, &path->hops[0], 0, false, true);
+ tb_test_check_hop(test, &path->hops[1], 14, true, false);
+ tb_test_check_hop(test, &path->hops[2], 14, false, false);
+ tb_test_check_path_fc(test, path, true);
+
+ tb_test_check_shared(test, &host->ports[1], 14, 1);
+ tb_test_check_shared(test, &dev1->ports[1], 14, 1);
+ tb_test_check_shared(test, &dev1->ports[3], 0, 0);
+ tb_test_check_shared(test, &dev2->ports[1], 0, 0);
+
+ tb_tunnel_put(tunnel);
+
+ tb_test_check_shared(test, &host->ports[1], 0, 0);
+ tb_test_check_shared(test, &dev1->ports[1], 0, 0);
+
+ usb4_switch_free_credit_pools(dev2);
+ usb4_switch_free_credit_pools(dev1);
+ usb4_switch_free_credit_pools(host);
+}
+
+static void tb_test_credit_alloc_dma_shared_no_credit_allocation(struct kunit *test)
+{
+ struct tb_switch *host, *dev;
+ struct tb_port *nhi, *port;
+ struct tb_tunnel *tunnel;
+ struct tb_path *path;
+
+ host = alloc_host_usb4(test);
+ dev = alloc_dev_usb4(test, host, 0x1, true);
+ dev->credit_allocation = false;
+
+ tb_switch_enable_shared_buffering(host);
+ tb_switch_enable_shared_buffering(dev);
+
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(host), 0);
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(dev), 0);
+
+ nhi = &host->ports[7];
+ port = &dev->ports[3];
+
+ /*
+ * Shared buffering needs the credit allocation so only the
+ * host ingress (RX path) can use shared buffers. The device
+ * ingress uses the fixed dedicated credits.
+ */
+ tunnel = tb_tunnel_alloc_dma(NULL, nhi, port, 8, 1, 8, 1);
+ KUNIT_ASSERT_NOT_NULL(test, tunnel);
+ KUNIT_ASSERT_EQ(test, tunnel->npaths, (size_t)2);
+
+ /* DMA RX */
+ path = tunnel->paths[0];
+ KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_hop(test, &path->hops[0], 6, false, true);
+ tb_test_check_hop(test, &path->hops[1], 14, true, false);
+ tb_test_check_path_fc(test, path, false);
+
+ /* DMA TX */
+ path = tunnel->paths[1];
+ KUNIT_ASSERT_EQ(test, path->path_length, 2);
+ tb_test_check_hop(test, &path->hops[0], 0, false, false);
+ tb_test_check_hop(test, &path->hops[1], 14, false, false);
+ tb_test_check_path_fc(test, path, true);
+
+ tb_test_check_shared(test, &host->ports[1], 14, 1);
+ tb_test_check_shared(test, &dev->ports[1], 0, 0);
+
+ tb_tunnel_put(tunnel);
+
+ tb_test_check_shared(test, &host->ports[1], 0, 0);
+
+ usb4_switch_free_credit_pools(dev);
+ usb4_switch_free_credit_pools(host);
+}
+
+static void tb_test_credit_alloc_shared_hop(struct kunit *test)
+{
+ struct tb_path_hop hop1 = {}, hop2 = {}, hop3 = {};
+ struct tb_switch *host;
+ struct tb_port *port;
+
+ host = alloc_host_usb4(test);
+ KUNIT_ASSERT_EQ(test, usb4_switch_alloc_credit_pools(host), 0);
+
+ port = &host->ports[1];
+
+ /* Shared without dedicated buffers (PCA is not used) */
+ hop1.in_port = port;
+ KUNIT_ASSERT_EQ(test, tb_hop_alloc_credits(&hop1, TB_CREDITS_DMA,
+ TB_HOP_ISE), 0);
+ KUNIT_EXPECT_EQ(test, hop1.initial_credits, 0U);
+ KUNIT_EXPECT_EQ(test, hop1.nfc_credits, 0U);
+ KUNIT_EXPECT_FALSE(test, hop1.ingress_fc_enable);
+ KUNIT_EXPECT_TRUE(test, hop1.ingress_shared_buffer);
+ tb_test_check_shared(test, port, 14, 1);
+
+ /* Restricted shared joins the same shared buffers */
+ hop2.in_port = port;
+ KUNIT_ASSERT_EQ(test, tb_hop_alloc_credits(&hop2, TB_CREDITS_DMA,
+ TB_HOP_IFC | TB_HOP_ISE), 0);
+ KUNIT_EXPECT_EQ(test, hop2.initial_credits, 14U);
+ KUNIT_EXPECT_EQ(test, hop2.nfc_credits, 0U);
+ KUNIT_EXPECT_TRUE(test, hop2.ingress_fc_enable);
+ KUNIT_EXPECT_TRUE(test, hop2.ingress_shared_buffer);
+ tb_test_check_shared(test, port, 14, 2);
+
+ /* Releasing hop that was never allocated is a no-op */
+ hop3.in_port = port;
+ hop3.ingress_shared_buffer = true;
+ tb_hop_release_credits(&hop3);
+ tb_test_check_shared(test, port, 14, 2);
+
+ tb_hop_release_credits(&hop1);
+ tb_test_check_shared(test, port, 14, 1);
+ tb_hop_release_credits(&hop2);
+ tb_test_check_shared(test, port, 0, 0);
+ KUNIT_EXPECT_EQ(test, hop2.initial_credits, 0U);
+
+ usb4_switch_free_credit_pools(host);
+}
+
static struct tb_tunnel *TB_TEST_PCIE_TUNNEL(struct kunit *test,
struct tb_switch *host, struct tb_switch *dev)
{
@@ -3558,6 +4149,13 @@ static struct kunit_case tb_test_cases[] = {
KUNIT_CASE(tb_test_credit_alloc_usb3),
KUNIT_CASE(tb_test_credit_alloc_dma),
KUNIT_CASE(tb_test_credit_alloc_dma_multiple),
+ KUNIT_CASE(tb_test_credit_alloc_dma_shared),
+ KUNIT_CASE(tb_test_credit_alloc_dma_multiple_shared),
+ KUNIT_CASE(tb_test_credit_alloc_dma_shared_partial),
+ KUNIT_CASE(tb_test_credit_alloc_dma_shared_reserved),
+ KUNIT_CASE(tb_test_credit_alloc_dma_shared_mixed),
+ KUNIT_CASE(tb_test_credit_alloc_dma_shared_no_credit_allocation),
+ KUNIT_CASE(tb_test_credit_alloc_shared_hop),
KUNIT_CASE(tb_test_credit_alloc_all),
KUNIT_CASE(tb_test_property_parse),
KUNIT_CASE(tb_test_property_format),
--
2.50.1
prev parent reply other threads:[~2026-11-19 17:19 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-19 17:12 [PATCH 00/18] thunderbolt: Add support for shared buffering Mika Westerberg
2026-11-19 17:12 ` [PATCH 01/18] thunderbolt: Avoid leaking of DMA tunnel after XDomain removal Mika Westerberg
2026-11-19 17:12 ` [PATCH 02/18] thunderbolt: Tear down DMA tunnels on every " Mika Westerberg
2026-11-19 17:12 ` [PATCH 03/18] thunderbolt: Delay re-pairing DP IN/OUT if DPRX negotiation fails Mika Westerberg
2026-11-19 17:12 ` [PATCH 04/18] thunderbolt: Call DP tunnel activation callback with tb->lock held Mika Westerberg
2026-11-19 17:12 ` [PATCH 05/18] thunderbolt: Re-apply Alpine/Titan Ridge flow on resume Mika Westerberg
2026-11-19 17:12 ` [PATCH 06/18] thunderbolt: Return -ESHUTDOWN when control channel is not running Mika Westerberg
2026-11-19 17:12 ` [PATCH 07/18] thunderbolt: Add usb4_port_hotplug_disable() Mika Westerberg
2026-11-19 17:12 ` [PATCH 08/18] thunderbolt: Move tb_plug_events_active() before tb_switch_reset_host() Mika Westerberg
2026-11-19 17:12 ` [PATCH 09/18] thunderbolt: Add tb_port_state_is_up() Mika Westerberg
2026-11-19 17:12 ` [PATCH 10/18] thunderbolt: Split host router port reset into a separate function Mika Westerberg
2026-11-19 17:12 ` [PATCH 11/18] thunderbolt: Reset topology after suspend-to-disk Mika Westerberg
2026-11-19 17:12 ` [PATCH 12/18] thunderbolt: Drop tunnel discovery without HopID allocation Mika Westerberg
2026-11-19 17:12 ` [PATCH 13/18] thunderbolt: Always take domain lock when tb_tunnel_put() is called Mika Westerberg
2026-11-19 17:12 ` [PATCH 14/18] thunderbolt: Assign domain to the routers in KUnit tests Mika Westerberg
2026-11-19 17:12 ` [PATCH 15/18] thunderbolt: Rework tunnel credit allocation Mika Westerberg
2026-11-19 17:12 ` [PATCH 16/18] thunderbolt: Add support for shared flow control Mika Westerberg
2026-11-19 17:12 ` [PATCH 17/18] thunderbolt: Use restricted shared flow control for DMA tunnels on intra-domain links Mika Westerberg
2026-11-19 17:12 ` Mika Westerberg [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261119171232.1616316-19-mika.westerberg@linux.intel.com \
--to=mika.westerberg@linux.intel.com \
--cc=YehezkelShB@gmail.com \
--cc=andreas.noever@gmail.com \
--cc=gil.fine@linux.intel.com \
--cc=linux-usb@vger.kernel.org \
--cc=lukas@wunner.de \
--cc=pooja.katiyar@intel.com \
--cc=rene.sapiens@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox