aboutsummaryrefslogtreecommitdiffstats
path: root/net/mctp/test/utils.c
diff options
context:
space:
mode:
authorPaolo Abeni <[email protected]>2024-02-22 12:32:57 +0000
committerPaolo Abeni <[email protected]>2024-02-22 12:32:58 +0000
commite7b83f2fa445290f4ce906367ccfc8d184a98249 (patch)
tree0bd869b88b5b91bd06abd9ad4cd9e20f3c4cbd03 /net/mctp/test/utils.c
parentPPPoL2TP: Add more code snippets (diff)
parentnet: mctp: tests: Add a test for proper tag creation on local output (diff)
downloadkernel-e7b83f2fa445290f4ce906367ccfc8d184a98249.tar.gz
kernel-e7b83f2fa445290f4ce906367ccfc8d184a98249.zip
Merge branch 'mctp-core-protocol-updates-minor-fixes-tests'
Jeremy Kerr says: ==================== MCTP core protocol updates, minor fixes & tests This series implements some procotol improvements for AF_MCTP, particularly for systems with multiple MCTP networks defined. For those, we need to add the network ID to the tag lookups, which then suggests an updated version of the tag allocate / drop ioctl to allow the net ID to be specified there too. The ioctl change affects uabi, so might warrant some extra attention. There are also a couple of new kunit tests for multiple-net configurations. We have a fix for populating the flow data when fragmenting, and a testcase for that too. Of course, any queries/comments/etc., please let me know! ==================== Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Paolo Abeni <[email protected]>
Diffstat (limited to 'net/mctp/test/utils.c')
-rw-r--r--net/mctp/test/utils.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/net/mctp/test/utils.c b/net/mctp/test/utils.c
index e03ba66bbe18..565763eb0211 100644
--- a/net/mctp/test/utils.c
+++ b/net/mctp/test/utils.c
@@ -4,6 +4,7 @@
#include <linux/mctp.h>
#include <linux/if_arp.h>
+#include <net/mctp.h>
#include <net/mctpdevice.h>
#include <net/pkt_sched.h>
@@ -54,6 +55,7 @@ struct mctp_test_dev *mctp_test_create_dev(void)
rcu_read_lock();
dev->mdev = __mctp_dev_get(ndev);
+ dev->mdev->net = mctp_default_net(dev_net(ndev));
rcu_read_unlock();
return dev;