Skip to contentSkip to conversation

crypto: remove unneeded semicolon

PATCH In review Chen Zhou 3 participants 3 messages Dec 16, 2019 – Dec 27, 2019 Crypto API

lore
Share & tools
lore

Chen Zhou

author
#0 lore raw

PATCH 1/1 crypto: remove unneeded semicolon

Fixes coccicheck warning:

./include/linux/crypto.h:573:2-3: Unneeded semicolon

---
 include/linux/crypto.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/linux/crypto.h +1 -1
index 23365a9..5446efe 100644
@@ -570,7 +570,7 @@ static inline int crypto_wait_req(int err, struct crypto_wait *wait)
 		reinit_completion(&wait->completion);
 		err = wait->err;
 		break;
-	};
+	}
 
 	return err;
 }
Signature · 1 line
2.7.4
#1 lore raw
Quoted 15 lines · Chen Zhou

Fixes coccicheck warning:

./include/linux/crypto.h:573:2-3: Unneeded semicolon

---
 include/linux/crypto.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/linux/crypto.h +0 -0
index 23365a9..5446efe 100644

include/linux/crypto.h static inline int crypto_wait_req(int err, struct crypto_wait *wait) · line 576

Quoted 8 lines
include/linux/crypto.h +1 -1
@@ -570,7 +570,7 @@ static inline int crypto_wait_req(int err, struct crypto_wait *wait)
 		reinit_completion(&wait->completion);
 		err = wait->err;
 		break;
-	};
+	}
 
 	return err;
 }

As long as you're changing this, perhaps also change the 'switch' to an 'if' and delete the extra blank line? I.e.:

static inline int crypto_wait_req(int err, struct crypto_wait *wait)

{
	if (err == -EINPROGRESS || err == -EBUSY) {
		wait_for_completion(&wait->completion);
		reinit_completion(&wait->completion);
		err = wait->err;
	}
	return err;
}
maintainer
#2 lore raw
In reply to Chen Zhou
Quoted 8 lines · Chen Zhou

Fixes coccicheck warning:

./include/linux/crypto.h:573:2-3: Unneeded semicolon

---
 include/linux/crypto.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch applied. Thanks.

Signature · 3 lines
Email: Herbert Xu <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt