android_kernel_motorola_sm6225/net/sunrpc
Zhang Xiaoxu ba124fdcd1 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-20 16:15:41 +02:00
..
auth_gss rpc: fix NULL dereference on kmalloc failure 2021-04-07 12:48:47 +02:00
xprtrdma svcrdma: disable timeouts on rdma backchannel 2021-03-24 11:07:33 +01:00
addr.c net: sunrpc: interpret the return value of kstrtou32 correctly 2021-01-19 18:22:38 +01:00
auth.c sunrpc: kstrtoul() can also return -ERANGE 2018-07-31 12:53:40 -04:00
auth_generic.c SUNRPC: Fix a bogus get/put in generic_key_to_expire() 2018-12-01 09:37:33 +01:00
auth_null.c net/sunrpc: Make rpc_auth_create_args a const 2018-07-30 13:19:41 -04:00
auth_unix.c net/sunrpc: Make rpc_auth_create_args a const 2018-07-30 13:19:41 -04:00
backchannel_rqst.c sunrpc: whitespace fixes 2018-07-31 12:53:40 -04:00
cache.c sunrpc: fix crash when cache_head become valid before update 2019-12-17 20:35:52 +01:00
clnt.c net :sunrpc :clnt :Fix xps refcount imbalance on the error path 2019-07-14 08:11:15 +02:00
debugfs.c
Kconfig IB: Revert "remove redundant INFINIBAND kconfig dependencies" 2018-05-28 10:40:16 -06:00
Makefile
netns.h
rpc_pipe.c sunrpc: fixed rollback in rpc_gssd_dummy_populate() 2020-06-30 23:17:18 -04:00
rpcb_clnt.c SUNRPC: stop printk reading past end of string 2020-09-23 12:10:58 +02:00
sched.c SUNRPC: Should wake up the privileged task firstly. 2021-07-20 16:15:41 +02:00
socklib.c
stats.c sunrpc: whitespace fixes 2018-07-31 12:53:40 -04:00
sunrpc.h sunrpc: whitespace fixes 2018-07-31 12:53:40 -04:00
sunrpc_syms.c
svc.c sunrpc: fix refcount leak for rpc auth modules 2021-03-24 11:07:33 +01:00
svc_xprt.c NFSD: Repair misuse of sv_lock in 5.10.16-rt30. 2021-03-24 11:07:33 +01:00
svcauth.c
svcauth_unix.c
svcsock.c svcrdma: Fix leak of svc_rdma_recv_ctxt objects 2020-05-02 17:25:52 +02:00
sysctl.c
timer.c
xdr.c SUNRPC: Properly set the @subbuf parameter of xdr_buf_subsegment() 2020-06-30 23:17:18 -04:00
xprt.c SUNRPC: xprt_load_transport() needs to support the netid "rdma6" 2020-12-30 11:25:59 +01:00
xprtmultipath.c
xprtsock.c SUNRPC: xprt_load_transport() needs to support the netid "rdma6" 2020-12-30 11:25:59 +01:00