diff options
author | Wu Fengguang <fengguang.wu@intel.com> | 2016-06-04 19:17:19 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-06-07 18:30:21 -0400 |
commit | fa54cc70ed2eddd96773ffdf4d96d23ea7483e56 (patch) | |
tree | 2d6aa18b12be9227c0ae1c0a87580ee7edfe42fd /net | |
parent | 29a36611e9f10f629b4d7920418fcb8f5e50ae75 (diff) |
rxrpc: fix ptr_ret.cocci warnings
net/rxrpc/rxkad.c:1165:1-3: WARNING: PTR_ERR_OR_ZERO can be used
Use PTR_ERR_OR_ZERO rather than if(IS_ERR(...)) + PTR_ERR
Generated by: scripts/coccinelle/api/ptr_ret.cocci
CC: David Howells <dhowells@redhat.com>
Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/rxrpc/rxkad.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/net/rxrpc/rxkad.c b/net/rxrpc/rxkad.c index 6b726a046a7d..bab56ed649ba 100644 --- a/net/rxrpc/rxkad.c +++ b/net/rxrpc/rxkad.c | |||
@@ -1162,9 +1162,7 @@ static int rxkad_init(void) | |||
1162 | /* pin the cipher we need so that the crypto layer doesn't invoke | 1162 | /* pin the cipher we need so that the crypto layer doesn't invoke |
1163 | * keventd to go get it */ | 1163 | * keventd to go get it */ |
1164 | rxkad_ci = crypto_alloc_skcipher("pcbc(fcrypt)", 0, CRYPTO_ALG_ASYNC); | 1164 | rxkad_ci = crypto_alloc_skcipher("pcbc(fcrypt)", 0, CRYPTO_ALG_ASYNC); |
1165 | if (IS_ERR(rxkad_ci)) | 1165 | return PTR_ERR_OR_ZERO(rxkad_ci); |
1166 | return PTR_ERR(rxkad_ci); | ||
1167 | return 0; | ||
1168 | } | 1166 | } |
1169 | 1167 | ||
1170 | /* | 1168 | /* |