Skip to content

Commit 1eb5be0

Browse files
jgunthorpedledford
authored andcommitted
rdma: Allow demand loading of NETLINK_RDMA
Provide a module alias so that if userspace opens a netlink socket for RDMA the kernel support is loaded automatically. Signed-off-by: Jason Gunthorpe <[email protected]> Reviewed-by: Leon Romanovsky <[email protected]> Signed-off-by: Doug Ledford <[email protected]>
1 parent e9105cd commit 1eb5be0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

drivers/infiniband/core/netlink.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
#include <net/net_namespace.h>
3939
#include <net/sock.h>
4040
#include <rdma/rdma_netlink.h>
41+
#include <linux/module.h>
4142
#include "core_priv.h"
4243

4344
#include "core_priv.h"
@@ -290,3 +291,5 @@ void rdma_nl_exit(void)
290291

291292
netlink_kernel_release(nls);
292293
}
294+
295+
MODULE_ALIAS_NET_PF_PROTO(PF_NETLINK, NETLINK_RDMA);

0 commit comments

Comments
 (0)