SUNRPC: Fix up task signalling
authorTrond Myklebust <trondmy@gmail.com>
Sun, 7 Apr 2019 17:58:44 +0000 (13:58 -0400)
committerAnna Schumaker <Anna.Schumaker@Netapp.com>
Thu, 25 Apr 2019 18:18:12 +0000 (14:18 -0400)
commitae67bd3821bb0a54d97e7883d211196637d487a9
tree351a54fd10a71f6c76d5e8d8a8ce323c9252192e
parent085b7755808aa11f78ab9377257e1dad2e6fa4bb
SUNRPC: Fix up task signalling

The RPC_TASK_KILLED flag should really not be set from another context
because it can clobber data in the struct task when task->tk_flags is
changed non-atomically.
Let's therefore swap out RPC_TASK_KILLED with an atomic flag, and add
a function to set that flag and safely wake up the task.

Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
fs/lockd/clntproc.c
fs/nfsd/nfs4callback.c
include/linux/sunrpc/sched.h
include/trace/events/sunrpc.h
net/sunrpc/clnt.c
net/sunrpc/sched.c
net/sunrpc/xprt.c