Skip to content

Commit 7259f1d

Browse files
jtlaytonJ. Bruce Fields
authored andcommitted
sunrpc: don't register UDP port with rpcbind when version needs congestion control
Signed-off-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com>
1 parent 5283b03 commit 7259f1d

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

net/sunrpc/svc.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -976,6 +976,13 @@ int svc_register(const struct svc_serv *serv, struct net *net,
976976
if (vers->vs_hidden)
977977
continue;
978978

979+
/*
980+
* Don't register a UDP port if we need congestion
981+
* control.
982+
*/
983+
if (vers->vs_need_cong_ctrl && proto == IPPROTO_UDP)
984+
continue;
985+
979986
error = __svc_register(net, progp->pg_name, progp->pg_prog,
980987
i, family, proto, port);
981988

0 commit comments

Comments
 (0)