]> git.baikalelectronics.ru Git - kernel.git/commit
svcrpc: don't leak contexts on PROC_DESTROY
authorJ. Bruce Fields <bfields@redhat.com>
Mon, 9 Jan 2017 22:15:18 +0000 (17:15 -0500)
committerJ. Bruce Fields <bfields@redhat.com>
Thu, 12 Jan 2017 20:56:14 +0000 (15:56 -0500)
commit595c284121f6380b87049e54ffd5f2968966c19a
treeade1523bd1d3ebd2dc14e46676d496a2df16f116
parentd8383c6eba05a65476a79e401949985d905bad89
svcrpc: don't leak contexts on PROC_DESTROY

Context expiry times are in units of seconds since boot, not unix time.

The use of get_seconds() here therefore sets the expiry time decades in
the future.  This prevents timely freeing of contexts destroyed by
client RPC_GSS_PROC_DESTROY requests.  We'd still free them eventually
(when the module is unloaded or the container shut down), but a lot of
contexts could pile up before then.

Cc: stable@vger.kernel.org
Fixes: e7a3b7488263 "sunrpc: use seconds since boot in expiry cache"
Reported-by: Andy Adamson <andros@netapp.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
net/sunrpc/auth_gss/svcauth_gss.c