generic-poky/meta/recipes-devtools/unfs-server/unfs-server-2.1+2.2beta47/023-no-rpc-register.patch
Jason Wessel ae6133572f Allow user mode NFS server to run without rpcbind / portmap
and nfsroot mount without the need to talk to an RPC info
server as long as the port numbers for mountd and nfsd
are known in advance.

This patch updates the qemu startup scripts and the
user mode NFS server to have the ability to start
without the need to use rpcbind or portmap services.

(From OE-Core rev: 3b1346c607c41a2d592c48594457c32153cb2314)

Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-10-10 10:00:08 +01:00

35 lines
1.2 KiB
Diff

Upstream-Status: Inappropriate [other]
Upstream is not making further releases of this software.
Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
# Allow user mode NFS to work without rpcbind / portmap
# Patch origin: Wind River
---
rpcmisc.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
--- a/rpcmisc.c
+++ b/rpcmisc.c
@@ -91,7 +91,8 @@ not_inetd:
if (transp == NULL)
Dprintf(L_FATAL, "cannot create udp service.");
for (i = 0; (vers = verstbl[i]) != 0; i++) {
- if (!svc_register(transp, prog, vers, dispatch, IPPROTO_UDP)) {
+ if (!(svc_register(transp, prog, vers, dispatch, IPPROTO_UDP) ||
+ svc_register(transp, prog, vers, dispatch, 0))) {
Dprintf(L_FATAL,
"unable to register (%s, %d, udp).",
name, vers);
@@ -110,7 +111,8 @@ not_inetd:
transp->xp_ops->xp_recv = auth_rendevouser;
#endif
for (i = 0; (vers = verstbl[i]) != 0; i++) {
- if (!svc_register(transp, prog, vers, dispatch, IPPROTO_TCP)) {
+ if (!(svc_register(transp, prog, vers, dispatch, IPPROTO_TCP) ||
+ svc_register(transp, prog, vers, dispatch, 0))) {
Dprintf(L_FATAL,
"unable to register (%s, %d, tcp).",
name, vers);