kernel_optimize_test/net/sunrpc
Zhang Xiaoxu cbcbfb0488 SUNRPC: Should wake up the privileged task firstly.
commit 5483b904bf336948826594610af4c9bbb0d9e3aa upstream.

When find a task from wait queue to wake up, a non-privileged task may
be found out, rather than the privileged. This maybe lead a deadlock
same as commit dfe1fe75e00e ("NFSv4: Fix deadlock between nfs4_evict_inode()
and nfs4_opendata_get_inode()"):

Privileged delegreturn task is queued to privileged list because all
the slots are assigned. If there has no enough slot to wake up the
non-privileged batch tasks(session less than 8 slot), then the privileged
delegreturn task maybe lost waked up because the found out task can't
get slot since the session is on draining.

So we should treate the privileged task as the emergency task, and
execute it as for as we can.

Reported-by: Hulk Robot <hulkci@huawei.com>
Fixes: 5fcdfacc01 ("NFSv4: Return delegations synchronously in evict_inode")
Cc: stable@vger.kernel.org
Signed-off-by: Zhang Xiaoxu <zhangxiaoxu5@huawei.com>
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-07-14 16:55:42 +02:00
..
auth_gss rpc: fix NULL dereference on kmalloc failure 2021-04-07 15:00:04 +02:00
xprtrdma SUNRPC: More fixes for backlog congestion 2021-06-03 09:00:51 +02:00
addr.c
auth_null.c
auth_unix.c
auth.c
backchannel_rqst.c
cache.c
clnt.c SUNRPC in case of backlog, hand free slots directly to waiting task 2021-06-03 09:00:37 +02:00
debugfs.c
Kconfig
Makefile
netns.h
rpc_pipe.c
rpcb_clnt.c
sched.c SUNRPC: Should wake up the privileged task firstly. 2021-07-14 16:55:42 +02:00
socklib.c
socklib.h
stats.c
sunrpc_syms.c
sunrpc.h
svc_xprt.c NFSD: Repair misuse of sv_lock in 5.10.16-rt30. 2021-03-25 09:04:08 +01:00
svc.c sunrpc: fix refcount leak for rpc auth modules 2021-03-25 09:04:08 +01:00
svcauth_unix.c
svcauth.c
svcsock.c SUNRPC: fix ternary sign expansion bug in tracing 2021-05-19 10:13:04 +02:00
sysctl.c
timer.c
xdr.c
xprt.c SUNRPC: More fixes for backlog congestion 2021-06-03 09:00:51 +02:00
xprtmultipath.c
xprtsock.c