Date: Mon, 3 Feb 2025 18:22:37 +0200 From: Konstantin Belousov <kostikbel@gmail.com> To: Gleb Smirnoff <glebius@freebsd.org> Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: c5d671b711c3 - main - libc/rpc: add userland side RPC server over netlink(4) Message-ID: <Z6DtTe1dyj_GJokW@kib.kiev.ua> In-Reply-To: <202502010902.51192534047826@gitrepo.freebsd.org> References: <202502010902.51192534047826@gitrepo.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Feb 01, 2025 at 09:02:05AM +0000, Gleb Smirnoff wrote: > The branch main has been updated by glebius: > > URL: https://cgit.FreeBSD.org/src/commit/?id=c5d671b711c34fb9eec55531663182feedd93f87 > > commit c5d671b711c34fb9eec55531663182feedd93f87 > Author: Gleb Smirnoff <glebius@FreeBSD.org> > AuthorDate: 2025-02-01 01:02:00 +0000 > Commit: Gleb Smirnoff <glebius@FreeBSD.org> > CommitDate: 2025-02-01 09:00:25 +0000 > > libc/rpc: add userland side RPC server over netlink(4) > > To be used by NFS related daemons that provide RPC services to the kernel. > Some implementation details inside the new svc_nl.c. > > Reviewed by: rmacklem > Differential Revision: https://reviews.freebsd.org/D48550 > --- > include/rpc/svc.h | 6 + > lib/libc/rpc/Makefile.inc | 2 +- > lib/libc/rpc/Symbol.map | 4 + > lib/libc/rpc/rpc_generic.c | 3 +- > lib/libc/rpc/svc_nl.c | 300 +++++++++++++++++++++++++++++++++++++++++++++ > 5 files changed, 313 insertions(+), 2 deletions(-) > > diff --git a/include/rpc/svc.h b/include/rpc/svc.h > index d4a84384bb92..deb626ad7c1d 100644 > --- a/include/rpc/svc.h > +++ b/include/rpc/svc.h > @@ -455,6 +455,12 @@ extern SVCXPRT *svc_fd_create(const int, const u_int, const u_int); > */ > extern SVCXPRT *svcunixfd_create(int, u_int, u_int); > > +/* > + * netlink(4) server creation. To be used to service requests that > + * originate from an in-kernel client. > + */ > +extern SVCXPRT *svc_nl_create(const char *); > + > /* > * Memory based rpc (for speed check and testing) > */ > diff --git a/lib/libc/rpc/Makefile.inc b/lib/libc/rpc/Makefile.inc > index 5ee4ffc256a2..87963d10eec1 100644 > --- a/lib/libc/rpc/Makefile.inc > +++ b/lib/libc/rpc/Makefile.inc > @@ -8,7 +8,7 @@ SRCS+= auth_none.c auth_unix.c authunix_prot.c bindresvport.c clnt_bcast.c \ > rpc_callmsg.c rpc_generic.c rpc_soc.c rpcb_clnt.c rpcb_prot.c \ > rpcb_st_xdr.c rpcsec_gss_stub.c svc.c svc_auth.c svc_dg.c \ > svc_auth_unix.c svc_generic.c svc_raw.c svc_run.c svc_simple.c \ > - svc_vc.c > + svc_vc.c svc_nl.c > > # Secure-RPC > SRCS+= auth_time.c auth_des.c authdes_prot.c des_crypt.c des_soft.c \ > diff --git a/lib/libc/rpc/Symbol.map b/lib/libc/rpc/Symbol.map > index e4fecb83ec66..105d6fb6b54e 100644 > --- a/lib/libc/rpc/Symbol.map > +++ b/lib/libc/rpc/Symbol.map > @@ -199,6 +199,10 @@ FBSD_1.0 { > __rpc_get_local_uid; > }; > > +FBSD_1.8 { > + svc_nl_create; > +}; > + Are you sure that you want this symbol to be public? Do you envision that some out-of-base component would utilize it? Do you intend to keep the interface stable? Previous rpc syscall(s) were in private namespace.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Z6DtTe1dyj_GJokW>