[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240424135109.3524355-2-amorenoz@redhat.com>
Date: Wed, 24 Apr 2024 15:50:48 +0200
From: Adrian Moreno <amorenoz@...hat.com>
To: netdev@...r.kernel.org
Cc: aconole@...hat.com,
echaudro@...hat.com,
horms@...nel.org,
i.maximets@....org,
Adrian Moreno <amorenoz@...hat.com>,
Jakub Kicinski <kuba@...nel.org>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Paolo Abeni <pabeni@...hat.com>,
Jiri Pirko <jiri@...nulli.us>,
Jacob Keller <jacob.e.keller@...el.com>,
Johannes Berg <johannes@...solutions.net>,
Ido Schimmel <idosch@...dia.com>,
Stanislaw Gruszka <stanislaw.gruszka@...ux.intel.com>,
linux-kernel@...r.kernel.org
Subject: [PATCH net-next 1/8] net: netlink: export genl private pointer getters
Both "__genl_sk_priv_get" and "genl_sk_priv_get" are useful functions to
handle private pointers attached to genetlink sockets.
Export them so they can be used in modules.
Reviewed-by: Jakub Kicinski <kuba@...nel.org>
Signed-off-by: Adrian Moreno <amorenoz@...hat.com>
---
net/netlink/genetlink.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/net/netlink/genetlink.c b/net/netlink/genetlink.c
index feb54c63a116..beafa415a9f5 100644
--- a/net/netlink/genetlink.c
+++ b/net/netlink/genetlink.c
@@ -726,6 +726,7 @@ void *__genl_sk_priv_get(struct genl_family *family, struct sock *sk)
return ERR_PTR(-EINVAL);
return xa_load(family->sock_privs, (unsigned long) sk);
}
+EXPORT_SYMBOL(__genl_sk_priv_get);
/**
* genl_sk_priv_get - Get family private pointer for socket
@@ -764,6 +765,7 @@ void *genl_sk_priv_get(struct genl_family *family, struct sock *sk)
}
return priv;
}
+EXPORT_SYMBOL(genl_sk_priv_get);
/**
* genl_register_family - register a generic netlink family
--
2.44.0
Powered by blists - more mailing lists