Trond Myklebust cb2c6fdf62 NFSv4.1: Fix a race in nfs4_proc_layoutget
commit bd171930e6a3de4f5cffdafbb944e50093dfb59b upstream.

If the task calling layoutget is signalled, then it is possible for the
calls to nfs4_sequence_free_slot() and nfs4_layoutget_prepare() to race,
in which case we leak a slot.
The fix is to move the call to nfs4_sequence_free_slot() into the
nfs4_layoutget_release() so that it gets called at task teardown time.

Fixes: 2e80dbe7ac51 ("NFSv4.1: Close callback races for OPEN, LAYOUTGET...")
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-07-05 14:40:18 +02:00
..
2016-10-13 21:28:20 -07:00
2016-10-04 16:20:26 -04:00
2015-02-03 11:06:34 -08:00
2016-03-31 00:30:15 -04:00
2016-11-18 13:35:58 -05:00
2015-04-23 15:16:14 -04:00
2015-04-23 15:16:14 -04:00
2016-05-17 15:47:55 -04:00
2016-07-30 16:33:25 -07:00
2016-09-27 11:03:58 +02:00
2016-10-07 18:46:28 -07:00
2017-01-19 20:18:05 +01:00
2016-07-20 23:30:06 -04:00