1
0
Fork 0
alistair23-linux/net/sunrpc
Eric Biggers 877b5691f2 crypto: shash - remove shash_desc::flags
The flags field in 'struct shash_desc' never actually does anything.
The only ostensibly supported flag is CRYPTO_TFM_REQ_MAY_SLEEP.
However, no shash algorithm ever sleeps, making this flag a no-op.

With this being the case, inevitably some users who can't sleep wrongly
pass MAY_SLEEP.  These would all need to be fixed if any shash algorithm
actually started sleeping.  For example, the shash_ahash_*() functions,
which wrap a shash algorithm with the ahash API, pass through MAY_SLEEP
from the ahash API to the shash API.  However, the shash functions are
called under kmap_atomic(), so actually they're assumed to never sleep.

Even if it turns out that some users do need preemption points while
hashing large buffers, we could easily provide a helper function
crypto_shash_update_large() which divides the data into smaller chunks
and calls crypto_shash_update() and cond_resched() for each chunk.  It's
not necessary to have a flag in 'struct shash_desc', nor is it necessary
to make individual shash algorithms aware of this at all.

Therefore, remove shash_desc::flags, and document that the
crypto_shash_*() functions can be called from any context.

Signed-off-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2019-04-25 15:38:12 +08:00
..
auth_gss crypto: shash - remove shash_desc::flags 2019-04-25 15:38:12 +08:00
xprtrdma Miscellaneous NFS server fixes. Probably the most visible bug is one 2019-03-12 15:06:54 -07:00
Kconfig SUNRPC: Add build option to disable support for insecure enctypes 2019-02-13 13:33:12 -05:00
Makefile SUNRPC: remove generic cred code. 2018-12-19 13:52:46 -05:00
addr.c replace strict_strto calls 2014-07-12 18:45:49 -04:00
auth.c SUNRPC: Use struct xdr_stream when decoding RPC Reply header 2019-02-14 09:11:18 -05:00
auth_null.c SUNRPC: Add rpc_auth::au_ralign field 2019-02-14 11:48:36 -05:00
auth_unix.c NFSoRDMA client updates for 5.1 2019-02-25 09:35:49 -05:00
backchannel_rqst.c SUNRPC: Allow dynamic allocation of back channel slots 2019-03-02 16:25:26 -05:00
cache.c sunrpc: fix cache_head leak due to queued request 2018-12-04 15:42:08 -05:00
clnt.c SUNRPC: Remove redundant check for the reply length in call_decode() 2019-03-15 13:11:36 -04:00
debugfs.c rpc: properly check debugfs dentry before using it 2019-02-12 15:51:39 -05:00
netns.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
rpc_pipe.c sunrpc: convert to DEFINE_SHOW_ATTRIBUTE 2019-01-02 12:05:49 -05:00
rpcb_clnt.c sunrpc: convert unnecessary GFP_ATOMIC to GFP_NOFS 2019-01-02 12:05:19 -05:00
sched.c SUNRPC: Remove redundant calls to RPC_IS_QUEUED() 2019-03-09 16:22:58 -05:00
socklib.c net: dump more useful information in netdev_rx_csum_fault() 2018-11-15 11:37:04 -08:00
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 net: Drop pernet_operations::async 2018-03-27 13:18:09 -04:00
svc.c SUNRPC: Remove rpc_xprt::tsh_size 2019-02-13 13:14:35 -05:00
svc_xprt.c svcrpc: fix unlikely races preventing queueing of sockets 2019-02-06 15:37:14 -05:00
svcauth.c SUNRPC: Add lockless lookup of the server's auth domain 2018-10-03 11:32:59 -04:00
svcauth_unix.c SUNRPC: Make server side AUTH_UNIX use lockless lookups 2018-10-29 16:58:04 -04:00
svcsock.c svcrpc: fix UDP on servers with lots of threads 2019-02-21 10:17:36 -05:00
sysctl.c Remove 'type' argument from access_ok() function 2019-01-03 18:57:57 -08:00
timer.c net: cleanup unsigned to unsigned int 2012-04-15 12:44:40 -04:00
xdr.c NFS: Account for XDR pad of buf->pages 2019-02-14 10:13:49 -05:00
xprt.c SUNRPC: Use the ENOTCONN error on socket disconnect 2019-03-15 13:08:20 -04:00
xprtmultipath.c SUNRPC: Fix some kernel doc complaints 2019-01-02 12:05:18 -05:00
xprtsock.c SUNRPC: Fix a client regression when handling oversized replies 2019-03-15 13:06:21 -04:00