Re: [trivial PATCH] treewide: Convert switch/case fallthrough; to break;

From
Keith Busch <kbusch@kernel.org>
Date
2020-09-09 20:56:11
Also in
bpf, ceph-devel, dm-devel, dri-devel, intel-gfx, intel-wired-lan, kvmarm, linux-arm-kernel, linux-crypto, linux-i2c, linux-ide, linux-input, linux-iommu, linux-media, linux-mediatek, linux-mips, linux-mmc, linux-nfs, linux-pm, linux-rdma, linux-rtc, linux-s390, linux-scsi, linux-sctp, linux-serial, linux-usb, linux-wireless, linuxppc-dev, lkml, netdev, netfilter-devel, nouveau, sparclinux
Reply to
Joe Perches, 2020-09-09
On Wed, Sep 09, 2020 at 01:06:39PM -0700, Joe Perches wrote:
quoted hunk ↗ jump to hunk
diff --git a/crypto/tcrypt.c b/crypto/tcrypt.c
index eea0f453cfb6..8aac5bc60f4c 100644
--- a/crypto/tcrypt.c
+++ b/crypto/tcrypt.c
@@ -2464,7 +2464,7 @@ static int do_test(const char *alg, u32 type, u32 mask, int m, u32 num_mb)
 		test_hash_speed("streebog512", sec,
 				generic_hash_speed_template);
 		if (mode > 300 && mode < 400) break;
-		fallthrough;
+		break;
 	case 399:
 		break;
Just imho, this change makes the preceding 'if' look even more
pointless. Maybe the fallthrough was a deliberate choice? Not that my
opinion matters here as I don't know this module, but it looked a bit
odd to me.
Thread (18 messages) 18 messages, 16 authors, last reply 2020-09-17
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help