* [powerpc:merge] BUILD SUCCESS 4b552a4cbf286ff9dcdab19153f3c1c7d1680fab
From: kernel test robot @ 2020-09-10 1:18 UTC (permalink / raw)
To: Michael Ellerman; +Cc: linuxppc-dev
tree/branch: https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git merge
branch HEAD: 4b552a4cbf286ff9dcdab19153f3c1c7d1680fab Automatic merge of 'master', 'next' and 'fixes' (2020-09-09 22:40)
elapsed time: 726m
configs tested: 129
configs skipped: 11
The following configs have been built successfully.
More configs may be tested in the coming days.
gcc tested configs:
arm defconfig
arm64 allyesconfig
arm64 defconfig
arm allyesconfig
arm allmodconfig
arm zeus_defconfig
powerpc linkstation_defconfig
sparc64 defconfig
h8300 h8s-sim_defconfig
mips fuloong2e_defconfig
sh apsh4a3a_defconfig
arm footbridge_defconfig
sh ecovec24_defconfig
mips malta_kvm_guest_defconfig
sh shmin_defconfig
powerpc cell_defconfig
powerpc powernv_defconfig
powerpc mgcoge_defconfig
arm neponset_defconfig
m68k stmark2_defconfig
arm mainstone_defconfig
mips mtx1_defconfig
sh r7785rp_defconfig
arc tb10x_defconfig
arm spear3xx_defconfig
arm sama5_defconfig
arm netwinder_defconfig
microblaze mmu_defconfig
sh se7721_defconfig
arm lpc18xx_defconfig
mips jazz_defconfig
m68k m5249evb_defconfig
parisc generic-32bit_defconfig
arm assabet_defconfig
arm dove_defconfig
arc axs101_defconfig
mips bmips_be_defconfig
powerpc mpc83xx_defconfig
m68k sun3_defconfig
powerpc mpc512x_defconfig
sh sh7757lcr_defconfig
s390 allyesconfig
arm cerfcube_defconfig
sh shx3_defconfig
arm clps711x_defconfig
arc vdk_hs38_defconfig
openrisc alldefconfig
sh ap325rxa_defconfig
arm mvebu_v7_defconfig
arm spear13xx_defconfig
openrisc simple_smp_defconfig
arm collie_defconfig
sh se7750_defconfig
arm hackkit_defconfig
arm gemini_defconfig
sh microdev_defconfig
arm ixp4xx_defconfig
sh landisk_defconfig
arc haps_hs_smp_defconfig
arm tegra_defconfig
sh se7206_defconfig
xtensa xip_kc705_defconfig
mips rb532_defconfig
ia64 allmodconfig
ia64 defconfig
ia64 allyesconfig
m68k defconfig
m68k allyesconfig
m68k allmodconfig
nios2 defconfig
arc allyesconfig
nds32 allnoconfig
c6x allyesconfig
nds32 defconfig
nios2 allyesconfig
csky defconfig
alpha defconfig
alpha allyesconfig
xtensa allyesconfig
h8300 allyesconfig
arc defconfig
sh allmodconfig
parisc defconfig
parisc allyesconfig
s390 defconfig
i386 allyesconfig
sparc allyesconfig
sparc defconfig
i386 defconfig
mips allyesconfig
mips allmodconfig
powerpc defconfig
powerpc allyesconfig
powerpc allmodconfig
powerpc allnoconfig
x86_64 randconfig-a004-20200909
x86_64 randconfig-a006-20200909
x86_64 randconfig-a003-20200909
x86_64 randconfig-a001-20200909
x86_64 randconfig-a005-20200909
x86_64 randconfig-a002-20200909
i386 randconfig-a004-20200909
i386 randconfig-a005-20200909
i386 randconfig-a006-20200909
i386 randconfig-a002-20200909
i386 randconfig-a001-20200909
i386 randconfig-a003-20200909
i386 randconfig-a016-20200909
i386 randconfig-a015-20200909
i386 randconfig-a011-20200909
i386 randconfig-a013-20200909
i386 randconfig-a014-20200909
i386 randconfig-a012-20200909
riscv allyesconfig
riscv allnoconfig
riscv defconfig
riscv allmodconfig
x86_64 rhel
x86_64 allyesconfig
x86_64 rhel-7.6-kselftests
x86_64 defconfig
x86_64 rhel-8.3
x86_64 kexec
clang tested configs:
x86_64 randconfig-a013-20200909
x86_64 randconfig-a016-20200909
x86_64 randconfig-a011-20200909
x86_64 randconfig-a012-20200909
x86_64 randconfig-a015-20200909
x86_64 randconfig-a014-20200909
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
^ permalink raw reply
* [powerpc:next-test] BUILD SUCCESS a24f73a061494d718b254ec7814cd10010ac2ec3
From: kernel test robot @ 2020-09-10 1:18 UTC (permalink / raw)
To: Michael Ellerman; +Cc: linuxppc-dev
tree/branch: https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next-test
branch HEAD: a24f73a061494d718b254ec7814cd10010ac2ec3 powerpc/watchpoint/selftests: Tests for kernel accessing user memory
elapsed time: 725m
configs tested: 152
configs skipped: 15
The following configs have been built successfully.
More configs may be tested in the coming days.
gcc tested configs:
arm defconfig
arm64 allyesconfig
arm64 defconfig
arm allyesconfig
arm allmodconfig
arm zeus_defconfig
powerpc linkstation_defconfig
sparc64 defconfig
h8300 h8s-sim_defconfig
mips fuloong2e_defconfig
sh apsh4a3a_defconfig
arm footbridge_defconfig
sh ecovec24_defconfig
powerpc powernv_defconfig
powerpc mgcoge_defconfig
arm neponset_defconfig
m68k stmark2_defconfig
arm mainstone_defconfig
mips mtx1_defconfig
sh r7785rp_defconfig
arc tb10x_defconfig
arm spear3xx_defconfig
i386 allyesconfig
arm sama5_defconfig
arm netwinder_defconfig
microblaze mmu_defconfig
sh se7721_defconfig
m68k q40_defconfig
x86_64 alldefconfig
powerpc mpc83xx_defconfig
arm colibri_pxa270_defconfig
mips nlm_xlp_defconfig
arc allyesconfig
h8300 defconfig
mips loongson3_defconfig
sh se7750_defconfig
xtensa xip_kc705_defconfig
m68k bvme6000_defconfig
arm lpc18xx_defconfig
mips jazz_defconfig
m68k m5249evb_defconfig
parisc generic-32bit_defconfig
arm assabet_defconfig
arm dove_defconfig
arm multi_v4t_defconfig
c6x alldefconfig
arm nhk8815_defconfig
openrisc alldefconfig
c6x dsk6455_defconfig
mips decstation_r4k_defconfig
arc axs101_defconfig
mips bmips_be_defconfig
m68k sun3_defconfig
powerpc mpc512x_defconfig
sh sh7757lcr_defconfig
mips maltasmvp_eva_defconfig
sh titan_defconfig
arm pxa910_defconfig
mips vocore2_defconfig
mips rt305x_defconfig
arm bcm2835_defconfig
powerpc mvme5100_defconfig
mips ip32_defconfig
arm cm_x300_defconfig
sh ecovec24-romimage_defconfig
csky defconfig
i386 defconfig
sh polaris_defconfig
m68k mvme16x_defconfig
openrisc simple_smp_defconfig
arm shmobile_defconfig
arm64 alldefconfig
mips rs90_defconfig
mips ath25_defconfig
arm clps711x_defconfig
arc vdk_hs38_defconfig
arm hackkit_defconfig
arm gemini_defconfig
sh microdev_defconfig
arm ixp4xx_defconfig
arm pxa3xx_defconfig
powerpc amigaone_defconfig
arm xcep_defconfig
riscv allmodconfig
arc axs103_defconfig
sh ul2_defconfig
powerpc cell_defconfig
m68k multi_defconfig
sh se7206_defconfig
mips rb532_defconfig
ia64 allmodconfig
ia64 defconfig
ia64 allyesconfig
m68k defconfig
m68k allyesconfig
m68k allmodconfig
nios2 defconfig
nds32 allnoconfig
c6x allyesconfig
nds32 defconfig
nios2 allyesconfig
alpha defconfig
alpha allyesconfig
xtensa allyesconfig
h8300 allyesconfig
arc defconfig
sh allmodconfig
parisc defconfig
s390 allyesconfig
parisc allyesconfig
s390 defconfig
sparc allyesconfig
sparc defconfig
mips allyesconfig
mips allmodconfig
powerpc defconfig
powerpc allyesconfig
powerpc allmodconfig
powerpc allnoconfig
x86_64 randconfig-a004-20200909
x86_64 randconfig-a006-20200909
x86_64 randconfig-a003-20200909
x86_64 randconfig-a001-20200909
x86_64 randconfig-a005-20200909
x86_64 randconfig-a002-20200909
i386 randconfig-a004-20200909
i386 randconfig-a005-20200909
i386 randconfig-a006-20200909
i386 randconfig-a002-20200909
i386 randconfig-a001-20200909
i386 randconfig-a003-20200909
i386 randconfig-a016-20200909
i386 randconfig-a015-20200909
i386 randconfig-a011-20200909
i386 randconfig-a013-20200909
i386 randconfig-a014-20200909
i386 randconfig-a012-20200909
riscv allyesconfig
riscv allnoconfig
riscv defconfig
x86_64 rhel
x86_64 allyesconfig
x86_64 rhel-7.6-kselftests
x86_64 defconfig
x86_64 rhel-8.3
x86_64 kexec
clang tested configs:
x86_64 randconfig-a013-20200909
x86_64 randconfig-a016-20200909
x86_64 randconfig-a011-20200909
x86_64 randconfig-a012-20200909
x86_64 randconfig-a015-20200909
x86_64 randconfig-a014-20200909
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
^ permalink raw reply
* [powerpc:fixes-test] BUILD SUCCESS 0460534b532e5518c657c7d6492b9337d975eaa3
From: kernel test robot @ 2020-09-10 1:12 UTC (permalink / raw)
To: Michael Ellerman; +Cc: linuxppc-dev
tree/branch: https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git fixes-test
branch HEAD: 0460534b532e5518c657c7d6492b9337d975eaa3 powerpc/papr_scm: Limit the readability of 'perf_stats' sysfs attribute
elapsed time: 721m
configs tested: 159
configs skipped: 22
The following configs have been built successfully.
More configs may be tested in the coming days.
gcc tested configs:
arm defconfig
arm64 allyesconfig
arm64 defconfig
arm allyesconfig
arm allmodconfig
mips malta_kvm_guest_defconfig
mips db1xxx_defconfig
mips rm200_defconfig
arm vexpress_defconfig
mips tb0226_defconfig
mips maltasmvp_defconfig
h8300 h8s-sim_defconfig
mips fuloong2e_defconfig
sh apsh4a3a_defconfig
arm footbridge_defconfig
sh ecovec24_defconfig
sh shmin_defconfig
powerpc cell_defconfig
powerpc powernv_defconfig
powerpc mgcoge_defconfig
arm neponset_defconfig
m68k stmark2_defconfig
arm mainstone_defconfig
mips mtx1_defconfig
sh r7785rp_defconfig
arc tb10x_defconfig
arm spear3xx_defconfig
i386 allyesconfig
arm sama5_defconfig
arm netwinder_defconfig
microblaze mmu_defconfig
sh se7721_defconfig
arm imx_v4_v5_defconfig
mips lemote2f_defconfig
arc allyesconfig
h8300 defconfig
mips loongson3_defconfig
sh se7750_defconfig
xtensa xip_kc705_defconfig
m68k bvme6000_defconfig
arm lpc18xx_defconfig
mips jazz_defconfig
m68k m5249evb_defconfig
parisc generic-32bit_defconfig
arm assabet_defconfig
arm dove_defconfig
mips bigsur_defconfig
mips cu1000-neo_defconfig
arm pxa910_defconfig
openrisc alldefconfig
c6x dsk6455_defconfig
mips decstation_r4k_defconfig
mips maltasmvp_eva_defconfig
sh titan_defconfig
mips vocore2_defconfig
arm cm_x300_defconfig
sh ecovec24-romimage_defconfig
csky defconfig
i386 defconfig
arm vt8500_v6_v7_defconfig
arm colibri_pxa300_defconfig
xtensa generic_kc705_defconfig
arm s3c2410_defconfig
um kunit_defconfig
sh polaris_defconfig
m68k mvme16x_defconfig
c6x allyesconfig
openrisc simple_smp_defconfig
arm shmobile_defconfig
arm64 alldefconfig
mips rs90_defconfig
mips ath25_defconfig
arm clps711x_defconfig
arc vdk_hs38_defconfig
sh alldefconfig
powerpc ep8248e_defconfig
sh ul2_defconfig
m68k multi_defconfig
arm nhk8815_defconfig
alpha defconfig
sh landisk_defconfig
arc haps_hs_smp_defconfig
arm tegra_defconfig
powerpc chrp32_defconfig
arm corgi_defconfig
sh se7780_defconfig
x86_64 alldefconfig
arc nsim_700_defconfig
arm multi_v7_defconfig
arm jornada720_defconfig
sh se7206_defconfig
mips rb532_defconfig
ia64 allmodconfig
ia64 defconfig
ia64 allyesconfig
m68k defconfig
m68k allyesconfig
m68k allmodconfig
nios2 defconfig
nds32 allnoconfig
nds32 defconfig
nios2 allyesconfig
alpha allyesconfig
xtensa allyesconfig
h8300 allyesconfig
arc defconfig
sh allmodconfig
parisc defconfig
s390 allyesconfig
parisc allyesconfig
s390 defconfig
sparc allyesconfig
sparc defconfig
mips allyesconfig
mips allmodconfig
powerpc defconfig
powerpc allyesconfig
powerpc allmodconfig
powerpc allnoconfig
x86_64 randconfig-a004-20200909
x86_64 randconfig-a006-20200909
x86_64 randconfig-a003-20200909
x86_64 randconfig-a001-20200909
x86_64 randconfig-a005-20200909
x86_64 randconfig-a002-20200909
i386 randconfig-a004-20200909
i386 randconfig-a005-20200909
i386 randconfig-a006-20200909
i386 randconfig-a002-20200909
i386 randconfig-a001-20200909
i386 randconfig-a003-20200909
i386 randconfig-a016-20200909
i386 randconfig-a015-20200909
i386 randconfig-a011-20200909
i386 randconfig-a013-20200909
i386 randconfig-a014-20200909
i386 randconfig-a012-20200909
x86_64 randconfig-a004-20200910
x86_64 randconfig-a006-20200910
x86_64 randconfig-a003-20200910
x86_64 randconfig-a002-20200910
x86_64 randconfig-a005-20200910
x86_64 randconfig-a001-20200910
riscv allyesconfig
riscv allnoconfig
riscv defconfig
riscv allmodconfig
x86_64 rhel
x86_64 allyesconfig
x86_64 rhel-7.6-kselftests
x86_64 defconfig
x86_64 rhel-8.3
x86_64 kexec
clang tested configs:
x86_64 randconfig-a013-20200909
x86_64 randconfig-a016-20200909
x86_64 randconfig-a011-20200909
x86_64 randconfig-a012-20200909
x86_64 randconfig-a015-20200909
x86_64 randconfig-a014-20200909
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
^ permalink raw reply
* Re: [trivial PATCH] treewide: Convert switch/case fallthrough; to break;
From: Joe Perches @ 2020-09-09 22:47 UTC (permalink / raw)
To: Jason Gunthorpe
Cc: linux-wireless, linux-fbdev, oss-drivers, nouveau, alsa-devel,
dri-devel, linux-mips, linux-ide, dm-devel, linux-mtd, linux-i2c,
sparclinux, kvmarm, linux-rtc, linux-s390, linux-scsi, dccp,
linux-rdma, linux-atm-general, linux-afs, coreteam,
intel-wired-lan, linux-serial, linux-input, linux-mmc, Kees Cook,
linux-media, linux-pm, intel-gfx, linux-sctp, linux-mediatek,
linux-nvme, storagedev, ceph-devel, linux-arm-kernel, linux-nfs,
Jiri Kosina, linux-parisc, netdev, linux-usb, Nick Desaulniers,
LKML, iommu, netfilter-devel, linux-crypto, bpf, linuxppc-dev
In-Reply-To: <20200909223602.GJ87483@ziepe.ca>
On Wed, 2020-09-09 at 19:36 -0300, Jason Gunthorpe wrote:
> On Wed, Sep 09, 2020 at 01:06:39PM -0700, Joe Perches wrote:
> > fallthrough to a separate case/default label break; isn't very readable.
> >
> > Convert pseudo-keyword fallthrough; statements to a simple break; when
> > the next label is case or default and the only statement in the next
> > label block is break;
> >
> > Found using:
> >
> > $ grep-2.5.4 -rP --include=*.[ch] -n "fallthrough;(\s*(case\s+\w+|default)\s*:\s*){1,7}break;" *
> >
> > Miscellanea:
> >
> > o Move or coalesce a couple label blocks above a default: block.
> >
> > Signed-off-by: Joe Perches <joe@perches.com>
> > ---
> >
> > Compiled allyesconfig x86-64 only.
> > A few files for other arches were not compiled.
>
> IB part looks OK, I prefer it like this
>
> You could do the same for continue as well, I saw a few of those..
I saw some continue uses as well but wasn't sure
and didn't look to see if the switch/case with
continue was in a for/while loop.
^ permalink raw reply
* Re: [trivial PATCH] treewide: Convert switch/case fallthrough; to break;
From: Jason Gunthorpe @ 2020-09-09 22:36 UTC (permalink / raw)
To: Joe Perches
Cc: linux-wireless, linux-fbdev, oss-drivers, nouveau, alsa-devel,
dri-devel, linux-mips, linux-ide, dm-devel, linux-mtd, linux-i2c,
sparclinux, kvmarm, linux-rtc, linux-s390, linux-scsi, dccp,
linux-rdma, linux-atm-general, linux-afs, coreteam,
intel-wired-lan, linux-serial, linux-input, linux-mmc, Kees Cook,
linux-media, linux-pm, intel-gfx, linux-sctp, linux-mediatek,
linux-nvme, storagedev, ceph-devel, linux-arm-kernel, linux-nfs,
Jiri Kosina, linux-parisc, netdev, linux-usb, Nick Desaulniers,
LKML, iommu, netfilter-devel, linux-crypto, bpf, linuxppc-dev
In-Reply-To: <e6387578c75736d61b2fe70d9783d91329a97eb4.camel@perches.com>
On Wed, Sep 09, 2020 at 01:06:39PM -0700, Joe Perches wrote:
> fallthrough to a separate case/default label break; isn't very readable.
>
> Convert pseudo-keyword fallthrough; statements to a simple break; when
> the next label is case or default and the only statement in the next
> label block is break;
>
> Found using:
>
> $ grep-2.5.4 -rP --include=*.[ch] -n "fallthrough;(\s*(case\s+\w+|default)\s*:\s*){1,7}break;" *
>
> Miscellanea:
>
> o Move or coalesce a couple label blocks above a default: block.
>
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>
> Compiled allyesconfig x86-64 only.
> A few files for other arches were not compiled.
IB part looks OK, I prefer it like this
You could do the same for continue as well, I saw a few of those..
Thanks,
Jason
^ permalink raw reply
* Re: [trivial PATCH] treewide: Convert switch/case fallthrough; to break;
From: Keith Busch @ 2020-09-09 20:55 UTC (permalink / raw)
To: Joe Perches
Cc: linux-wireless, linux-fbdev, oss-drivers, nouveau, alsa-devel,
dri-devel, linux-mips, linux-ide, dm-devel, linux-mtd, linux-i2c,
sparclinux, kvmarm, linux-rtc, linux-s390, linux-scsi, dccp,
linux-rdma, linux-atm-general, linux-afs, coreteam,
intel-wired-lan, linux-serial, linux-input, linux-mmc, Kees Cook,
linux-media, linux-pm, intel-gfx, linux-sctp, linux-mediatek,
linux-nvme, storagedev, ceph-devel, linux-arm-kernel, linux-nfs,
Jiri Kosina, linux-parisc, netdev, linux-usb, Nick Desaulniers,
LKML, iommu, netfilter-devel, linux-crypto, bpf, linuxppc-dev
In-Reply-To: <e6387578c75736d61b2fe70d9783d91329a97eb4.camel@perches.com>
On Wed, Sep 09, 2020 at 01:06:39PM -0700, Joe Perches wrote:
> 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.
^ permalink raw reply
* Re: remove the last set_fs() in common code, and remove it for x86 and powerpc v3
From: Linus Torvalds @ 2020-09-09 21:33 UTC (permalink / raw)
To: Segher Boessenkool
Cc: linux-arch, Kees Cook, the arch/x86 maintainers, Nick Desaulniers,
Linux Kernel Mailing List, Christoph Hellwig, Luis Chamberlain,
Al Viro, linux-fsdevel, linuxppc-dev, Alexey Dobriyan
In-Reply-To: <20200909184001.GB28786@gate.crashing.org>
On Wed, Sep 9, 2020 at 11:42 AM Segher Boessenkool
<segher@kernel.crashing.org> wrote:
>
> It will not work like this in GCC, no. The LLVM people know about that.
> I do not know why they insist on pushing this, being incompatible and
> everything.
Umm. Since they'd be the ones supporting this, *gcc* would be the
incompatible one, not clang.
Like it or not, clang is becoming a major kernel compiler. It's
already basically used for all android uses afaik.
So I'd phrase it differently. If gcc is planning on doing some
different model for asm goto with outputs, that would be the
incompatible case.
I'm not sure how gcc could do it differently. The only possible
difference I see is
(a) not doing it at all
(b) doing the "all goto targets have the outputs" case
and honestly, (b) is actually inferior for the error cases, even if to
a compiler person it might feel like the "RightThing(tm)" to do.
Because when an exception happens, the outputs simply won't be
initialized.
Anyway, for either of those cases, the kernel won't care either way.
We'll have to support the non-goto case for many years even if
everybody were to magically implement it today, so it's not like this
is a "you have to do it" thing.
Linus
^ permalink raw reply
* Re: [trivial PATCH] treewide: Convert switch/case fallthrough; to break;
From: Gustavo A. R. Silva @ 2020-09-09 20:38 UTC (permalink / raw)
To: Joe Perches, LKML, Jiri Kosina
Cc: linux-wireless, linux-fbdev, oss-drivers, nouveau, alsa-devel,
dri-devel, linux-ide, dm-devel, linux-mtd, linux-i2c, sparclinux,
kvmarm, linux-rtc, linux-s390, linux-scsi, dccp, linux-rdma,
linux-atm-general, linux-afs, coreteam, intel-wired-lan,
linux-serial, linux-input, linux-mmc, Kees Cook, linux-media,
linux-pm, intel-gfx, linux-sctp, linux-mediatek, linux-nvme,
storagedev, ceph-devel, linux-arm-kernel, linux-nfs, linux-parisc,
netdev, linux-usb, Nick Desaulniers, linux-mips, iommu,
netfilter-devel, linux-crypto, bpf, linuxppc-dev
In-Reply-To: <e6387578c75736d61b2fe70d9783d91329a97eb4.camel@perches.com>
On 9/9/20 15:06, Joe Perches wrote:
> fallthrough to a separate case/default label break; isn't very readable.
>
> Convert pseudo-keyword fallthrough; statements to a simple break; when
> the next label is case or default and the only statement in the next
> label block is break;
>
> Found using:
>
> $ grep-2.5.4 -rP --include=*.[ch] -n "fallthrough;(\s*(case\s+\w+|default)\s*:\s*){1,7}break;" *
>
> Miscellanea:
>
> o Move or coalesce a couple label blocks above a default: block.
>
> Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: Gustavo A. R. Silva <gustavoars@kernel.org>
Thanks
--
Gustavo
> ---
>
> Compiled allyesconfig x86-64 only.
> A few files for other arches were not compiled.
>
> arch/arm/mach-mmp/pm-pxa910.c | 2 +-
> arch/arm64/kvm/handle_exit.c | 2 +-
> arch/mips/kernel/cpu-probe.c | 2 +-
> arch/mips/math-emu/cp1emu.c | 2 +-
> arch/s390/pci/pci.c | 2 +-
> crypto/tcrypt.c | 4 ++--
> drivers/ata/sata_mv.c | 2 +-
> drivers/atm/lanai.c | 2 +-
> drivers/gpu/drm/i915/display/intel_sprite.c | 2 +-
> drivers/gpu/drm/nouveau/nvkm/engine/disp/hdmi.c | 2 +-
> drivers/hid/wacom_wac.c | 2 +-
> drivers/i2c/busses/i2c-i801.c | 2 +-
> drivers/infiniband/ulp/rtrs/rtrs-clt.c | 14 +++++++-------
> drivers/infiniband/ulp/rtrs/rtrs-srv.c | 6 +++---
> drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c | 2 +-
> drivers/irqchip/irq-vic.c | 4 ++--
> drivers/md/dm.c | 2 +-
> drivers/media/dvb-frontends/drxd_hard.c | 2 +-
> drivers/media/i2c/ov5640.c | 2 +-
> drivers/media/i2c/ov6650.c | 5 ++---
> drivers/media/i2c/smiapp/smiapp-core.c | 2 +-
> drivers/media/i2c/tvp5150.c | 2 +-
> drivers/media/pci/ddbridge/ddbridge-core.c | 2 +-
> drivers/media/usb/cpia2/cpia2_core.c | 2 +-
> drivers/mfd/iqs62x.c | 3 +--
> drivers/mmc/host/atmel-mci.c | 2 +-
> drivers/mtd/nand/raw/nandsim.c | 2 +-
> drivers/net/ethernet/intel/e1000e/phy.c | 2 +-
> drivers/net/ethernet/intel/fm10k/fm10k_pf.c | 2 +-
> drivers/net/ethernet/intel/i40e/i40e_adminq.c | 2 +-
> drivers/net/ethernet/intel/i40e/i40e_txrx.c | 2 +-
> drivers/net/ethernet/intel/iavf/iavf_txrx.c | 2 +-
> drivers/net/ethernet/intel/igb/e1000_phy.c | 2 +-
> drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c | 2 +-
> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 +-
> drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c | 2 +-
> drivers/net/ethernet/intel/ixgbevf/vf.c | 2 +-
> drivers/net/ethernet/netronome/nfp/nfpcore/nfp6000_pcie.c | 2 +-
> drivers/net/ethernet/qlogic/qed/qed_mcp.c | 2 +-
> drivers/net/ethernet/sfc/falcon/farch.c | 2 +-
> drivers/net/ethernet/sfc/farch.c | 2 +-
> drivers/net/phy/adin.c | 3 +--
> drivers/net/usb/pegasus.c | 4 ++--
> drivers/net/usb/usbnet.c | 2 +-
> drivers/net/wireless/ath/ath5k/eeprom.c | 2 +-
> drivers/net/wireless/mediatek/mt7601u/dma.c | 8 ++++----
> drivers/nvme/host/core.c | 12 ++++++------
> drivers/pcmcia/db1xxx_ss.c | 4 ++--
> drivers/power/supply/abx500_chargalg.c | 2 +-
> drivers/power/supply/charger-manager.c | 2 +-
> drivers/rtc/rtc-pcf85063.c | 2 +-
> drivers/s390/scsi/zfcp_fsf.c | 2 +-
> drivers/scsi/aic7xxx/aic79xx_core.c | 4 ++--
> drivers/scsi/aic94xx/aic94xx_tmf.c | 2 +-
> drivers/scsi/lpfc/lpfc_sli.c | 2 +-
> drivers/scsi/smartpqi/smartpqi_init.c | 2 +-
> drivers/scsi/sr.c | 2 +-
> drivers/tty/serial/sunsu.c | 2 +-
> drivers/tty/serial/sunzilog.c | 2 +-
> drivers/tty/vt/vt_ioctl.c | 2 +-
> drivers/usb/dwc3/core.c | 2 +-
> drivers/usb/gadget/legacy/inode.c | 2 +-
> drivers/usb/gadget/udc/pxa25x_udc.c | 4 ++--
> drivers/usb/host/ohci-hcd.c | 2 +-
> drivers/usb/isp1760/isp1760-hcd.c | 2 +-
> drivers/usb/musb/cppi_dma.c | 2 +-
> drivers/usb/phy/phy-fsl-usb.c | 2 +-
> drivers/video/fbdev/stifb.c | 2 +-
> fs/afs/yfsclient.c | 8 ++++----
> fs/ceph/dir.c | 2 +-
> fs/nfs/nfs4proc.c | 2 +-
> fs/nfs_common/nfsacl.c | 2 +-
> kernel/bpf/verifier.c | 2 +-
> kernel/sched/topology.c | 2 +-
> kernel/trace/trace_events_filter.c | 2 +-
> net/dccp/output.c | 2 +-
> net/ipv4/ip_output.c | 2 +-
> net/netfilter/nf_tables_api.c | 2 +-
> net/rxrpc/input.c | 4 ++--
> net/sctp/outqueue.c | 2 +-
> sound/soc/codecs/ak4613.c | 2 +-
> sound/soc/codecs/jz4770.c | 2 +-
> 82 files changed, 109 insertions(+), 112 deletions(-)
>
> diff --git a/arch/arm/mach-mmp/pm-pxa910.c b/arch/arm/mach-mmp/pm-pxa910.c
> index 1d71d73c1862..dcf2482a9e6c 100644
> --- a/arch/arm/mach-mmp/pm-pxa910.c
> +++ b/arch/arm/mach-mmp/pm-pxa910.c
> @@ -161,7 +161,7 @@ void pxa910_pm_enter_lowpower_mode(int state)
> idle_cfg |= APMU_MOH_IDLE_CFG_MOH_PWRDWN;
> idle_cfg |= APMU_MOH_IDLE_CFG_MOH_PWR_SW(3)
> | APMU_MOH_IDLE_CFG_MOH_L2_PWR_SW(3);
> - fallthrough;
> + break;
> case POWER_MODE_CORE_INTIDLE:
> break;
> }
> diff --git a/arch/arm64/kvm/handle_exit.c b/arch/arm64/kvm/handle_exit.c
> index 5d690d60ccad..bf3d54b0a233 100644
> --- a/arch/arm64/kvm/handle_exit.c
> +++ b/arch/arm64/kvm/handle_exit.c
> @@ -128,7 +128,7 @@ static int kvm_handle_guest_debug(struct kvm_vcpu *vcpu)
> switch (ESR_ELx_EC(esr)) {
> case ESR_ELx_EC_WATCHPT_LOW:
> run->debug.arch.far = vcpu->arch.fault.far_el2;
> - fallthrough;
> + break;
> case ESR_ELx_EC_SOFTSTP_LOW:
> case ESR_ELx_EC_BREAKPT_LOW:
> case ESR_ELx_EC_BKPT32:
> diff --git a/arch/mips/kernel/cpu-probe.c b/arch/mips/kernel/cpu-probe.c
> index e2955f1f6316..6ddc70211a0f 100644
> --- a/arch/mips/kernel/cpu-probe.c
> +++ b/arch/mips/kernel/cpu-probe.c
> @@ -1823,7 +1823,7 @@ static inline void cpu_probe_mips(struct cpuinfo_mips *c, unsigned int cpu)
> fallthrough;
> case CPU_I6400:
> c->options |= MIPS_CPU_SHARED_FTLB_RAM;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/arch/mips/math-emu/cp1emu.c b/arch/mips/math-emu/cp1emu.c
> index 587cf1d115e8..9c8f8539ec5d 100644
> --- a/arch/mips/math-emu/cp1emu.c
> +++ b/arch/mips/math-emu/cp1emu.c
> @@ -1224,7 +1224,7 @@ static int cop1Emulate(struct pt_regs *xcp, struct mips_fpu_struct *ctx,
> case bctl_op:
> if (cpu_has_mips_2_3_4_5_r)
> likely = 1;
> - fallthrough;
> + break;
> case bct_op:
> break;
> }
> diff --git a/arch/s390/pci/pci.c b/arch/s390/pci/pci.c
> index 4b62d6b55024..5b1e412bbd32 100644
> --- a/arch/s390/pci/pci.c
> +++ b/arch/s390/pci/pci.c
> @@ -743,7 +743,7 @@ void zpci_release_device(struct kref *kref)
> zpci_cleanup_bus_resources(zdev);
> zpci_bus_device_unregister(zdev);
> zpci_destroy_iommu(zdev);
> - fallthrough;
> + break;
> default:
> break;
> }
> 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;
>
> @@ -2587,7 +2587,7 @@ static int do_test(const char *alg, u32 type, u32 mask, int m, u32 num_mb)
> test_mb_ahash_speed("streebog512", sec,
> generic_hash_speed_template, num_mb);
> if (mode > 400 && mode < 500) break;
> - fallthrough;
> + break;
> case 499:
> break;
>
> diff --git a/drivers/ata/sata_mv.c b/drivers/ata/sata_mv.c
> index 664ef658a955..4d6cce2352bd 100644
> --- a/drivers/ata/sata_mv.c
> +++ b/drivers/ata/sata_mv.c
> @@ -2044,7 +2044,7 @@ static enum ata_completion_errors mv_qc_prep(struct ata_queued_cmd *qc)
> case ATA_PROT_DMA:
> if (tf->command == ATA_CMD_DSM)
> return AC_ERR_OK;
> - fallthrough;
> + break;
> case ATA_PROT_NCQ:
> break; /* continue below */
> case ATA_PROT_PIO:
> diff --git a/drivers/atm/lanai.c b/drivers/atm/lanai.c
> index ac811cfa6843..972a6837a20e 100644
> --- a/drivers/atm/lanai.c
> +++ b/drivers/atm/lanai.c
> @@ -2019,7 +2019,7 @@ static int lanai_normalize_ci(struct lanai_dev *lanai,
> switch (*vpip) {
> case ATM_VPI_ANY:
> *vpip = 0;
> - fallthrough;
> + break;
> case 0:
> break;
> default:
> diff --git a/drivers/gpu/drm/i915/display/intel_sprite.c b/drivers/gpu/drm/i915/display/intel_sprite.c
> index 5ac0dbf0e03d..35ac539cc2b1 100644
> --- a/drivers/gpu/drm/i915/display/intel_sprite.c
> +++ b/drivers/gpu/drm/i915/display/intel_sprite.c
> @@ -2861,7 +2861,7 @@ static bool gen12_plane_format_mod_supported(struct drm_plane *_plane,
> case I915_FORMAT_MOD_Y_TILED_GEN12_MC_CCS:
> if (!gen12_plane_supports_mc_ccs(dev_priv, plane->id))
> return false;
> - fallthrough;
> + break;
> case DRM_FORMAT_MOD_LINEAR:
> case I915_FORMAT_MOD_X_TILED:
> case I915_FORMAT_MOD_Y_TILED:
> diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/disp/hdmi.c b/drivers/gpu/drm/nouveau/nvkm/engine/disp/hdmi.c
> index 1ccfc8314812..bc83cf098e25 100644
> --- a/drivers/gpu/drm/nouveau/nvkm/engine/disp/hdmi.c
> +++ b/drivers/gpu/drm/nouveau/nvkm/engine/disp/hdmi.c
> @@ -71,7 +71,7 @@ void pack_hdmi_infoframe(struct packed_hdmi_infoframe *packed_frame,
> fallthrough;
> case 1:
> header |= raw_frame[0];
> - fallthrough;
> + break;
> case 0:
> break;
> }
> diff --git a/drivers/hid/wacom_wac.c b/drivers/hid/wacom_wac.c
> index 83dfec327c42..822dc15b59b6 100644
> --- a/drivers/hid/wacom_wac.c
> +++ b/drivers/hid/wacom_wac.c
> @@ -3833,7 +3833,7 @@ int wacom_setup_touch_input_capabilities(struct input_dev *input_dev,
> case MTTPC_B:
> case TABLETPC2FG:
> input_mt_init_slots(input_dev, features->touch_max, INPUT_MT_DIRECT);
> - fallthrough;
> + break;
>
> case TABLETPC:
> case TABLETPCE:
> diff --git a/drivers/i2c/busses/i2c-i801.c b/drivers/i2c/busses/i2c-i801.c
> index e32ef3f01fe8..b13b1cbcac29 100644
> --- a/drivers/i2c/busses/i2c-i801.c
> +++ b/drivers/i2c/busses/i2c-i801.c
> @@ -1785,7 +1785,7 @@ static int i801_probe(struct pci_dev *dev, const struct pci_device_id *id)
> fallthrough;
> case PCI_DEVICE_ID_INTEL_82801CA_3:
> priv->features |= FEATURE_HOST_NOTIFY;
> - fallthrough;
> + break;
> case PCI_DEVICE_ID_INTEL_82801BA_2:
> case PCI_DEVICE_ID_INTEL_82801AB_3:
> case PCI_DEVICE_ID_INTEL_82801AA_3:
> diff --git a/drivers/infiniband/ulp/rtrs/rtrs-clt.c b/drivers/infiniband/ulp/rtrs/rtrs-clt.c
> index 776e89231c52..55339cad408a 100644
> --- a/drivers/infiniband/ulp/rtrs/rtrs-clt.c
> +++ b/drivers/infiniband/ulp/rtrs/rtrs-clt.c
> @@ -209,7 +209,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
> switch (old_state) {
> case RTRS_CLT_RECONNECTING:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -220,7 +220,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
> case RTRS_CLT_CONNECTING_ERR:
> case RTRS_CLT_CLOSED:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -229,7 +229,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
> switch (old_state) {
> case RTRS_CLT_CONNECTING:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -238,7 +238,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
> switch (old_state) {
> case RTRS_CLT_CONNECTING:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -250,7 +250,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
> case RTRS_CLT_RECONNECTING:
> case RTRS_CLT_CONNECTED:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -259,7 +259,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
> switch (old_state) {
> case RTRS_CLT_CLOSING:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -268,7 +268,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
> switch (old_state) {
> case RTRS_CLT_CLOSED:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/infiniband/ulp/rtrs/rtrs-srv.c b/drivers/infiniband/ulp/rtrs/rtrs-srv.c
> index b61a18e57aeb..24e53b39a79c 100644
> --- a/drivers/infiniband/ulp/rtrs/rtrs-srv.c
> +++ b/drivers/infiniband/ulp/rtrs/rtrs-srv.c
> @@ -78,7 +78,7 @@ static bool __rtrs_srv_change_state(struct rtrs_srv_sess *sess,
> switch (old_state) {
> case RTRS_SRV_CONNECTING:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -88,7 +88,7 @@ static bool __rtrs_srv_change_state(struct rtrs_srv_sess *sess,
> case RTRS_SRV_CONNECTING:
> case RTRS_SRV_CONNECTED:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -97,7 +97,7 @@ static bool __rtrs_srv_change_state(struct rtrs_srv_sess *sess,
> switch (old_state) {
> case RTRS_SRV_CLOSING:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c b/drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c
> index c192544e874b..743db1abec40 100644
> --- a/drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c
> +++ b/drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c
> @@ -3777,7 +3777,7 @@ static int arm_smmu_device_hw_probe(struct arm_smmu_device *smmu)
> switch (FIELD_GET(IDR0_TTF, reg)) {
> case IDR0_TTF_AARCH32_64:
> smmu->ias = 40;
> - fallthrough;
> + break;
> case IDR0_TTF_AARCH64:
> break;
> default:
> diff --git a/drivers/irqchip/irq-vic.c b/drivers/irqchip/irq-vic.c
> index e46036374227..10ff0a5c225a 100644
> --- a/drivers/irqchip/irq-vic.c
> +++ b/drivers/irqchip/irq-vic.c
> @@ -453,10 +453,10 @@ static void __init __vic_init(void __iomem *base, int parent_irq, int irq_start,
> case AMBA_VENDOR_ST:
> vic_init_st(base, irq_start, vic_sources, node);
> return;
> + case AMBA_VENDOR_ARM:
> + break;
> default:
> printk(KERN_WARNING "VIC: unknown vendor, continuing anyways\n");
> - fallthrough;
> - case AMBA_VENDOR_ARM:
> break;
> }
>
> diff --git a/drivers/md/dm.c b/drivers/md/dm.c
> index 3dedd9cc4fb6..dc71573d5b09 100644
> --- a/drivers/md/dm.c
> +++ b/drivers/md/dm.c
> @@ -1021,7 +1021,7 @@ static void clone_endio(struct bio *bio)
> switch (r) {
> case DM_ENDIO_REQUEUE:
> error = BLK_STS_DM_REQUEUE;
> - fallthrough;
> + break;
> case DM_ENDIO_DONE:
> break;
> case DM_ENDIO_INCOMPLETE:
> diff --git a/drivers/media/dvb-frontends/drxd_hard.c b/drivers/media/dvb-frontends/drxd_hard.c
> index 45f982863904..d6592e764a92 100644
> --- a/drivers/media/dvb-frontends/drxd_hard.c
> +++ b/drivers/media/dvb-frontends/drxd_hard.c
> @@ -1519,7 +1519,7 @@ static int SetDeviceTypeId(struct drxd_state *state)
> break;
> case 6:
> state->diversity = 1;
> - fallthrough;
> + break;
> case 5:
> case 8:
> break;
> diff --git a/drivers/media/i2c/ov5640.c b/drivers/media/i2c/ov5640.c
> index 637687d761f2..855d3aba711a 100644
> --- a/drivers/media/i2c/ov5640.c
> +++ b/drivers/media/i2c/ov5640.c
> @@ -3010,7 +3010,7 @@ static int ov5640_probe(struct i2c_client *client)
> switch (rotation) {
> case 180:
> sensor->upside_down = true;
> - fallthrough;
> + break;
> case 0:
> break;
> default:
> diff --git a/drivers/media/i2c/ov6650.c b/drivers/media/i2c/ov6650.c
> index d73f9f540932..fde56572dce8 100644
> --- a/drivers/media/i2c/ov6650.c
> +++ b/drivers/media/i2c/ov6650.c
> @@ -685,17 +685,16 @@ static int ov6650_set_fmt(struct v4l2_subdev *sd,
> switch (mf->code) {
> case MEDIA_BUS_FMT_Y10_1X10:
> mf->code = MEDIA_BUS_FMT_Y8_1X8;
> - fallthrough;
> + break;
> case MEDIA_BUS_FMT_Y8_1X8:
> case MEDIA_BUS_FMT_YVYU8_2X8:
> case MEDIA_BUS_FMT_YUYV8_2X8:
> case MEDIA_BUS_FMT_VYUY8_2X8:
> case MEDIA_BUS_FMT_UYVY8_2X8:
> + case MEDIA_BUS_FMT_SBGGR8_1X8:
> break;
> default:
> mf->code = MEDIA_BUS_FMT_SBGGR8_1X8;
> - fallthrough;
> - case MEDIA_BUS_FMT_SBGGR8_1X8:
> break;
> }
>
> diff --git a/drivers/media/i2c/smiapp/smiapp-core.c b/drivers/media/i2c/smiapp/smiapp-core.c
> index 6fc0680a93d0..8bfba407b8f1 100644
> --- a/drivers/media/i2c/smiapp/smiapp-core.c
> +++ b/drivers/media/i2c/smiapp/smiapp-core.c
> @@ -2795,7 +2795,7 @@ static struct smiapp_hwconfig *smiapp_get_hwconfig(struct device *dev)
> case 180:
> hwcfg->module_board_orient =
> SMIAPP_MODULE_BOARD_ORIENT_180;
> - fallthrough;
> + break;
> case 0:
> break;
> default:
> diff --git a/drivers/media/i2c/tvp5150.c b/drivers/media/i2c/tvp5150.c
> index 7d9401219a3a..df174089e74d 100644
> --- a/drivers/media/i2c/tvp5150.c
> +++ b/drivers/media/i2c/tvp5150.c
> @@ -293,7 +293,7 @@ static void tvp5150_selmux(struct v4l2_subdev *sd)
> switch (decoder->input) {
> case TVP5150_COMPOSITE1:
> input |= 2;
> - fallthrough;
> + break;
> case TVP5150_COMPOSITE0:
> break;
> case TVP5150_SVIDEO:
> diff --git a/drivers/media/pci/ddbridge/ddbridge-core.c b/drivers/media/pci/ddbridge/ddbridge-core.c
> index 92fe051c672f..426c9e0152d8 100644
> --- a/drivers/media/pci/ddbridge/ddbridge-core.c
> +++ b/drivers/media/pci/ddbridge/ddbridge-core.c
> @@ -1336,7 +1336,7 @@ static void dvb_input_detach(struct ddb_input *input)
> fallthrough;
> case 0x10:
> dvb_dmx_release(&dvb->demux);
> - fallthrough;
> + break;
> case 0x01:
> break;
> }
> diff --git a/drivers/media/usb/cpia2/cpia2_core.c b/drivers/media/usb/cpia2/cpia2_core.c
> index e747548ab286..cbef274d4f95 100644
> --- a/drivers/media/usb/cpia2/cpia2_core.c
> +++ b/drivers/media/usb/cpia2/cpia2_core.c
> @@ -1751,7 +1751,7 @@ int cpia2_set_fps(struct camera_data *cam, int framerate)
> CPIA2_VP_SENSOR_FLAGS_500) {
> return -EINVAL;
> }
> - fallthrough;
> + break;
> case CPIA2_VP_FRAMERATE_15:
> case CPIA2_VP_FRAMERATE_12_5:
> case CPIA2_VP_FRAMERATE_7_5:
> diff --git a/drivers/mfd/iqs62x.c b/drivers/mfd/iqs62x.c
> index 761b4ef3a381..5671482ec8fe 100644
> --- a/drivers/mfd/iqs62x.c
> +++ b/drivers/mfd/iqs62x.c
> @@ -490,8 +490,7 @@ static irqreturn_t iqs62x_irq(int irq, void *context)
>
> case IQS62X_EVENT_HYST:
> event_map[i] <<= iqs62x->dev_desc->hyst_shift;
> -
> - fallthrough;
> + break;
>
> case IQS62X_EVENT_WHEEL:
> case IQS62X_EVENT_HALL:
> diff --git a/drivers/mmc/host/atmel-mci.c b/drivers/mmc/host/atmel-mci.c
> index 444bd3a0a922..8324312e4f42 100644
> --- a/drivers/mmc/host/atmel-mci.c
> +++ b/drivers/mmc/host/atmel-mci.c
> @@ -2435,7 +2435,7 @@ static void atmci_get_cap(struct atmel_mci *host)
> case 0x100:
> host->caps.has_bad_data_ordering = 0;
> host->caps.need_reset_after_xfer = 0;
> - fallthrough;
> + break;
> case 0x0:
> break;
> default:
> diff --git a/drivers/mtd/nand/raw/nandsim.c b/drivers/mtd/nand/raw/nandsim.c
> index f5a53aac3c5f..b07934247297 100644
> --- a/drivers/mtd/nand/raw/nandsim.c
> +++ b/drivers/mtd/nand/raw/nandsim.c
> @@ -2286,7 +2286,7 @@ static int __init ns_init_module(void)
> fallthrough;
> case 1:
> chip->bbt_options |= NAND_BBT_USE_FLASH;
> - fallthrough;
> + break;
> case 0:
> break;
> default:
> diff --git a/drivers/net/ethernet/intel/e1000e/phy.c b/drivers/net/ethernet/intel/e1000e/phy.c
> index e11c877595fb..9fec7cc52710 100644
> --- a/drivers/net/ethernet/intel/e1000e/phy.c
> +++ b/drivers/net/ethernet/intel/e1000e/phy.c
> @@ -607,7 +607,7 @@ static s32 e1000_set_master_slave_mode(struct e1000_hw *hw)
> break;
> case e1000_ms_auto:
> phy_data &= ~CTL1000_ENABLE_MASTER;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/net/ethernet/intel/fm10k/fm10k_pf.c b/drivers/net/ethernet/intel/fm10k/fm10k_pf.c
> index c0780c3624c8..1c601d7464dd 100644
> --- a/drivers/net/ethernet/intel/fm10k/fm10k_pf.c
> +++ b/drivers/net/ethernet/intel/fm10k/fm10k_pf.c
> @@ -1329,7 +1329,7 @@ static u8 fm10k_iov_supported_xcast_mode_pf(struct fm10k_vf_info *vf_info,
> case FM10K_XCAST_MODE_NONE:
> if (vf_flags & FM10K_VF_FLAG_NONE_CAPABLE)
> return FM10K_XCAST_MODE_NONE;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/net/ethernet/intel/i40e/i40e_adminq.c b/drivers/net/ethernet/intel/i40e/i40e_adminq.c
> index c897a2863e4f..857b699f02c9 100644
> --- a/drivers/net/ethernet/intel/i40e/i40e_adminq.c
> +++ b/drivers/net/ethernet/intel/i40e/i40e_adminq.c
> @@ -541,7 +541,7 @@ static void i40e_set_hw_flags(struct i40e_hw *hw)
> (aq->api_maj_ver == 1 &&
> aq->api_min_ver >= I40E_MINOR_VER_GET_LINK_INFO_X722))
> hw->flags |= I40E_HW_FLAG_AQ_PHY_ACCESS_CAPABLE;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/net/ethernet/intel/i40e/i40e_txrx.c b/drivers/net/ethernet/intel/i40e/i40e_txrx.c
> index 91ab824926b9..ef4f3dbc7b7e 100644
> --- a/drivers/net/ethernet/intel/i40e/i40e_txrx.c
> +++ b/drivers/net/ethernet/intel/i40e/i40e_txrx.c
> @@ -1690,7 +1690,7 @@ static inline void i40e_rx_checksum(struct i40e_vsi *vsi,
> case I40E_RX_PTYPE_INNER_PROT_UDP:
> case I40E_RX_PTYPE_INNER_PROT_SCTP:
> skb->ip_summed = CHECKSUM_UNNECESSARY;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/net/ethernet/intel/iavf/iavf_txrx.c b/drivers/net/ethernet/intel/iavf/iavf_txrx.c
> index 256fa07d54d5..c2c1ef255008 100644
> --- a/drivers/net/ethernet/intel/iavf/iavf_txrx.c
> +++ b/drivers/net/ethernet/intel/iavf/iavf_txrx.c
> @@ -1007,7 +1007,7 @@ static inline void iavf_rx_checksum(struct iavf_vsi *vsi,
> case IAVF_RX_PTYPE_INNER_PROT_UDP:
> case IAVF_RX_PTYPE_INNER_PROT_SCTP:
> skb->ip_summed = CHECKSUM_UNNECESSARY;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/net/ethernet/intel/igb/e1000_phy.c b/drivers/net/ethernet/intel/igb/e1000_phy.c
> index 8c8eb82e6272..f8f7ffbc45f0 100644
> --- a/drivers/net/ethernet/intel/igb/e1000_phy.c
> +++ b/drivers/net/ethernet/intel/igb/e1000_phy.c
> @@ -2621,7 +2621,7 @@ static s32 igb_set_master_slave_mode(struct e1000_hw *hw)
> break;
> case e1000_ms_auto:
> phy_data &= ~CR_1000T_MS_ENABLE;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c
> index 8d3798a32f0e..1549f0342384 100644
> --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c
> +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c
> @@ -1589,7 +1589,7 @@ s32 ixgbe_fdir_set_input_mask_82599(struct ixgbe_hw *hw,
> case 0x0000:
> /* Mask Flex Bytes */
> fdirm |= IXGBE_FDIRM_FLEX;
> - fallthrough;
> + break;
> case 0xFFFF:
> break;
> default:
> diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> index 0b675c34ce49..17e0fe4d380e 100644
> --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> @@ -5901,7 +5901,7 @@ void ixgbe_disable_tx(struct ixgbe_adapter *adapter)
> IXGBE_WRITE_REG(hw, IXGBE_DMATXCTL,
> (IXGBE_READ_REG(hw, IXGBE_DMATXCTL) &
> ~IXGBE_DMATXCTL_TE));
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c
> index 988db46bff0e..45b18708f5ed 100644
> --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c
> +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c
> @@ -1141,7 +1141,7 @@ static int ixgbe_update_vf_xcast_mode(struct ixgbe_adapter *adapter,
> /* promisc introduced in 1.3 version */
> if (xcast_mode == IXGBEVF_XCAST_MODE_PROMISC)
> return -EOPNOTSUPP;
> - fallthrough;
> + break;
> case ixgbe_mbox_api_13:
> case ixgbe_mbox_api_14:
> break;
> diff --git a/drivers/net/ethernet/intel/ixgbevf/vf.c b/drivers/net/ethernet/intel/ixgbevf/vf.c
> index bfe6dfcec4ab..7f14665b6bdf 100644
> --- a/drivers/net/ethernet/intel/ixgbevf/vf.c
> +++ b/drivers/net/ethernet/intel/ixgbevf/vf.c
> @@ -540,7 +540,7 @@ static s32 ixgbevf_update_xcast_mode(struct ixgbe_hw *hw, int xcast_mode)
> /* promisc introduced in 1.3 version */
> if (xcast_mode == IXGBEVF_XCAST_MODE_PROMISC)
> return -EOPNOTSUPP;
> - fallthrough;
> + break;
> case ixgbe_mbox_api_14:
> case ixgbe_mbox_api_13:
> break;
> diff --git a/drivers/net/ethernet/netronome/nfp/nfpcore/nfp6000_pcie.c b/drivers/net/ethernet/netronome/nfp/nfpcore/nfp6000_pcie.c
> index 252fe06f58aa..1d5b87079104 100644
> --- a/drivers/net/ethernet/netronome/nfp/nfpcore/nfp6000_pcie.c
> +++ b/drivers/net/ethernet/netronome/nfp/nfpcore/nfp6000_pcie.c
> @@ -345,7 +345,7 @@ static int matching_bar(struct nfp_bar *bar, u32 tgt, u32 act, u32 tok,
> baract = NFP_CPP_ACTION_RW;
> if (act == 0)
> act = NFP_CPP_ACTION_RW;
> - fallthrough;
> + break;
> case NFP_PCIE_BAR_PCIE2CPP_MapType_FIXED:
> break;
> default:
> diff --git a/drivers/net/ethernet/qlogic/qed/qed_mcp.c b/drivers/net/ethernet/qlogic/qed/qed_mcp.c
> index cd882c453394..1bffe5cb88f4 100644
> --- a/drivers/net/ethernet/qlogic/qed/qed_mcp.c
> +++ b/drivers/net/ethernet/qlogic/qed/qed_mcp.c
> @@ -3546,7 +3546,7 @@ qed_mcp_resc_allocation_msg(struct qed_hwfn *p_hwfn,
> switch (p_in_params->cmd) {
> case DRV_MSG_SET_RESOURCE_VALUE_MSG:
> mfw_resc_info.size = p_in_params->resc_max_val;
> - fallthrough;
> + break;
> case DRV_MSG_GET_RESOURCE_ALLOC_MSG:
> break;
> default:
> diff --git a/drivers/net/ethernet/sfc/falcon/farch.c b/drivers/net/ethernet/sfc/falcon/farch.c
> index fa1ade856b10..14f42c94809d 100644
> --- a/drivers/net/ethernet/sfc/falcon/farch.c
> +++ b/drivers/net/ethernet/sfc/falcon/farch.c
> @@ -1052,7 +1052,7 @@ ef4_farch_handle_rx_event(struct ef4_channel *channel, const ef4_qword_t *event)
> fallthrough;
> case FSE_CZ_RX_EV_HDR_TYPE_IPV4V6_UDP:
> flags |= EF4_RX_PKT_CSUMMED;
> - fallthrough;
> + break;
> case FSE_CZ_RX_EV_HDR_TYPE_IPV4V6_OTHER:
> case FSE_AZ_RX_EV_HDR_TYPE_OTHER:
> break;
> diff --git a/drivers/net/ethernet/sfc/farch.c b/drivers/net/ethernet/sfc/farch.c
> index e004524e14a8..cea0eb822473 100644
> --- a/drivers/net/ethernet/sfc/farch.c
> +++ b/drivers/net/ethernet/sfc/farch.c
> @@ -1038,7 +1038,7 @@ efx_farch_handle_rx_event(struct efx_channel *channel, const efx_qword_t *event)
> fallthrough;
> case FSE_CZ_RX_EV_HDR_TYPE_IPV4V6_UDP:
> flags |= EFX_RX_PKT_CSUMMED;
> - fallthrough;
> + break;
> case FSE_CZ_RX_EV_HDR_TYPE_IPV4V6_OTHER:
> case FSE_AZ_RX_EV_HDR_TYPE_OTHER:
> break;
> diff --git a/drivers/net/phy/adin.c b/drivers/net/phy/adin.c
> index 307f0ac1287b..95aeffe7482b 100644
> --- a/drivers/net/phy/adin.c
> +++ b/drivers/net/phy/adin.c
> @@ -366,10 +366,9 @@ static int adin_set_edpd(struct phy_device *phydev, u16 tx_interval)
>
> switch (tx_interval) {
> case 1000: /* 1 second */
> - fallthrough;
> case ETHTOOL_PHY_EDPD_DFLT_TX_MSECS:
> val |= ADIN1300_NRG_PD_TX_EN;
> - fallthrough;
> + break;
> case ETHTOOL_PHY_EDPD_NO_TX:
> break;
> default:
> diff --git a/drivers/net/usb/pegasus.c b/drivers/net/usb/pegasus.c
> index e92cb51a2c77..9adb26ee4a86 100644
> --- a/drivers/net/usb/pegasus.c
> +++ b/drivers/net/usb/pegasus.c
> @@ -627,10 +627,10 @@ static void write_bulk_callback(struct urb *urb)
> case -ESHUTDOWN:
> netif_dbg(pegasus, ifdown, net, "tx unlink, %d\n", status);
> return;
> + case 0:
> + break;
> default:
> netif_info(pegasus, tx_err, net, "TX status %d\n", status);
> - fallthrough;
> - case 0:
> break;
> }
>
> diff --git a/drivers/net/usb/usbnet.c b/drivers/net/usb/usbnet.c
> index 2b2a841cd938..56edd8c9819e 100644
> --- a/drivers/net/usb/usbnet.c
> +++ b/drivers/net/usb/usbnet.c
> @@ -110,7 +110,7 @@ int usbnet_get_endpoints(struct usbnet *dev, struct usb_interface *intf)
> if (!usb_endpoint_dir_in(&e->desc))
> continue;
> intr = 1;
> - fallthrough;
> + break;
> case USB_ENDPOINT_XFER_BULK:
> break;
> default:
> diff --git a/drivers/net/wireless/ath/ath5k/eeprom.c b/drivers/net/wireless/ath/ath5k/eeprom.c
> index 1fbc2c19848f..f5ea317f2a67 100644
> --- a/drivers/net/wireless/ath/ath5k/eeprom.c
> +++ b/drivers/net/wireless/ath/ath5k/eeprom.c
> @@ -1178,7 +1178,7 @@ ath5k_cal_data_offset_2413(struct ath5k_eeprom_info *ee, int mode)
> offset += ath5k_pdgains_size_2413(ee,
> AR5K_EEPROM_MODE_11A) +
> AR5K_EEPROM_N_5GHZ_CHAN / 2;
> - fallthrough;
> + break;
> case AR5K_EEPROM_MODE_11A:
> break;
> default:
> diff --git a/drivers/net/wireless/mediatek/mt7601u/dma.c b/drivers/net/wireless/mediatek/mt7601u/dma.c
> index 09f931d4598c..778be26d329f 100644
> --- a/drivers/net/wireless/mediatek/mt7601u/dma.c
> +++ b/drivers/net/wireless/mediatek/mt7601u/dma.c
> @@ -193,11 +193,11 @@ static void mt7601u_complete_rx(struct urb *urb)
> case -ESHUTDOWN:
> case -ENOENT:
> return;
> + case 0:
> + break;
> default:
> dev_err_ratelimited(dev->dev, "rx urb failed: %d\n",
> urb->status);
> - fallthrough;
> - case 0:
> break;
> }
>
> @@ -238,11 +238,11 @@ static void mt7601u_complete_tx(struct urb *urb)
> case -ESHUTDOWN:
> case -ENOENT:
> return;
> + case 0:
> + break;
> default:
> dev_err_ratelimited(dev->dev, "tx urb failed: %d\n",
> urb->status);
> - fallthrough;
> - case 0:
> break;
> }
>
> diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
> index ea1fa41fbba8..aea9f978861e 100644
> --- a/drivers/nvme/host/core.c
> +++ b/drivers/nvme/host/core.c
> @@ -365,7 +365,7 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
> case NVME_CTRL_RESETTING:
> case NVME_CTRL_CONNECTING:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -375,7 +375,7 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
> case NVME_CTRL_NEW:
> case NVME_CTRL_LIVE:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -385,7 +385,7 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
> case NVME_CTRL_NEW:
> case NVME_CTRL_RESETTING:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -396,7 +396,7 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
> case NVME_CTRL_RESETTING:
> case NVME_CTRL_CONNECTING:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -406,7 +406,7 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
> case NVME_CTRL_DELETING:
> case NVME_CTRL_DEAD:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> @@ -415,7 +415,7 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
> switch (old_state) {
> case NVME_CTRL_DELETING:
> changed = true;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/pcmcia/db1xxx_ss.c b/drivers/pcmcia/db1xxx_ss.c
> index a7c7c7cd2326..d5eec00aaf97 100644
> --- a/drivers/pcmcia/db1xxx_ss.c
> +++ b/drivers/pcmcia/db1xxx_ss.c
> @@ -258,7 +258,7 @@ static int db1x_pcmcia_configure(struct pcmcia_socket *skt,
> fallthrough;
> case 33:
> ++v;
> - fallthrough;
> + break;
> case 0:
> break;
> default:
> @@ -273,7 +273,7 @@ static int db1x_pcmcia_configure(struct pcmcia_socket *skt,
> case 33:
> case 50:
> ++p;
> - fallthrough;
> + break;
> case 0:
> break;
> default:
> diff --git a/drivers/power/supply/abx500_chargalg.c b/drivers/power/supply/abx500_chargalg.c
> index 175c4f3d7955..b847a1570ab0 100644
> --- a/drivers/power/supply/abx500_chargalg.c
> +++ b/drivers/power/supply/abx500_chargalg.c
> @@ -1419,7 +1419,7 @@ static void abx500_chargalg_algorithm(struct abx500_chargalg *di)
> abx500_chargalg_stop_charging(di);
> di->charge_status = POWER_SUPPLY_STATUS_DISCHARGING;
> abx500_chargalg_state_to(di, STATE_HANDHELD);
> - fallthrough;
> + break;
>
> case STATE_HANDHELD:
> break;
> diff --git a/drivers/power/supply/charger-manager.c b/drivers/power/supply/charger-manager.c
> index 07992821e252..ac7871a7684b 100644
> --- a/drivers/power/supply/charger-manager.c
> +++ b/drivers/power/supply/charger-manager.c
> @@ -585,7 +585,7 @@ static int cm_get_target_status(struct charger_manager *cm)
> case POWER_SUPPLY_STATUS_FULL:
> if (is_full_charged(cm))
> return POWER_SUPPLY_STATUS_FULL;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/rtc/rtc-pcf85063.c b/drivers/rtc/rtc-pcf85063.c
> index f8b99cb72959..65bb87cc8380 100644
> --- a/drivers/rtc/rtc-pcf85063.c
> +++ b/drivers/rtc/rtc-pcf85063.c
> @@ -353,7 +353,7 @@ static int pcf85063_load_capacitance(struct pcf85063 *pcf85063,
> default:
> dev_warn(&pcf85063->rtc->dev, "Unknown quartz-load-femtofarads value: %d. Assuming 7000",
> load);
> - fallthrough;
> + break;
> case 7000:
> break;
> case 12500:
> diff --git a/drivers/s390/scsi/zfcp_fsf.c b/drivers/s390/scsi/zfcp_fsf.c
> index 140186fe1d1e..2741a07df692 100644
> --- a/drivers/s390/scsi/zfcp_fsf.c
> +++ b/drivers/s390/scsi/zfcp_fsf.c
> @@ -2105,7 +2105,7 @@ static void zfcp_fsf_open_lun_handler(struct zfcp_fsf_req *req)
>
> case FSF_PORT_HANDLE_NOT_VALID:
> zfcp_erp_adapter_reopen(adapter, 0, "fsouh_1");
> - fallthrough;
> + break;
> case FSF_LUN_ALREADY_OPEN:
> break;
> case FSF_PORT_BOXED:
> diff --git a/drivers/scsi/aic7xxx/aic79xx_core.c b/drivers/scsi/aic7xxx/aic79xx_core.c
> index 1c617c0d5899..e8fa68d96cde 100644
> --- a/drivers/scsi/aic7xxx/aic79xx_core.c
> +++ b/drivers/scsi/aic7xxx/aic79xx_core.c
> @@ -8175,7 +8175,7 @@ ahd_search_qinfifo(struct ahd_softc *ahd, int target, char channel,
> if ((scb->flags & SCB_ACTIVE) == 0)
> printk("Inactive SCB in qinfifo\n");
> ahd_done_with_status(ahd, scb, status);
> - fallthrough;
> + break;
> case SEARCH_REMOVE:
> break;
> case SEARCH_PRINT:
> @@ -8295,7 +8295,7 @@ ahd_search_qinfifo(struct ahd_softc *ahd, int target, char channel,
> }
> case SEARCH_PRINT:
> printk(" 0x%x", SCB_GET_TAG(scb));
> - fallthrough;
> + break;
> case SEARCH_COUNT:
> break;
> }
> diff --git a/drivers/scsi/aic94xx/aic94xx_tmf.c b/drivers/scsi/aic94xx/aic94xx_tmf.c
> index 0eb6e206a2b4..fdd0f34fcb17 100644
> --- a/drivers/scsi/aic94xx/aic94xx_tmf.c
> +++ b/drivers/scsi/aic94xx/aic94xx_tmf.c
> @@ -490,7 +490,7 @@ int asd_abort_task(struct sas_task *task)
> switch (tcs.dl_opcode) {
> default:
> res = asd_clear_nexus(task);
> - fallthrough;
> + break;
> case TC_NO_ERROR:
> break;
> /* The task hasn't been sent to the device xor
> diff --git a/drivers/scsi/lpfc/lpfc_sli.c b/drivers/scsi/lpfc/lpfc_sli.c
> index e158cd77d387..253a4a41ebc9 100644
> --- a/drivers/scsi/lpfc/lpfc_sli.c
> +++ b/drivers/scsi/lpfc/lpfc_sli.c
> @@ -9339,7 +9339,7 @@ __lpfc_sli_issue_iocb_s3(struct lpfc_hba *phba, uint32_t ring_number,
> */
> if (piocb->iocb_cmpl)
> piocb->iocb_cmpl = NULL;
> - fallthrough;
> + break;
> case CMD_CREATE_XRI_CR:
> case CMD_CLOSE_XRI_CN:
> case CMD_CLOSE_XRI_CX:
> diff --git a/drivers/scsi/smartpqi/smartpqi_init.c b/drivers/scsi/smartpqi/smartpqi_init.c
> index 9d0229656681..f2be6feea226 100644
> --- a/drivers/scsi/smartpqi/smartpqi_init.c
> +++ b/drivers/scsi/smartpqi/smartpqi_init.c
> @@ -2937,7 +2937,7 @@ static int pqi_process_io_intr(struct pqi_ctrl_info *ctrl_info, struct pqi_queue
> case PQI_RESPONSE_IU_AIO_PATH_IO_SUCCESS:
> if (io_request->scmd)
> io_request->scmd->result = 0;
> - fallthrough;
> + break;
> case PQI_RESPONSE_IU_GENERAL_MANAGEMENT:
> break;
> case PQI_RESPONSE_IU_VENDOR_GENERAL:
> diff --git a/drivers/scsi/sr.c b/drivers/scsi/sr.c
> index 3b3a53c6a0de..1216396284f9 100644
> --- a/drivers/scsi/sr.c
> +++ b/drivers/scsi/sr.c
> @@ -880,7 +880,7 @@ static void get_sectorsize(struct scsi_cd *cd)
> fallthrough;
> case 2048:
> cd->capacity *= 4;
> - fallthrough;
> + break;
> case 512:
> break;
> default:
> diff --git a/drivers/tty/serial/sunsu.c b/drivers/tty/serial/sunsu.c
> index 319e5ceb6130..de3fbdcfa7f8 100644
> --- a/drivers/tty/serial/sunsu.c
> +++ b/drivers/tty/serial/sunsu.c
> @@ -514,7 +514,7 @@ static void receive_kbd_ms_chars(struct uart_sunsu_port *up, int is_break)
> switch (ret) {
> case 2:
> sunsu_change_mouse_baud(up);
> - fallthrough;
> + break;
> case 1:
> break;
>
> diff --git a/drivers/tty/serial/sunzilog.c b/drivers/tty/serial/sunzilog.c
> index 001e19d7c17d..a1f5c73be291 100644
> --- a/drivers/tty/serial/sunzilog.c
> +++ b/drivers/tty/serial/sunzilog.c
> @@ -306,7 +306,7 @@ static void sunzilog_kbdms_receive_chars(struct uart_sunzilog_port *up,
> switch (ret) {
> case 2:
> sunzilog_change_mouse_baud(up);
> - fallthrough;
> + break;
> case 1:
> break;
>
> diff --git a/drivers/tty/vt/vt_ioctl.c b/drivers/tty/vt/vt_ioctl.c
> index 2ea76a09e07f..c7ca691f1d2b 100644
> --- a/drivers/tty/vt/vt_ioctl.c
> +++ b/drivers/tty/vt/vt_ioctl.c
> @@ -255,7 +255,7 @@ static int vt_kdsetmode(struct vc_data *vc, unsigned long mode)
> case KD_TEXT0:
> case KD_TEXT1:
> mode = KD_TEXT;
> - fallthrough;
> + break;
> case KD_TEXT:
> break;
> default:
> diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
> index 2eb34c8b4065..85f04dca7ae9 100644
> --- a/drivers/usb/dwc3/core.c
> +++ b/drivers/usb/dwc3/core.c
> @@ -646,7 +646,7 @@ static int dwc3_phy_setup(struct dwc3 *dwc)
> if (!(reg & DWC3_GUSB2PHYCFG_ULPI_UTMI))
> break;
> }
> - fallthrough;
> + break;
> case DWC3_GHWPARAMS3_HSPHY_IFC_ULPI:
> default:
> break;
> diff --git a/drivers/usb/gadget/legacy/inode.c b/drivers/usb/gadget/legacy/inode.c
> index 1b430b36d0a6..261ec2dd52c6 100644
> --- a/drivers/usb/gadget/legacy/inode.c
> +++ b/drivers/usb/gadget/legacy/inode.c
> @@ -1717,7 +1717,7 @@ gadgetfs_suspend (struct usb_gadget *gadget)
> case STATE_DEV_UNCONNECTED:
> next_event (dev, GADGETFS_SUSPEND);
> ep0_readable (dev);
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/usb/gadget/udc/pxa25x_udc.c b/drivers/usb/gadget/udc/pxa25x_udc.c
> index 10324a7334fe..a5a754ba6bc9 100644
> --- a/drivers/usb/gadget/udc/pxa25x_udc.c
> +++ b/drivers/usb/gadget/udc/pxa25x_udc.c
> @@ -2340,12 +2340,12 @@ static int pxa25x_udc_probe(struct platform_device *pdev)
> case PXA250_A0:
> case PXA250_A1:
> /* A0/A1 "not released"; ep 13, 15 unusable */
> - fallthrough;
> + break;
> case PXA250_B2: case PXA210_B2:
> case PXA250_B1: case PXA210_B1:
> case PXA250_B0: case PXA210_B0:
> /* OUT-DMA is broken ... */
> - fallthrough;
> + break;
> case PXA250_C0: case PXA210_C0:
> break;
> #elif defined(CONFIG_ARCH_IXP4XX)
> diff --git a/drivers/usb/host/ohci-hcd.c b/drivers/usb/host/ohci-hcd.c
> index dd37e77dae00..9ea59b99535e 100644
> --- a/drivers/usb/host/ohci-hcd.c
> +++ b/drivers/usb/host/ohci-hcd.c
> @@ -1051,7 +1051,7 @@ int ohci_restart(struct ohci_hcd *ohci)
> ed->ed_next = ohci->ed_rm_list;
> ed->ed_prev = NULL;
> ohci->ed_rm_list = ed;
> - fallthrough;
> + break;
> case ED_UNLINK:
> break;
> default:
> diff --git a/drivers/usb/isp1760/isp1760-hcd.c b/drivers/usb/isp1760/isp1760-hcd.c
> index dd74ab7a2f9c..30c168bccf70 100644
> --- a/drivers/usb/isp1760/isp1760-hcd.c
> +++ b/drivers/usb/isp1760/isp1760-hcd.c
> @@ -792,7 +792,7 @@ static void collect_qtds(struct usb_hcd *hcd, struct isp1760_qh *qh,
> case OUT_PID:
> qtd->urb->actual_length +=
> qtd->actual_length;
> - fallthrough;
> + break;
> case SETUP_PID:
> break;
> }
> diff --git a/drivers/usb/musb/cppi_dma.c b/drivers/usb/musb/cppi_dma.c
> index edb5b63d7063..a066aec2b4c1 100644
> --- a/drivers/usb/musb/cppi_dma.c
> +++ b/drivers/usb/musb/cppi_dma.c
> @@ -975,7 +975,7 @@ static int cppi_channel_program(struct dma_channel *ch,
> musb_dbg(musb, "%cX DMA%d not allocated!",
> cppi_ch->transmit ? 'T' : 'R',
> cppi_ch->index);
> - fallthrough;
> + break;
> case MUSB_DMA_STATUS_FREE:
> break;
> }
> diff --git a/drivers/usb/phy/phy-fsl-usb.c b/drivers/usb/phy/phy-fsl-usb.c
> index f34c9437a182..d5c3b548aa51 100644
> --- a/drivers/usb/phy/phy-fsl-usb.c
> +++ b/drivers/usb/phy/phy-fsl-usb.c
> @@ -914,7 +914,7 @@ int usb_otg_start(struct platform_device *pdev)
> fallthrough;
> case FSL_USB2_PHY_UTMI:
> temp |= PORTSC_PTS_UTMI;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/drivers/video/fbdev/stifb.c b/drivers/video/fbdev/stifb.c
> index 265865610edc..aae5ca0b89c9 100644
> --- a/drivers/video/fbdev/stifb.c
> +++ b/drivers/video/fbdev/stifb.c
> @@ -1157,7 +1157,7 @@ static int __init stifb_init_fb(struct sti_struct *sti, int bpp_pref)
> dev_name);
> goto out_err0;
> }
> - fallthrough;
> + break;
> case S9000_ID_ARTIST:
> case S9000_ID_HCRX:
> case S9000_ID_TIMBER:
> diff --git a/fs/afs/yfsclient.c b/fs/afs/yfsclient.c
> index 3b1239b7e90d..6be481a98097 100644
> --- a/fs/afs/yfsclient.c
> +++ b/fs/afs/yfsclient.c
> @@ -461,7 +461,7 @@ static int yfs_deliver_fs_fetch_data64(struct afs_call *call)
> req->file_size = vp->scb.status.size;
>
> call->unmarshall++;
> - fallthrough;
> + break;
>
> case 5:
> break;
> @@ -1363,7 +1363,7 @@ static int yfs_deliver_fs_get_volume_status(struct afs_call *call)
> _debug("motd '%s'", p);
>
> call->unmarshall++;
> - fallthrough;
> + break;
>
> case 8:
> break;
> @@ -1727,7 +1727,7 @@ static int yfs_deliver_fs_inline_bulk_status(struct afs_call *call)
> xdr_decode_YFSVolSync(&bp, &op->volsync);
>
> call->unmarshall++;
> - fallthrough;
> + break;
>
> case 6:
> break;
> @@ -1886,7 +1886,7 @@ static int yfs_deliver_fs_fetch_opaque_acl(struct afs_call *call)
> xdr_decode_YFSVolSync(&bp, &op->volsync);
>
> call->unmarshall++;
> - fallthrough;
> + break;
>
> case 6:
> break;
> diff --git a/fs/ceph/dir.c b/fs/ceph/dir.c
> index d72e4a12bb69..67c3005fb88d 100644
> --- a/fs/ceph/dir.c
> +++ b/fs/ceph/dir.c
> @@ -1740,7 +1740,7 @@ static int ceph_d_revalidate(struct dentry *dentry, unsigned int flags)
> case -ENOENT:
> if (d_really_is_negative(dentry))
> valid = 1;
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c
> index 6e95c85fe395..4bf60dcf13e1 100644
> --- a/fs/nfs/nfs4proc.c
> +++ b/fs/nfs/nfs4proc.c
> @@ -9444,7 +9444,7 @@ static void nfs4_layoutreturn_done(struct rpc_task *task, void *calldata)
> fallthrough;
> default:
> task->tk_status = 0;
> - fallthrough;
> + break;
> case 0:
> break;
> case -NFS4ERR_DELAY:
> diff --git a/fs/nfs_common/nfsacl.c b/fs/nfs_common/nfsacl.c
> index d056ad2fdefd..009c1e434aa5 100644
> --- a/fs/nfs_common/nfsacl.c
> +++ b/fs/nfs_common/nfsacl.c
> @@ -237,7 +237,7 @@ posix_acl_from_nfsacl(struct posix_acl *acl)
> break;
> case ACL_MASK:
> mask = pa;
> - fallthrough;
> + break;
> case ACL_OTHER:
> break;
> }
> diff --git a/kernel/bpf/verifier.c b/kernel/bpf/verifier.c
> index 86fdebb5ffd8..c88c7a7d77fb 100644
> --- a/kernel/bpf/verifier.c
> +++ b/kernel/bpf/verifier.c
> @@ -5334,7 +5334,7 @@ static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env,
> off_reg == dst_reg ? dst : src);
> return -EACCES;
> }
> - fallthrough;
> + break;
> default:
> break;
> }
> diff --git a/kernel/sched/topology.c b/kernel/sched/topology.c
> index da3cd60e4b78..c6c8699f466c 100644
> --- a/kernel/sched/topology.c
> +++ b/kernel/sched/topology.c
> @@ -1233,7 +1233,7 @@ static void __free_domain_allocs(struct s_data *d, enum s_alloc what,
> fallthrough;
> case sa_sd_storage:
> __sdt_free(cpu_map);
> - fallthrough;
> + break;
> case sa_none:
> break;
> }
> diff --git a/kernel/trace/trace_events_filter.c b/kernel/trace/trace_events_filter.c
> index 78a678eeb140..52df27e45843 100644
> --- a/kernel/trace/trace_events_filter.c
> +++ b/kernel/trace/trace_events_filter.c
> @@ -1273,7 +1273,7 @@ static int parse_pred(const char *str, void *data,
> switch (op) {
> case OP_NE:
> pred->not = 1;
> - fallthrough;
> + break;
> case OP_GLOB:
> case OP_EQ:
> break;
> diff --git a/net/dccp/output.c b/net/dccp/output.c
> index 50e6d5699bb2..5a4dbd7cee32 100644
> --- a/net/dccp/output.c
> +++ b/net/dccp/output.c
> @@ -62,7 +62,7 @@ static int dccp_transmit_skb(struct sock *sk, struct sk_buff *skb)
> switch (dcb->dccpd_type) {
> case DCCP_PKT_DATA:
> set_ack = 0;
> - fallthrough;
> + break;
> case DCCP_PKT_DATAACK:
> case DCCP_PKT_RESET:
> break;
> diff --git a/net/ipv4/ip_output.c b/net/ipv4/ip_output.c
> index 825e381e9909..3cf38c0bedf3 100644
> --- a/net/ipv4/ip_output.c
> +++ b/net/ipv4/ip_output.c
> @@ -333,7 +333,7 @@ static int ip_mc_finish_output(struct net *net, struct sock *sk,
> switch (ret) {
> case NET_XMIT_CN:
> do_cn = true;
> - fallthrough;
> + break;
> case NET_XMIT_SUCCESS:
> break;
> default:
> diff --git a/net/netfilter/nf_tables_api.c b/net/netfilter/nf_tables_api.c
> index 97fb6f776114..4844781699d5 100644
> --- a/net/netfilter/nf_tables_api.c
> +++ b/net/netfilter/nf_tables_api.c
> @@ -8525,7 +8525,7 @@ static int nft_verdict_init(const struct nft_ctx *ctx, struct nft_data *data,
> default:
> return -EINVAL;
> }
> - fallthrough;
> + break;
> case NFT_CONTINUE:
> case NFT_BREAK:
> case NFT_RETURN:
> diff --git a/net/rxrpc/input.c b/net/rxrpc/input.c
> index 667c44aa5a63..b654b8c65d10 100644
> --- a/net/rxrpc/input.c
> +++ b/net/rxrpc/input.c
> @@ -1101,7 +1101,7 @@ static void rxrpc_input_implicit_end_call(struct rxrpc_sock *rx,
> switch (READ_ONCE(call->state)) {
> case RXRPC_CALL_SERVER_AWAIT_ACK:
> rxrpc_call_completed(call);
> - fallthrough;
> + break;
> case RXRPC_CALL_COMPLETE:
> break;
> default:
> @@ -1265,7 +1265,7 @@ int rxrpc_input_packet(struct sock *udp_sk, struct sk_buff *skb)
> case RXRPC_PACKET_TYPE_ACKALL:
> if (sp->hdr.callNumber == 0)
> goto bad_message;
> - fallthrough;
> + break;
> case RXRPC_PACKET_TYPE_ABORT:
> break;
>
> diff --git a/net/sctp/outqueue.c b/net/sctp/outqueue.c
> index 3fd06a27105d..f8ce1b3925a9 100644
> --- a/net/sctp/outqueue.c
> +++ b/net/sctp/outqueue.c
> @@ -1030,7 +1030,7 @@ static void sctp_outq_flush_data(struct sctp_flush_ctx *ctx,
> if (!ctx->packet || !ctx->packet->has_cookie_echo)
> return;
>
> - fallthrough;
> + break;
> case SCTP_STATE_ESTABLISHED:
> case SCTP_STATE_SHUTDOWN_PENDING:
> case SCTP_STATE_SHUTDOWN_RECEIVED:
> diff --git a/sound/soc/codecs/ak4613.c b/sound/soc/codecs/ak4613.c
> index 8d663e8d64c4..b35193eb9057 100644
> --- a/sound/soc/codecs/ak4613.c
> +++ b/sound/soc/codecs/ak4613.c
> @@ -457,7 +457,7 @@ static int ak4613_set_bias_level(struct snd_soc_component *component,
> fallthrough;
> case SND_SOC_BIAS_STANDBY:
> mgmt1 |= PMVR;
> - fallthrough;
> + break;
> case SND_SOC_BIAS_OFF:
> default:
> break;
> diff --git a/sound/soc/codecs/jz4770.c b/sound/soc/codecs/jz4770.c
> index 298689a07168..734cf7809b7e 100644
> --- a/sound/soc/codecs/jz4770.c
> +++ b/sound/soc/codecs/jz4770.c
> @@ -202,7 +202,7 @@ static int jz4770_codec_set_bias_level(struct snd_soc_component *codec,
> REG_CR_VIC_SB_SLEEP, REG_CR_VIC_SB_SLEEP);
> regmap_update_bits(regmap, JZ4770_CODEC_REG_CR_VIC,
> REG_CR_VIC_SB, REG_CR_VIC_SB);
> - fallthrough;
> + break;
> default:
> break;
> }
>
>
^ permalink raw reply
* [trivial PATCH] treewide: Convert switch/case fallthrough; to break;
From: Joe Perches @ 2020-09-09 20:06 UTC (permalink / raw)
To: LKML, Jiri Kosina
Cc: linux-wireless, linux-fbdev, oss-drivers, nouveau, alsa-devel,
dri-devel, linux-ide, dm-devel, linux-mtd, linux-i2c, sparclinux,
kvmarm, linux-rtc, linux-s390, linux-scsi, dccp, linux-rdma,
linux-atm-general, linux-afs, coreteam, intel-wired-lan,
linux-serial, linux-input, linux-mmc, Kees Cook, linux-media,
linux-pm, intel-gfx, linux-sctp, linux-mediatek, linux-nvme,
storagedev, ceph-devel, linux-arm-kernel, linux-nfs, linux-parisc,
netdev, linux-usb, Nick Desaulniers, linux-mips, iommu,
netfilter-devel, linux-crypto, bpf, linuxppc-dev
fallthrough to a separate case/default label break; isn't very readable.
Convert pseudo-keyword fallthrough; statements to a simple break; when
the next label is case or default and the only statement in the next
label block is break;
Found using:
$ grep-2.5.4 -rP --include=*.[ch] -n "fallthrough;(\s*(case\s+\w+|default)\s*:\s*){1,7}break;" *
Miscellanea:
o Move or coalesce a couple label blocks above a default: block.
Signed-off-by: Joe Perches <joe@perches.com>
---
Compiled allyesconfig x86-64 only.
A few files for other arches were not compiled.
arch/arm/mach-mmp/pm-pxa910.c | 2 +-
arch/arm64/kvm/handle_exit.c | 2 +-
arch/mips/kernel/cpu-probe.c | 2 +-
arch/mips/math-emu/cp1emu.c | 2 +-
arch/s390/pci/pci.c | 2 +-
crypto/tcrypt.c | 4 ++--
drivers/ata/sata_mv.c | 2 +-
drivers/atm/lanai.c | 2 +-
drivers/gpu/drm/i915/display/intel_sprite.c | 2 +-
drivers/gpu/drm/nouveau/nvkm/engine/disp/hdmi.c | 2 +-
drivers/hid/wacom_wac.c | 2 +-
drivers/i2c/busses/i2c-i801.c | 2 +-
drivers/infiniband/ulp/rtrs/rtrs-clt.c | 14 +++++++-------
drivers/infiniband/ulp/rtrs/rtrs-srv.c | 6 +++---
drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c | 2 +-
drivers/irqchip/irq-vic.c | 4 ++--
drivers/md/dm.c | 2 +-
drivers/media/dvb-frontends/drxd_hard.c | 2 +-
drivers/media/i2c/ov5640.c | 2 +-
drivers/media/i2c/ov6650.c | 5 ++---
drivers/media/i2c/smiapp/smiapp-core.c | 2 +-
drivers/media/i2c/tvp5150.c | 2 +-
drivers/media/pci/ddbridge/ddbridge-core.c | 2 +-
drivers/media/usb/cpia2/cpia2_core.c | 2 +-
drivers/mfd/iqs62x.c | 3 +--
drivers/mmc/host/atmel-mci.c | 2 +-
drivers/mtd/nand/raw/nandsim.c | 2 +-
drivers/net/ethernet/intel/e1000e/phy.c | 2 +-
drivers/net/ethernet/intel/fm10k/fm10k_pf.c | 2 +-
drivers/net/ethernet/intel/i40e/i40e_adminq.c | 2 +-
drivers/net/ethernet/intel/i40e/i40e_txrx.c | 2 +-
drivers/net/ethernet/intel/iavf/iavf_txrx.c | 2 +-
drivers/net/ethernet/intel/igb/e1000_phy.c | 2 +-
drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c | 2 +-
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 +-
drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c | 2 +-
drivers/net/ethernet/intel/ixgbevf/vf.c | 2 +-
drivers/net/ethernet/netronome/nfp/nfpcore/nfp6000_pcie.c | 2 +-
drivers/net/ethernet/qlogic/qed/qed_mcp.c | 2 +-
drivers/net/ethernet/sfc/falcon/farch.c | 2 +-
drivers/net/ethernet/sfc/farch.c | 2 +-
drivers/net/phy/adin.c | 3 +--
drivers/net/usb/pegasus.c | 4 ++--
drivers/net/usb/usbnet.c | 2 +-
drivers/net/wireless/ath/ath5k/eeprom.c | 2 +-
drivers/net/wireless/mediatek/mt7601u/dma.c | 8 ++++----
drivers/nvme/host/core.c | 12 ++++++------
drivers/pcmcia/db1xxx_ss.c | 4 ++--
drivers/power/supply/abx500_chargalg.c | 2 +-
drivers/power/supply/charger-manager.c | 2 +-
drivers/rtc/rtc-pcf85063.c | 2 +-
drivers/s390/scsi/zfcp_fsf.c | 2 +-
drivers/scsi/aic7xxx/aic79xx_core.c | 4 ++--
drivers/scsi/aic94xx/aic94xx_tmf.c | 2 +-
drivers/scsi/lpfc/lpfc_sli.c | 2 +-
drivers/scsi/smartpqi/smartpqi_init.c | 2 +-
drivers/scsi/sr.c | 2 +-
drivers/tty/serial/sunsu.c | 2 +-
drivers/tty/serial/sunzilog.c | 2 +-
drivers/tty/vt/vt_ioctl.c | 2 +-
drivers/usb/dwc3/core.c | 2 +-
drivers/usb/gadget/legacy/inode.c | 2 +-
drivers/usb/gadget/udc/pxa25x_udc.c | 4 ++--
drivers/usb/host/ohci-hcd.c | 2 +-
drivers/usb/isp1760/isp1760-hcd.c | 2 +-
drivers/usb/musb/cppi_dma.c | 2 +-
drivers/usb/phy/phy-fsl-usb.c | 2 +-
drivers/video/fbdev/stifb.c | 2 +-
fs/afs/yfsclient.c | 8 ++++----
fs/ceph/dir.c | 2 +-
fs/nfs/nfs4proc.c | 2 +-
fs/nfs_common/nfsacl.c | 2 +-
kernel/bpf/verifier.c | 2 +-
kernel/sched/topology.c | 2 +-
kernel/trace/trace_events_filter.c | 2 +-
net/dccp/output.c | 2 +-
net/ipv4/ip_output.c | 2 +-
net/netfilter/nf_tables_api.c | 2 +-
net/rxrpc/input.c | 4 ++--
net/sctp/outqueue.c | 2 +-
sound/soc/codecs/ak4613.c | 2 +-
sound/soc/codecs/jz4770.c | 2 +-
82 files changed, 109 insertions(+), 112 deletions(-)
diff --git a/arch/arm/mach-mmp/pm-pxa910.c b/arch/arm/mach-mmp/pm-pxa910.c
index 1d71d73c1862..dcf2482a9e6c 100644
--- a/arch/arm/mach-mmp/pm-pxa910.c
+++ b/arch/arm/mach-mmp/pm-pxa910.c
@@ -161,7 +161,7 @@ void pxa910_pm_enter_lowpower_mode(int state)
idle_cfg |= APMU_MOH_IDLE_CFG_MOH_PWRDWN;
idle_cfg |= APMU_MOH_IDLE_CFG_MOH_PWR_SW(3)
| APMU_MOH_IDLE_CFG_MOH_L2_PWR_SW(3);
- fallthrough;
+ break;
case POWER_MODE_CORE_INTIDLE:
break;
}
diff --git a/arch/arm64/kvm/handle_exit.c b/arch/arm64/kvm/handle_exit.c
index 5d690d60ccad..bf3d54b0a233 100644
--- a/arch/arm64/kvm/handle_exit.c
+++ b/arch/arm64/kvm/handle_exit.c
@@ -128,7 +128,7 @@ static int kvm_handle_guest_debug(struct kvm_vcpu *vcpu)
switch (ESR_ELx_EC(esr)) {
case ESR_ELx_EC_WATCHPT_LOW:
run->debug.arch.far = vcpu->arch.fault.far_el2;
- fallthrough;
+ break;
case ESR_ELx_EC_SOFTSTP_LOW:
case ESR_ELx_EC_BREAKPT_LOW:
case ESR_ELx_EC_BKPT32:
diff --git a/arch/mips/kernel/cpu-probe.c b/arch/mips/kernel/cpu-probe.c
index e2955f1f6316..6ddc70211a0f 100644
--- a/arch/mips/kernel/cpu-probe.c
+++ b/arch/mips/kernel/cpu-probe.c
@@ -1823,7 +1823,7 @@ static inline void cpu_probe_mips(struct cpuinfo_mips *c, unsigned int cpu)
fallthrough;
case CPU_I6400:
c->options |= MIPS_CPU_SHARED_FTLB_RAM;
- fallthrough;
+ break;
default:
break;
}
diff --git a/arch/mips/math-emu/cp1emu.c b/arch/mips/math-emu/cp1emu.c
index 587cf1d115e8..9c8f8539ec5d 100644
--- a/arch/mips/math-emu/cp1emu.c
+++ b/arch/mips/math-emu/cp1emu.c
@@ -1224,7 +1224,7 @@ static int cop1Emulate(struct pt_regs *xcp, struct mips_fpu_struct *ctx,
case bctl_op:
if (cpu_has_mips_2_3_4_5_r)
likely = 1;
- fallthrough;
+ break;
case bct_op:
break;
}
diff --git a/arch/s390/pci/pci.c b/arch/s390/pci/pci.c
index 4b62d6b55024..5b1e412bbd32 100644
--- a/arch/s390/pci/pci.c
+++ b/arch/s390/pci/pci.c
@@ -743,7 +743,7 @@ void zpci_release_device(struct kref *kref)
zpci_cleanup_bus_resources(zdev);
zpci_bus_device_unregister(zdev);
zpci_destroy_iommu(zdev);
- fallthrough;
+ break;
default:
break;
}
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;
@@ -2587,7 +2587,7 @@ static int do_test(const char *alg, u32 type, u32 mask, int m, u32 num_mb)
test_mb_ahash_speed("streebog512", sec,
generic_hash_speed_template, num_mb);
if (mode > 400 && mode < 500) break;
- fallthrough;
+ break;
case 499:
break;
diff --git a/drivers/ata/sata_mv.c b/drivers/ata/sata_mv.c
index 664ef658a955..4d6cce2352bd 100644
--- a/drivers/ata/sata_mv.c
+++ b/drivers/ata/sata_mv.c
@@ -2044,7 +2044,7 @@ static enum ata_completion_errors mv_qc_prep(struct ata_queued_cmd *qc)
case ATA_PROT_DMA:
if (tf->command == ATA_CMD_DSM)
return AC_ERR_OK;
- fallthrough;
+ break;
case ATA_PROT_NCQ:
break; /* continue below */
case ATA_PROT_PIO:
diff --git a/drivers/atm/lanai.c b/drivers/atm/lanai.c
index ac811cfa6843..972a6837a20e 100644
--- a/drivers/atm/lanai.c
+++ b/drivers/atm/lanai.c
@@ -2019,7 +2019,7 @@ static int lanai_normalize_ci(struct lanai_dev *lanai,
switch (*vpip) {
case ATM_VPI_ANY:
*vpip = 0;
- fallthrough;
+ break;
case 0:
break;
default:
diff --git a/drivers/gpu/drm/i915/display/intel_sprite.c b/drivers/gpu/drm/i915/display/intel_sprite.c
index 5ac0dbf0e03d..35ac539cc2b1 100644
--- a/drivers/gpu/drm/i915/display/intel_sprite.c
+++ b/drivers/gpu/drm/i915/display/intel_sprite.c
@@ -2861,7 +2861,7 @@ static bool gen12_plane_format_mod_supported(struct drm_plane *_plane,
case I915_FORMAT_MOD_Y_TILED_GEN12_MC_CCS:
if (!gen12_plane_supports_mc_ccs(dev_priv, plane->id))
return false;
- fallthrough;
+ break;
case DRM_FORMAT_MOD_LINEAR:
case I915_FORMAT_MOD_X_TILED:
case I915_FORMAT_MOD_Y_TILED:
diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/disp/hdmi.c b/drivers/gpu/drm/nouveau/nvkm/engine/disp/hdmi.c
index 1ccfc8314812..bc83cf098e25 100644
--- a/drivers/gpu/drm/nouveau/nvkm/engine/disp/hdmi.c
+++ b/drivers/gpu/drm/nouveau/nvkm/engine/disp/hdmi.c
@@ -71,7 +71,7 @@ void pack_hdmi_infoframe(struct packed_hdmi_infoframe *packed_frame,
fallthrough;
case 1:
header |= raw_frame[0];
- fallthrough;
+ break;
case 0:
break;
}
diff --git a/drivers/hid/wacom_wac.c b/drivers/hid/wacom_wac.c
index 83dfec327c42..822dc15b59b6 100644
--- a/drivers/hid/wacom_wac.c
+++ b/drivers/hid/wacom_wac.c
@@ -3833,7 +3833,7 @@ int wacom_setup_touch_input_capabilities(struct input_dev *input_dev,
case MTTPC_B:
case TABLETPC2FG:
input_mt_init_slots(input_dev, features->touch_max, INPUT_MT_DIRECT);
- fallthrough;
+ break;
case TABLETPC:
case TABLETPCE:
diff --git a/drivers/i2c/busses/i2c-i801.c b/drivers/i2c/busses/i2c-i801.c
index e32ef3f01fe8..b13b1cbcac29 100644
--- a/drivers/i2c/busses/i2c-i801.c
+++ b/drivers/i2c/busses/i2c-i801.c
@@ -1785,7 +1785,7 @@ static int i801_probe(struct pci_dev *dev, const struct pci_device_id *id)
fallthrough;
case PCI_DEVICE_ID_INTEL_82801CA_3:
priv->features |= FEATURE_HOST_NOTIFY;
- fallthrough;
+ break;
case PCI_DEVICE_ID_INTEL_82801BA_2:
case PCI_DEVICE_ID_INTEL_82801AB_3:
case PCI_DEVICE_ID_INTEL_82801AA_3:
diff --git a/drivers/infiniband/ulp/rtrs/rtrs-clt.c b/drivers/infiniband/ulp/rtrs/rtrs-clt.c
index 776e89231c52..55339cad408a 100644
--- a/drivers/infiniband/ulp/rtrs/rtrs-clt.c
+++ b/drivers/infiniband/ulp/rtrs/rtrs-clt.c
@@ -209,7 +209,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
switch (old_state) {
case RTRS_CLT_RECONNECTING:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -220,7 +220,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
case RTRS_CLT_CONNECTING_ERR:
case RTRS_CLT_CLOSED:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -229,7 +229,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
switch (old_state) {
case RTRS_CLT_CONNECTING:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -238,7 +238,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
switch (old_state) {
case RTRS_CLT_CONNECTING:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -250,7 +250,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
case RTRS_CLT_RECONNECTING:
case RTRS_CLT_CONNECTED:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -259,7 +259,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
switch (old_state) {
case RTRS_CLT_CLOSING:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -268,7 +268,7 @@ static bool __rtrs_clt_change_state(struct rtrs_clt_sess *sess,
switch (old_state) {
case RTRS_CLT_CLOSED:
changed = true;
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/infiniband/ulp/rtrs/rtrs-srv.c b/drivers/infiniband/ulp/rtrs/rtrs-srv.c
index b61a18e57aeb..24e53b39a79c 100644
--- a/drivers/infiniband/ulp/rtrs/rtrs-srv.c
+++ b/drivers/infiniband/ulp/rtrs/rtrs-srv.c
@@ -78,7 +78,7 @@ static bool __rtrs_srv_change_state(struct rtrs_srv_sess *sess,
switch (old_state) {
case RTRS_SRV_CONNECTING:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -88,7 +88,7 @@ static bool __rtrs_srv_change_state(struct rtrs_srv_sess *sess,
case RTRS_SRV_CONNECTING:
case RTRS_SRV_CONNECTED:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -97,7 +97,7 @@ static bool __rtrs_srv_change_state(struct rtrs_srv_sess *sess,
switch (old_state) {
case RTRS_SRV_CLOSING:
changed = true;
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c b/drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c
index c192544e874b..743db1abec40 100644
--- a/drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c
+++ b/drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c
@@ -3777,7 +3777,7 @@ static int arm_smmu_device_hw_probe(struct arm_smmu_device *smmu)
switch (FIELD_GET(IDR0_TTF, reg)) {
case IDR0_TTF_AARCH32_64:
smmu->ias = 40;
- fallthrough;
+ break;
case IDR0_TTF_AARCH64:
break;
default:
diff --git a/drivers/irqchip/irq-vic.c b/drivers/irqchip/irq-vic.c
index e46036374227..10ff0a5c225a 100644
--- a/drivers/irqchip/irq-vic.c
+++ b/drivers/irqchip/irq-vic.c
@@ -453,10 +453,10 @@ static void __init __vic_init(void __iomem *base, int parent_irq, int irq_start,
case AMBA_VENDOR_ST:
vic_init_st(base, irq_start, vic_sources, node);
return;
+ case AMBA_VENDOR_ARM:
+ break;
default:
printk(KERN_WARNING "VIC: unknown vendor, continuing anyways\n");
- fallthrough;
- case AMBA_VENDOR_ARM:
break;
}
diff --git a/drivers/md/dm.c b/drivers/md/dm.c
index 3dedd9cc4fb6..dc71573d5b09 100644
--- a/drivers/md/dm.c
+++ b/drivers/md/dm.c
@@ -1021,7 +1021,7 @@ static void clone_endio(struct bio *bio)
switch (r) {
case DM_ENDIO_REQUEUE:
error = BLK_STS_DM_REQUEUE;
- fallthrough;
+ break;
case DM_ENDIO_DONE:
break;
case DM_ENDIO_INCOMPLETE:
diff --git a/drivers/media/dvb-frontends/drxd_hard.c b/drivers/media/dvb-frontends/drxd_hard.c
index 45f982863904..d6592e764a92 100644
--- a/drivers/media/dvb-frontends/drxd_hard.c
+++ b/drivers/media/dvb-frontends/drxd_hard.c
@@ -1519,7 +1519,7 @@ static int SetDeviceTypeId(struct drxd_state *state)
break;
case 6:
state->diversity = 1;
- fallthrough;
+ break;
case 5:
case 8:
break;
diff --git a/drivers/media/i2c/ov5640.c b/drivers/media/i2c/ov5640.c
index 637687d761f2..855d3aba711a 100644
--- a/drivers/media/i2c/ov5640.c
+++ b/drivers/media/i2c/ov5640.c
@@ -3010,7 +3010,7 @@ static int ov5640_probe(struct i2c_client *client)
switch (rotation) {
case 180:
sensor->upside_down = true;
- fallthrough;
+ break;
case 0:
break;
default:
diff --git a/drivers/media/i2c/ov6650.c b/drivers/media/i2c/ov6650.c
index d73f9f540932..fde56572dce8 100644
--- a/drivers/media/i2c/ov6650.c
+++ b/drivers/media/i2c/ov6650.c
@@ -685,17 +685,16 @@ static int ov6650_set_fmt(struct v4l2_subdev *sd,
switch (mf->code) {
case MEDIA_BUS_FMT_Y10_1X10:
mf->code = MEDIA_BUS_FMT_Y8_1X8;
- fallthrough;
+ break;
case MEDIA_BUS_FMT_Y8_1X8:
case MEDIA_BUS_FMT_YVYU8_2X8:
case MEDIA_BUS_FMT_YUYV8_2X8:
case MEDIA_BUS_FMT_VYUY8_2X8:
case MEDIA_BUS_FMT_UYVY8_2X8:
+ case MEDIA_BUS_FMT_SBGGR8_1X8:
break;
default:
mf->code = MEDIA_BUS_FMT_SBGGR8_1X8;
- fallthrough;
- case MEDIA_BUS_FMT_SBGGR8_1X8:
break;
}
diff --git a/drivers/media/i2c/smiapp/smiapp-core.c b/drivers/media/i2c/smiapp/smiapp-core.c
index 6fc0680a93d0..8bfba407b8f1 100644
--- a/drivers/media/i2c/smiapp/smiapp-core.c
+++ b/drivers/media/i2c/smiapp/smiapp-core.c
@@ -2795,7 +2795,7 @@ static struct smiapp_hwconfig *smiapp_get_hwconfig(struct device *dev)
case 180:
hwcfg->module_board_orient =
SMIAPP_MODULE_BOARD_ORIENT_180;
- fallthrough;
+ break;
case 0:
break;
default:
diff --git a/drivers/media/i2c/tvp5150.c b/drivers/media/i2c/tvp5150.c
index 7d9401219a3a..df174089e74d 100644
--- a/drivers/media/i2c/tvp5150.c
+++ b/drivers/media/i2c/tvp5150.c
@@ -293,7 +293,7 @@ static void tvp5150_selmux(struct v4l2_subdev *sd)
switch (decoder->input) {
case TVP5150_COMPOSITE1:
input |= 2;
- fallthrough;
+ break;
case TVP5150_COMPOSITE0:
break;
case TVP5150_SVIDEO:
diff --git a/drivers/media/pci/ddbridge/ddbridge-core.c b/drivers/media/pci/ddbridge/ddbridge-core.c
index 92fe051c672f..426c9e0152d8 100644
--- a/drivers/media/pci/ddbridge/ddbridge-core.c
+++ b/drivers/media/pci/ddbridge/ddbridge-core.c
@@ -1336,7 +1336,7 @@ static void dvb_input_detach(struct ddb_input *input)
fallthrough;
case 0x10:
dvb_dmx_release(&dvb->demux);
- fallthrough;
+ break;
case 0x01:
break;
}
diff --git a/drivers/media/usb/cpia2/cpia2_core.c b/drivers/media/usb/cpia2/cpia2_core.c
index e747548ab286..cbef274d4f95 100644
--- a/drivers/media/usb/cpia2/cpia2_core.c
+++ b/drivers/media/usb/cpia2/cpia2_core.c
@@ -1751,7 +1751,7 @@ int cpia2_set_fps(struct camera_data *cam, int framerate)
CPIA2_VP_SENSOR_FLAGS_500) {
return -EINVAL;
}
- fallthrough;
+ break;
case CPIA2_VP_FRAMERATE_15:
case CPIA2_VP_FRAMERATE_12_5:
case CPIA2_VP_FRAMERATE_7_5:
diff --git a/drivers/mfd/iqs62x.c b/drivers/mfd/iqs62x.c
index 761b4ef3a381..5671482ec8fe 100644
--- a/drivers/mfd/iqs62x.c
+++ b/drivers/mfd/iqs62x.c
@@ -490,8 +490,7 @@ static irqreturn_t iqs62x_irq(int irq, void *context)
case IQS62X_EVENT_HYST:
event_map[i] <<= iqs62x->dev_desc->hyst_shift;
-
- fallthrough;
+ break;
case IQS62X_EVENT_WHEEL:
case IQS62X_EVENT_HALL:
diff --git a/drivers/mmc/host/atmel-mci.c b/drivers/mmc/host/atmel-mci.c
index 444bd3a0a922..8324312e4f42 100644
--- a/drivers/mmc/host/atmel-mci.c
+++ b/drivers/mmc/host/atmel-mci.c
@@ -2435,7 +2435,7 @@ static void atmci_get_cap(struct atmel_mci *host)
case 0x100:
host->caps.has_bad_data_ordering = 0;
host->caps.need_reset_after_xfer = 0;
- fallthrough;
+ break;
case 0x0:
break;
default:
diff --git a/drivers/mtd/nand/raw/nandsim.c b/drivers/mtd/nand/raw/nandsim.c
index f5a53aac3c5f..b07934247297 100644
--- a/drivers/mtd/nand/raw/nandsim.c
+++ b/drivers/mtd/nand/raw/nandsim.c
@@ -2286,7 +2286,7 @@ static int __init ns_init_module(void)
fallthrough;
case 1:
chip->bbt_options |= NAND_BBT_USE_FLASH;
- fallthrough;
+ break;
case 0:
break;
default:
diff --git a/drivers/net/ethernet/intel/e1000e/phy.c b/drivers/net/ethernet/intel/e1000e/phy.c
index e11c877595fb..9fec7cc52710 100644
--- a/drivers/net/ethernet/intel/e1000e/phy.c
+++ b/drivers/net/ethernet/intel/e1000e/phy.c
@@ -607,7 +607,7 @@ static s32 e1000_set_master_slave_mode(struct e1000_hw *hw)
break;
case e1000_ms_auto:
phy_data &= ~CTL1000_ENABLE_MASTER;
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/net/ethernet/intel/fm10k/fm10k_pf.c b/drivers/net/ethernet/intel/fm10k/fm10k_pf.c
index c0780c3624c8..1c601d7464dd 100644
--- a/drivers/net/ethernet/intel/fm10k/fm10k_pf.c
+++ b/drivers/net/ethernet/intel/fm10k/fm10k_pf.c
@@ -1329,7 +1329,7 @@ static u8 fm10k_iov_supported_xcast_mode_pf(struct fm10k_vf_info *vf_info,
case FM10K_XCAST_MODE_NONE:
if (vf_flags & FM10K_VF_FLAG_NONE_CAPABLE)
return FM10K_XCAST_MODE_NONE;
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/net/ethernet/intel/i40e/i40e_adminq.c b/drivers/net/ethernet/intel/i40e/i40e_adminq.c
index c897a2863e4f..857b699f02c9 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_adminq.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_adminq.c
@@ -541,7 +541,7 @@ static void i40e_set_hw_flags(struct i40e_hw *hw)
(aq->api_maj_ver == 1 &&
aq->api_min_ver >= I40E_MINOR_VER_GET_LINK_INFO_X722))
hw->flags |= I40E_HW_FLAG_AQ_PHY_ACCESS_CAPABLE;
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/net/ethernet/intel/i40e/i40e_txrx.c b/drivers/net/ethernet/intel/i40e/i40e_txrx.c
index 91ab824926b9..ef4f3dbc7b7e 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_txrx.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_txrx.c
@@ -1690,7 +1690,7 @@ static inline void i40e_rx_checksum(struct i40e_vsi *vsi,
case I40E_RX_PTYPE_INNER_PROT_UDP:
case I40E_RX_PTYPE_INNER_PROT_SCTP:
skb->ip_summed = CHECKSUM_UNNECESSARY;
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/net/ethernet/intel/iavf/iavf_txrx.c b/drivers/net/ethernet/intel/iavf/iavf_txrx.c
index 256fa07d54d5..c2c1ef255008 100644
--- a/drivers/net/ethernet/intel/iavf/iavf_txrx.c
+++ b/drivers/net/ethernet/intel/iavf/iavf_txrx.c
@@ -1007,7 +1007,7 @@ static inline void iavf_rx_checksum(struct iavf_vsi *vsi,
case IAVF_RX_PTYPE_INNER_PROT_UDP:
case IAVF_RX_PTYPE_INNER_PROT_SCTP:
skb->ip_summed = CHECKSUM_UNNECESSARY;
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/net/ethernet/intel/igb/e1000_phy.c b/drivers/net/ethernet/intel/igb/e1000_phy.c
index 8c8eb82e6272..f8f7ffbc45f0 100644
--- a/drivers/net/ethernet/intel/igb/e1000_phy.c
+++ b/drivers/net/ethernet/intel/igb/e1000_phy.c
@@ -2621,7 +2621,7 @@ static s32 igb_set_master_slave_mode(struct e1000_hw *hw)
break;
case e1000_ms_auto:
phy_data &= ~CR_1000T_MS_ENABLE;
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c
index 8d3798a32f0e..1549f0342384 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_82599.c
@@ -1589,7 +1589,7 @@ s32 ixgbe_fdir_set_input_mask_82599(struct ixgbe_hw *hw,
case 0x0000:
/* Mask Flex Bytes */
fdirm |= IXGBE_FDIRM_FLEX;
- fallthrough;
+ break;
case 0xFFFF:
break;
default:
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
index 0b675c34ce49..17e0fe4d380e 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
@@ -5901,7 +5901,7 @@ void ixgbe_disable_tx(struct ixgbe_adapter *adapter)
IXGBE_WRITE_REG(hw, IXGBE_DMATXCTL,
(IXGBE_READ_REG(hw, IXGBE_DMATXCTL) &
~IXGBE_DMATXCTL_TE));
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c
index 988db46bff0e..45b18708f5ed 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c
@@ -1141,7 +1141,7 @@ static int ixgbe_update_vf_xcast_mode(struct ixgbe_adapter *adapter,
/* promisc introduced in 1.3 version */
if (xcast_mode == IXGBEVF_XCAST_MODE_PROMISC)
return -EOPNOTSUPP;
- fallthrough;
+ break;
case ixgbe_mbox_api_13:
case ixgbe_mbox_api_14:
break;
diff --git a/drivers/net/ethernet/intel/ixgbevf/vf.c b/drivers/net/ethernet/intel/ixgbevf/vf.c
index bfe6dfcec4ab..7f14665b6bdf 100644
--- a/drivers/net/ethernet/intel/ixgbevf/vf.c
+++ b/drivers/net/ethernet/intel/ixgbevf/vf.c
@@ -540,7 +540,7 @@ static s32 ixgbevf_update_xcast_mode(struct ixgbe_hw *hw, int xcast_mode)
/* promisc introduced in 1.3 version */
if (xcast_mode == IXGBEVF_XCAST_MODE_PROMISC)
return -EOPNOTSUPP;
- fallthrough;
+ break;
case ixgbe_mbox_api_14:
case ixgbe_mbox_api_13:
break;
diff --git a/drivers/net/ethernet/netronome/nfp/nfpcore/nfp6000_pcie.c b/drivers/net/ethernet/netronome/nfp/nfpcore/nfp6000_pcie.c
index 252fe06f58aa..1d5b87079104 100644
--- a/drivers/net/ethernet/netronome/nfp/nfpcore/nfp6000_pcie.c
+++ b/drivers/net/ethernet/netronome/nfp/nfpcore/nfp6000_pcie.c
@@ -345,7 +345,7 @@ static int matching_bar(struct nfp_bar *bar, u32 tgt, u32 act, u32 tok,
baract = NFP_CPP_ACTION_RW;
if (act == 0)
act = NFP_CPP_ACTION_RW;
- fallthrough;
+ break;
case NFP_PCIE_BAR_PCIE2CPP_MapType_FIXED:
break;
default:
diff --git a/drivers/net/ethernet/qlogic/qed/qed_mcp.c b/drivers/net/ethernet/qlogic/qed/qed_mcp.c
index cd882c453394..1bffe5cb88f4 100644
--- a/drivers/net/ethernet/qlogic/qed/qed_mcp.c
+++ b/drivers/net/ethernet/qlogic/qed/qed_mcp.c
@@ -3546,7 +3546,7 @@ qed_mcp_resc_allocation_msg(struct qed_hwfn *p_hwfn,
switch (p_in_params->cmd) {
case DRV_MSG_SET_RESOURCE_VALUE_MSG:
mfw_resc_info.size = p_in_params->resc_max_val;
- fallthrough;
+ break;
case DRV_MSG_GET_RESOURCE_ALLOC_MSG:
break;
default:
diff --git a/drivers/net/ethernet/sfc/falcon/farch.c b/drivers/net/ethernet/sfc/falcon/farch.c
index fa1ade856b10..14f42c94809d 100644
--- a/drivers/net/ethernet/sfc/falcon/farch.c
+++ b/drivers/net/ethernet/sfc/falcon/farch.c
@@ -1052,7 +1052,7 @@ ef4_farch_handle_rx_event(struct ef4_channel *channel, const ef4_qword_t *event)
fallthrough;
case FSE_CZ_RX_EV_HDR_TYPE_IPV4V6_UDP:
flags |= EF4_RX_PKT_CSUMMED;
- fallthrough;
+ break;
case FSE_CZ_RX_EV_HDR_TYPE_IPV4V6_OTHER:
case FSE_AZ_RX_EV_HDR_TYPE_OTHER:
break;
diff --git a/drivers/net/ethernet/sfc/farch.c b/drivers/net/ethernet/sfc/farch.c
index e004524e14a8..cea0eb822473 100644
--- a/drivers/net/ethernet/sfc/farch.c
+++ b/drivers/net/ethernet/sfc/farch.c
@@ -1038,7 +1038,7 @@ efx_farch_handle_rx_event(struct efx_channel *channel, const efx_qword_t *event)
fallthrough;
case FSE_CZ_RX_EV_HDR_TYPE_IPV4V6_UDP:
flags |= EFX_RX_PKT_CSUMMED;
- fallthrough;
+ break;
case FSE_CZ_RX_EV_HDR_TYPE_IPV4V6_OTHER:
case FSE_AZ_RX_EV_HDR_TYPE_OTHER:
break;
diff --git a/drivers/net/phy/adin.c b/drivers/net/phy/adin.c
index 307f0ac1287b..95aeffe7482b 100644
--- a/drivers/net/phy/adin.c
+++ b/drivers/net/phy/adin.c
@@ -366,10 +366,9 @@ static int adin_set_edpd(struct phy_device *phydev, u16 tx_interval)
switch (tx_interval) {
case 1000: /* 1 second */
- fallthrough;
case ETHTOOL_PHY_EDPD_DFLT_TX_MSECS:
val |= ADIN1300_NRG_PD_TX_EN;
- fallthrough;
+ break;
case ETHTOOL_PHY_EDPD_NO_TX:
break;
default:
diff --git a/drivers/net/usb/pegasus.c b/drivers/net/usb/pegasus.c
index e92cb51a2c77..9adb26ee4a86 100644
--- a/drivers/net/usb/pegasus.c
+++ b/drivers/net/usb/pegasus.c
@@ -627,10 +627,10 @@ static void write_bulk_callback(struct urb *urb)
case -ESHUTDOWN:
netif_dbg(pegasus, ifdown, net, "tx unlink, %d\n", status);
return;
+ case 0:
+ break;
default:
netif_info(pegasus, tx_err, net, "TX status %d\n", status);
- fallthrough;
- case 0:
break;
}
diff --git a/drivers/net/usb/usbnet.c b/drivers/net/usb/usbnet.c
index 2b2a841cd938..56edd8c9819e 100644
--- a/drivers/net/usb/usbnet.c
+++ b/drivers/net/usb/usbnet.c
@@ -110,7 +110,7 @@ int usbnet_get_endpoints(struct usbnet *dev, struct usb_interface *intf)
if (!usb_endpoint_dir_in(&e->desc))
continue;
intr = 1;
- fallthrough;
+ break;
case USB_ENDPOINT_XFER_BULK:
break;
default:
diff --git a/drivers/net/wireless/ath/ath5k/eeprom.c b/drivers/net/wireless/ath/ath5k/eeprom.c
index 1fbc2c19848f..f5ea317f2a67 100644
--- a/drivers/net/wireless/ath/ath5k/eeprom.c
+++ b/drivers/net/wireless/ath/ath5k/eeprom.c
@@ -1178,7 +1178,7 @@ ath5k_cal_data_offset_2413(struct ath5k_eeprom_info *ee, int mode)
offset += ath5k_pdgains_size_2413(ee,
AR5K_EEPROM_MODE_11A) +
AR5K_EEPROM_N_5GHZ_CHAN / 2;
- fallthrough;
+ break;
case AR5K_EEPROM_MODE_11A:
break;
default:
diff --git a/drivers/net/wireless/mediatek/mt7601u/dma.c b/drivers/net/wireless/mediatek/mt7601u/dma.c
index 09f931d4598c..778be26d329f 100644
--- a/drivers/net/wireless/mediatek/mt7601u/dma.c
+++ b/drivers/net/wireless/mediatek/mt7601u/dma.c
@@ -193,11 +193,11 @@ static void mt7601u_complete_rx(struct urb *urb)
case -ESHUTDOWN:
case -ENOENT:
return;
+ case 0:
+ break;
default:
dev_err_ratelimited(dev->dev, "rx urb failed: %d\n",
urb->status);
- fallthrough;
- case 0:
break;
}
@@ -238,11 +238,11 @@ static void mt7601u_complete_tx(struct urb *urb)
case -ESHUTDOWN:
case -ENOENT:
return;
+ case 0:
+ break;
default:
dev_err_ratelimited(dev->dev, "tx urb failed: %d\n",
urb->status);
- fallthrough;
- case 0:
break;
}
diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
index ea1fa41fbba8..aea9f978861e 100644
--- a/drivers/nvme/host/core.c
+++ b/drivers/nvme/host/core.c
@@ -365,7 +365,7 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
case NVME_CTRL_RESETTING:
case NVME_CTRL_CONNECTING:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -375,7 +375,7 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
case NVME_CTRL_NEW:
case NVME_CTRL_LIVE:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -385,7 +385,7 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
case NVME_CTRL_NEW:
case NVME_CTRL_RESETTING:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -396,7 +396,7 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
case NVME_CTRL_RESETTING:
case NVME_CTRL_CONNECTING:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -406,7 +406,7 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
case NVME_CTRL_DELETING:
case NVME_CTRL_DEAD:
changed = true;
- fallthrough;
+ break;
default:
break;
}
@@ -415,7 +415,7 @@ bool nvme_change_ctrl_state(struct nvme_ctrl *ctrl,
switch (old_state) {
case NVME_CTRL_DELETING:
changed = true;
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/pcmcia/db1xxx_ss.c b/drivers/pcmcia/db1xxx_ss.c
index a7c7c7cd2326..d5eec00aaf97 100644
--- a/drivers/pcmcia/db1xxx_ss.c
+++ b/drivers/pcmcia/db1xxx_ss.c
@@ -258,7 +258,7 @@ static int db1x_pcmcia_configure(struct pcmcia_socket *skt,
fallthrough;
case 33:
++v;
- fallthrough;
+ break;
case 0:
break;
default:
@@ -273,7 +273,7 @@ static int db1x_pcmcia_configure(struct pcmcia_socket *skt,
case 33:
case 50:
++p;
- fallthrough;
+ break;
case 0:
break;
default:
diff --git a/drivers/power/supply/abx500_chargalg.c b/drivers/power/supply/abx500_chargalg.c
index 175c4f3d7955..b847a1570ab0 100644
--- a/drivers/power/supply/abx500_chargalg.c
+++ b/drivers/power/supply/abx500_chargalg.c
@@ -1419,7 +1419,7 @@ static void abx500_chargalg_algorithm(struct abx500_chargalg *di)
abx500_chargalg_stop_charging(di);
di->charge_status = POWER_SUPPLY_STATUS_DISCHARGING;
abx500_chargalg_state_to(di, STATE_HANDHELD);
- fallthrough;
+ break;
case STATE_HANDHELD:
break;
diff --git a/drivers/power/supply/charger-manager.c b/drivers/power/supply/charger-manager.c
index 07992821e252..ac7871a7684b 100644
--- a/drivers/power/supply/charger-manager.c
+++ b/drivers/power/supply/charger-manager.c
@@ -585,7 +585,7 @@ static int cm_get_target_status(struct charger_manager *cm)
case POWER_SUPPLY_STATUS_FULL:
if (is_full_charged(cm))
return POWER_SUPPLY_STATUS_FULL;
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/rtc/rtc-pcf85063.c b/drivers/rtc/rtc-pcf85063.c
index f8b99cb72959..65bb87cc8380 100644
--- a/drivers/rtc/rtc-pcf85063.c
+++ b/drivers/rtc/rtc-pcf85063.c
@@ -353,7 +353,7 @@ static int pcf85063_load_capacitance(struct pcf85063 *pcf85063,
default:
dev_warn(&pcf85063->rtc->dev, "Unknown quartz-load-femtofarads value: %d. Assuming 7000",
load);
- fallthrough;
+ break;
case 7000:
break;
case 12500:
diff --git a/drivers/s390/scsi/zfcp_fsf.c b/drivers/s390/scsi/zfcp_fsf.c
index 140186fe1d1e..2741a07df692 100644
--- a/drivers/s390/scsi/zfcp_fsf.c
+++ b/drivers/s390/scsi/zfcp_fsf.c
@@ -2105,7 +2105,7 @@ static void zfcp_fsf_open_lun_handler(struct zfcp_fsf_req *req)
case FSF_PORT_HANDLE_NOT_VALID:
zfcp_erp_adapter_reopen(adapter, 0, "fsouh_1");
- fallthrough;
+ break;
case FSF_LUN_ALREADY_OPEN:
break;
case FSF_PORT_BOXED:
diff --git a/drivers/scsi/aic7xxx/aic79xx_core.c b/drivers/scsi/aic7xxx/aic79xx_core.c
index 1c617c0d5899..e8fa68d96cde 100644
--- a/drivers/scsi/aic7xxx/aic79xx_core.c
+++ b/drivers/scsi/aic7xxx/aic79xx_core.c
@@ -8175,7 +8175,7 @@ ahd_search_qinfifo(struct ahd_softc *ahd, int target, char channel,
if ((scb->flags & SCB_ACTIVE) == 0)
printk("Inactive SCB in qinfifo\n");
ahd_done_with_status(ahd, scb, status);
- fallthrough;
+ break;
case SEARCH_REMOVE:
break;
case SEARCH_PRINT:
@@ -8295,7 +8295,7 @@ ahd_search_qinfifo(struct ahd_softc *ahd, int target, char channel,
}
case SEARCH_PRINT:
printk(" 0x%x", SCB_GET_TAG(scb));
- fallthrough;
+ break;
case SEARCH_COUNT:
break;
}
diff --git a/drivers/scsi/aic94xx/aic94xx_tmf.c b/drivers/scsi/aic94xx/aic94xx_tmf.c
index 0eb6e206a2b4..fdd0f34fcb17 100644
--- a/drivers/scsi/aic94xx/aic94xx_tmf.c
+++ b/drivers/scsi/aic94xx/aic94xx_tmf.c
@@ -490,7 +490,7 @@ int asd_abort_task(struct sas_task *task)
switch (tcs.dl_opcode) {
default:
res = asd_clear_nexus(task);
- fallthrough;
+ break;
case TC_NO_ERROR:
break;
/* The task hasn't been sent to the device xor
diff --git a/drivers/scsi/lpfc/lpfc_sli.c b/drivers/scsi/lpfc/lpfc_sli.c
index e158cd77d387..253a4a41ebc9 100644
--- a/drivers/scsi/lpfc/lpfc_sli.c
+++ b/drivers/scsi/lpfc/lpfc_sli.c
@@ -9339,7 +9339,7 @@ __lpfc_sli_issue_iocb_s3(struct lpfc_hba *phba, uint32_t ring_number,
*/
if (piocb->iocb_cmpl)
piocb->iocb_cmpl = NULL;
- fallthrough;
+ break;
case CMD_CREATE_XRI_CR:
case CMD_CLOSE_XRI_CN:
case CMD_CLOSE_XRI_CX:
diff --git a/drivers/scsi/smartpqi/smartpqi_init.c b/drivers/scsi/smartpqi/smartpqi_init.c
index 9d0229656681..f2be6feea226 100644
--- a/drivers/scsi/smartpqi/smartpqi_init.c
+++ b/drivers/scsi/smartpqi/smartpqi_init.c
@@ -2937,7 +2937,7 @@ static int pqi_process_io_intr(struct pqi_ctrl_info *ctrl_info, struct pqi_queue
case PQI_RESPONSE_IU_AIO_PATH_IO_SUCCESS:
if (io_request->scmd)
io_request->scmd->result = 0;
- fallthrough;
+ break;
case PQI_RESPONSE_IU_GENERAL_MANAGEMENT:
break;
case PQI_RESPONSE_IU_VENDOR_GENERAL:
diff --git a/drivers/scsi/sr.c b/drivers/scsi/sr.c
index 3b3a53c6a0de..1216396284f9 100644
--- a/drivers/scsi/sr.c
+++ b/drivers/scsi/sr.c
@@ -880,7 +880,7 @@ static void get_sectorsize(struct scsi_cd *cd)
fallthrough;
case 2048:
cd->capacity *= 4;
- fallthrough;
+ break;
case 512:
break;
default:
diff --git a/drivers/tty/serial/sunsu.c b/drivers/tty/serial/sunsu.c
index 319e5ceb6130..de3fbdcfa7f8 100644
--- a/drivers/tty/serial/sunsu.c
+++ b/drivers/tty/serial/sunsu.c
@@ -514,7 +514,7 @@ static void receive_kbd_ms_chars(struct uart_sunsu_port *up, int is_break)
switch (ret) {
case 2:
sunsu_change_mouse_baud(up);
- fallthrough;
+ break;
case 1:
break;
diff --git a/drivers/tty/serial/sunzilog.c b/drivers/tty/serial/sunzilog.c
index 001e19d7c17d..a1f5c73be291 100644
--- a/drivers/tty/serial/sunzilog.c
+++ b/drivers/tty/serial/sunzilog.c
@@ -306,7 +306,7 @@ static void sunzilog_kbdms_receive_chars(struct uart_sunzilog_port *up,
switch (ret) {
case 2:
sunzilog_change_mouse_baud(up);
- fallthrough;
+ break;
case 1:
break;
diff --git a/drivers/tty/vt/vt_ioctl.c b/drivers/tty/vt/vt_ioctl.c
index 2ea76a09e07f..c7ca691f1d2b 100644
--- a/drivers/tty/vt/vt_ioctl.c
+++ b/drivers/tty/vt/vt_ioctl.c
@@ -255,7 +255,7 @@ static int vt_kdsetmode(struct vc_data *vc, unsigned long mode)
case KD_TEXT0:
case KD_TEXT1:
mode = KD_TEXT;
- fallthrough;
+ break;
case KD_TEXT:
break;
default:
diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
index 2eb34c8b4065..85f04dca7ae9 100644
--- a/drivers/usb/dwc3/core.c
+++ b/drivers/usb/dwc3/core.c
@@ -646,7 +646,7 @@ static int dwc3_phy_setup(struct dwc3 *dwc)
if (!(reg & DWC3_GUSB2PHYCFG_ULPI_UTMI))
break;
}
- fallthrough;
+ break;
case DWC3_GHWPARAMS3_HSPHY_IFC_ULPI:
default:
break;
diff --git a/drivers/usb/gadget/legacy/inode.c b/drivers/usb/gadget/legacy/inode.c
index 1b430b36d0a6..261ec2dd52c6 100644
--- a/drivers/usb/gadget/legacy/inode.c
+++ b/drivers/usb/gadget/legacy/inode.c
@@ -1717,7 +1717,7 @@ gadgetfs_suspend (struct usb_gadget *gadget)
case STATE_DEV_UNCONNECTED:
next_event (dev, GADGETFS_SUSPEND);
ep0_readable (dev);
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/usb/gadget/udc/pxa25x_udc.c b/drivers/usb/gadget/udc/pxa25x_udc.c
index 10324a7334fe..a5a754ba6bc9 100644
--- a/drivers/usb/gadget/udc/pxa25x_udc.c
+++ b/drivers/usb/gadget/udc/pxa25x_udc.c
@@ -2340,12 +2340,12 @@ static int pxa25x_udc_probe(struct platform_device *pdev)
case PXA250_A0:
case PXA250_A1:
/* A0/A1 "not released"; ep 13, 15 unusable */
- fallthrough;
+ break;
case PXA250_B2: case PXA210_B2:
case PXA250_B1: case PXA210_B1:
case PXA250_B0: case PXA210_B0:
/* OUT-DMA is broken ... */
- fallthrough;
+ break;
case PXA250_C0: case PXA210_C0:
break;
#elif defined(CONFIG_ARCH_IXP4XX)
diff --git a/drivers/usb/host/ohci-hcd.c b/drivers/usb/host/ohci-hcd.c
index dd37e77dae00..9ea59b99535e 100644
--- a/drivers/usb/host/ohci-hcd.c
+++ b/drivers/usb/host/ohci-hcd.c
@@ -1051,7 +1051,7 @@ int ohci_restart(struct ohci_hcd *ohci)
ed->ed_next = ohci->ed_rm_list;
ed->ed_prev = NULL;
ohci->ed_rm_list = ed;
- fallthrough;
+ break;
case ED_UNLINK:
break;
default:
diff --git a/drivers/usb/isp1760/isp1760-hcd.c b/drivers/usb/isp1760/isp1760-hcd.c
index dd74ab7a2f9c..30c168bccf70 100644
--- a/drivers/usb/isp1760/isp1760-hcd.c
+++ b/drivers/usb/isp1760/isp1760-hcd.c
@@ -792,7 +792,7 @@ static void collect_qtds(struct usb_hcd *hcd, struct isp1760_qh *qh,
case OUT_PID:
qtd->urb->actual_length +=
qtd->actual_length;
- fallthrough;
+ break;
case SETUP_PID:
break;
}
diff --git a/drivers/usb/musb/cppi_dma.c b/drivers/usb/musb/cppi_dma.c
index edb5b63d7063..a066aec2b4c1 100644
--- a/drivers/usb/musb/cppi_dma.c
+++ b/drivers/usb/musb/cppi_dma.c
@@ -975,7 +975,7 @@ static int cppi_channel_program(struct dma_channel *ch,
musb_dbg(musb, "%cX DMA%d not allocated!",
cppi_ch->transmit ? 'T' : 'R',
cppi_ch->index);
- fallthrough;
+ break;
case MUSB_DMA_STATUS_FREE:
break;
}
diff --git a/drivers/usb/phy/phy-fsl-usb.c b/drivers/usb/phy/phy-fsl-usb.c
index f34c9437a182..d5c3b548aa51 100644
--- a/drivers/usb/phy/phy-fsl-usb.c
+++ b/drivers/usb/phy/phy-fsl-usb.c
@@ -914,7 +914,7 @@ int usb_otg_start(struct platform_device *pdev)
fallthrough;
case FSL_USB2_PHY_UTMI:
temp |= PORTSC_PTS_UTMI;
- fallthrough;
+ break;
default:
break;
}
diff --git a/drivers/video/fbdev/stifb.c b/drivers/video/fbdev/stifb.c
index 265865610edc..aae5ca0b89c9 100644
--- a/drivers/video/fbdev/stifb.c
+++ b/drivers/video/fbdev/stifb.c
@@ -1157,7 +1157,7 @@ static int __init stifb_init_fb(struct sti_struct *sti, int bpp_pref)
dev_name);
goto out_err0;
}
- fallthrough;
+ break;
case S9000_ID_ARTIST:
case S9000_ID_HCRX:
case S9000_ID_TIMBER:
diff --git a/fs/afs/yfsclient.c b/fs/afs/yfsclient.c
index 3b1239b7e90d..6be481a98097 100644
--- a/fs/afs/yfsclient.c
+++ b/fs/afs/yfsclient.c
@@ -461,7 +461,7 @@ static int yfs_deliver_fs_fetch_data64(struct afs_call *call)
req->file_size = vp->scb.status.size;
call->unmarshall++;
- fallthrough;
+ break;
case 5:
break;
@@ -1363,7 +1363,7 @@ static int yfs_deliver_fs_get_volume_status(struct afs_call *call)
_debug("motd '%s'", p);
call->unmarshall++;
- fallthrough;
+ break;
case 8:
break;
@@ -1727,7 +1727,7 @@ static int yfs_deliver_fs_inline_bulk_status(struct afs_call *call)
xdr_decode_YFSVolSync(&bp, &op->volsync);
call->unmarshall++;
- fallthrough;
+ break;
case 6:
break;
@@ -1886,7 +1886,7 @@ static int yfs_deliver_fs_fetch_opaque_acl(struct afs_call *call)
xdr_decode_YFSVolSync(&bp, &op->volsync);
call->unmarshall++;
- fallthrough;
+ break;
case 6:
break;
diff --git a/fs/ceph/dir.c b/fs/ceph/dir.c
index d72e4a12bb69..67c3005fb88d 100644
--- a/fs/ceph/dir.c
+++ b/fs/ceph/dir.c
@@ -1740,7 +1740,7 @@ static int ceph_d_revalidate(struct dentry *dentry, unsigned int flags)
case -ENOENT:
if (d_really_is_negative(dentry))
valid = 1;
- fallthrough;
+ break;
default:
break;
}
diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c
index 6e95c85fe395..4bf60dcf13e1 100644
--- a/fs/nfs/nfs4proc.c
+++ b/fs/nfs/nfs4proc.c
@@ -9444,7 +9444,7 @@ static void nfs4_layoutreturn_done(struct rpc_task *task, void *calldata)
fallthrough;
default:
task->tk_status = 0;
- fallthrough;
+ break;
case 0:
break;
case -NFS4ERR_DELAY:
diff --git a/fs/nfs_common/nfsacl.c b/fs/nfs_common/nfsacl.c
index d056ad2fdefd..009c1e434aa5 100644
--- a/fs/nfs_common/nfsacl.c
+++ b/fs/nfs_common/nfsacl.c
@@ -237,7 +237,7 @@ posix_acl_from_nfsacl(struct posix_acl *acl)
break;
case ACL_MASK:
mask = pa;
- fallthrough;
+ break;
case ACL_OTHER:
break;
}
diff --git a/kernel/bpf/verifier.c b/kernel/bpf/verifier.c
index 86fdebb5ffd8..c88c7a7d77fb 100644
--- a/kernel/bpf/verifier.c
+++ b/kernel/bpf/verifier.c
@@ -5334,7 +5334,7 @@ static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env,
off_reg == dst_reg ? dst : src);
return -EACCES;
}
- fallthrough;
+ break;
default:
break;
}
diff --git a/kernel/sched/topology.c b/kernel/sched/topology.c
index da3cd60e4b78..c6c8699f466c 100644
--- a/kernel/sched/topology.c
+++ b/kernel/sched/topology.c
@@ -1233,7 +1233,7 @@ static void __free_domain_allocs(struct s_data *d, enum s_alloc what,
fallthrough;
case sa_sd_storage:
__sdt_free(cpu_map);
- fallthrough;
+ break;
case sa_none:
break;
}
diff --git a/kernel/trace/trace_events_filter.c b/kernel/trace/trace_events_filter.c
index 78a678eeb140..52df27e45843 100644
--- a/kernel/trace/trace_events_filter.c
+++ b/kernel/trace/trace_events_filter.c
@@ -1273,7 +1273,7 @@ static int parse_pred(const char *str, void *data,
switch (op) {
case OP_NE:
pred->not = 1;
- fallthrough;
+ break;
case OP_GLOB:
case OP_EQ:
break;
diff --git a/net/dccp/output.c b/net/dccp/output.c
index 50e6d5699bb2..5a4dbd7cee32 100644
--- a/net/dccp/output.c
+++ b/net/dccp/output.c
@@ -62,7 +62,7 @@ static int dccp_transmit_skb(struct sock *sk, struct sk_buff *skb)
switch (dcb->dccpd_type) {
case DCCP_PKT_DATA:
set_ack = 0;
- fallthrough;
+ break;
case DCCP_PKT_DATAACK:
case DCCP_PKT_RESET:
break;
diff --git a/net/ipv4/ip_output.c b/net/ipv4/ip_output.c
index 825e381e9909..3cf38c0bedf3 100644
--- a/net/ipv4/ip_output.c
+++ b/net/ipv4/ip_output.c
@@ -333,7 +333,7 @@ static int ip_mc_finish_output(struct net *net, struct sock *sk,
switch (ret) {
case NET_XMIT_CN:
do_cn = true;
- fallthrough;
+ break;
case NET_XMIT_SUCCESS:
break;
default:
diff --git a/net/netfilter/nf_tables_api.c b/net/netfilter/nf_tables_api.c
index 97fb6f776114..4844781699d5 100644
--- a/net/netfilter/nf_tables_api.c
+++ b/net/netfilter/nf_tables_api.c
@@ -8525,7 +8525,7 @@ static int nft_verdict_init(const struct nft_ctx *ctx, struct nft_data *data,
default:
return -EINVAL;
}
- fallthrough;
+ break;
case NFT_CONTINUE:
case NFT_BREAK:
case NFT_RETURN:
diff --git a/net/rxrpc/input.c b/net/rxrpc/input.c
index 667c44aa5a63..b654b8c65d10 100644
--- a/net/rxrpc/input.c
+++ b/net/rxrpc/input.c
@@ -1101,7 +1101,7 @@ static void rxrpc_input_implicit_end_call(struct rxrpc_sock *rx,
switch (READ_ONCE(call->state)) {
case RXRPC_CALL_SERVER_AWAIT_ACK:
rxrpc_call_completed(call);
- fallthrough;
+ break;
case RXRPC_CALL_COMPLETE:
break;
default:
@@ -1265,7 +1265,7 @@ int rxrpc_input_packet(struct sock *udp_sk, struct sk_buff *skb)
case RXRPC_PACKET_TYPE_ACKALL:
if (sp->hdr.callNumber == 0)
goto bad_message;
- fallthrough;
+ break;
case RXRPC_PACKET_TYPE_ABORT:
break;
diff --git a/net/sctp/outqueue.c b/net/sctp/outqueue.c
index 3fd06a27105d..f8ce1b3925a9 100644
--- a/net/sctp/outqueue.c
+++ b/net/sctp/outqueue.c
@@ -1030,7 +1030,7 @@ static void sctp_outq_flush_data(struct sctp_flush_ctx *ctx,
if (!ctx->packet || !ctx->packet->has_cookie_echo)
return;
- fallthrough;
+ break;
case SCTP_STATE_ESTABLISHED:
case SCTP_STATE_SHUTDOWN_PENDING:
case SCTP_STATE_SHUTDOWN_RECEIVED:
diff --git a/sound/soc/codecs/ak4613.c b/sound/soc/codecs/ak4613.c
index 8d663e8d64c4..b35193eb9057 100644
--- a/sound/soc/codecs/ak4613.c
+++ b/sound/soc/codecs/ak4613.c
@@ -457,7 +457,7 @@ static int ak4613_set_bias_level(struct snd_soc_component *component,
fallthrough;
case SND_SOC_BIAS_STANDBY:
mgmt1 |= PMVR;
- fallthrough;
+ break;
case SND_SOC_BIAS_OFF:
default:
break;
diff --git a/sound/soc/codecs/jz4770.c b/sound/soc/codecs/jz4770.c
index 298689a07168..734cf7809b7e 100644
--- a/sound/soc/codecs/jz4770.c
+++ b/sound/soc/codecs/jz4770.c
@@ -202,7 +202,7 @@ static int jz4770_codec_set_bias_level(struct snd_soc_component *codec,
REG_CR_VIC_SB_SLEEP, REG_CR_VIC_SB_SLEEP);
regmap_update_bits(regmap, JZ4770_CODEC_REG_CR_VIC,
REG_CR_VIC_SB, REG_CR_VIC_SB);
- fallthrough;
+ break;
default:
break;
}
^ permalink raw reply related
* Re: [PATCH] scsi: ibmvfc: Fix error return in ibmvfc_probe()
From: Tyrel Datwyler @ 2020-09-09 19:20 UTC (permalink / raw)
To: Jing Xiangfeng, mpe, benh, paulus, jejb, martin.petersen
Cc: linuxppc-dev, linux-kernel, linux-scsi
In-Reply-To: <20200907083949.154251-1-jingxiangfeng@huawei.com>
On 9/7/20 1:39 AM, Jing Xiangfeng wrote:
> Fix to return error code PTR_ERR() from the error handling case instead
> of 0.
>
> Signed-off-by: Jing Xiangfeng <jingxiangfeng@huawei.com>
Acked-by: Tyrel Datwyler <tyreld@linux.ibm.com>
> ---
> drivers/scsi/ibmvscsi/ibmvfc.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/scsi/ibmvscsi/ibmvfc.c b/drivers/scsi/ibmvscsi/ibmvfc.c
> index ea7c8930592d..70daa0605082 100644
> --- a/drivers/scsi/ibmvscsi/ibmvfc.c
> +++ b/drivers/scsi/ibmvscsi/ibmvfc.c
> @@ -4928,6 +4928,7 @@ static int ibmvfc_probe(struct vio_dev *vdev, const struct vio_device_id *id)
> if (IS_ERR(vhost->work_thread)) {
> dev_err(dev, "Couldn't create kernel thread: %ld\n",
> PTR_ERR(vhost->work_thread));
> + rc = PTR_ERR(vhost->work_thread);
> goto free_host_mem;
> }
>
>
^ permalink raw reply
* Re: remove the last set_fs() in common code, and remove it for x86 and powerpc v3
From: Segher Boessenkool @ 2020-09-09 18:40 UTC (permalink / raw)
To: Linus Torvalds
Cc: linux-arch, Kees Cook, the arch/x86 maintainers, Nick Desaulniers,
Linux Kernel Mailing List, Christoph Hellwig, Luis Chamberlain,
Al Viro, linux-fsdevel, linuxppc-dev, Alexey Dobriyan
In-Reply-To: <CAHk-=wgQNyeHxXfckd1WtiYnoDZP1Y_kD-tJKqWSksRoDZT=Aw@mail.gmail.com>
On Wed, Sep 09, 2020 at 10:31:34AM -0700, Linus Torvalds wrote:
> And apparently there are people working on this on the gcc side too,
> so it won't just be clang-specific. Nor kernel-specific in that Nick
> tells me some other projects are looking at using that asm goto with
> outputs too.
It will not work like this in GCC, no. The LLVM people know about that.
I do not know why they insist on pushing this, being incompatible and
everything.
Segher
^ permalink raw reply
* Re: [RFC PATCH v2 1/3] mm/gup: fix gup_fast with dynamic page table folding
From: Jason Gunthorpe @ 2020-09-09 18:03 UTC (permalink / raw)
To: Gerald Schaefer
Cc: Peter Zijlstra, Dave Hansen, Dave Hansen, Paul Mackerras,
linux-sparc, Alexander Gordeev, Claudio Imbrenda, Will Deacon,
linux-arch, linux-s390, Vasily Gorbik, Richard Weinberger,
linux-x86, Russell King, Christian Borntraeger, Ingo Molnar,
Catalin Marinas, Andrey Ryabinin, Heiko Carstens, Arnd Bergmann,
John Hubbard, Jeff Dike, linux-um, Borislav Petkov,
Andy Lutomirski, Thomas Gleixner, linux-arm, linux-mm,
linux-power, LKML, Andrew Morton, Linus Torvalds, Mike Rapoport
In-Reply-To: <20200909192534.442f8984@thinkpad>
On Wed, Sep 09, 2020 at 07:25:34PM +0200, Gerald Schaefer wrote:
> I actually had to draw myself a picture to get some hold of
> this, or rather a walk-through with a certain pud-crossing
> range in a folded 3-level scenario. Not sure if I would have
> understood my explanation above w/o that, but I hope you can
> make some sense out of it. Or draw yourself a picture :-)
What I don't understand is how does anything work with S390 today?
If the fix is only to change pxx_addr_end() then than generic code
like mm/pagewalk.c will iterate over a *different list* of page table
entries.
It's choice of entries to look at is entirely driven by pxx_addr_end().
Which suggest to me that mm/pagewalk.c also doesn't work properly
today on S390 and this issue is not really about stack variables?
Fundamentally if pXX_offset() and pXX_addr_end() must be consistent
together, if pXX_offset() is folded then pXX_addr_end() must cause a
single iteration of that level.
Jason
^ permalink raw reply
* Re: remove the last set_fs() in common code, and remove it for x86 and powerpc v3
From: Linus Torvalds @ 2020-09-09 17:31 UTC (permalink / raw)
To: Al Viro, Nick Desaulniers
Cc: linux-arch, Kees Cook, the arch/x86 maintainers,
Linux Kernel Mailing List, Alexey Dobriyan, Luis Chamberlain,
linux-fsdevel, linuxppc-dev, Christoph Hellwig
In-Reply-To: <20200903142803.GM1236603@ZenIV.linux.org.uk>
[-- Attachment #1: Type: text/plain, Size: 3002 bytes --]
On Thu, Sep 3, 2020 at 7:28 AM Al Viro <viro@zeniv.linux.org.uk> wrote:
>
> I can live with this series; do you want that in vfs.git#for-next?
Well, it's apparently there now (at least it's in your base.set_fs
branch, I didn't check actual -next).
So this is just a heads-up that I plan to merge the "asm goto" changes
on top of this during 5.10. Nick did the patch to make my patch-set
work either with or without the actual asm goto support, and I've been
running it privately now for several months.
And apparently there are people working on this on the gcc side too,
so it won't just be clang-specific. Nor kernel-specific in that Nick
tells me some other projects are looking at using that asm goto with
outputs too.
Anyway, the actual patch to use asm goto with outputs is fairly small
and not that interesting to people (since no released compiler
supports it), but part of the infrastructure to make it tiny is to
just get rid of the inlined "__get_user()" and "__put_user()" stuff.
I've ranted against those functions for a few years by now, so part of
this is to stop inlining them and make people think they are "good",
but part of it is also that those macros and inline functions are the
main remaining ones that mess with this all.
I'm attaching the two __get_user/__put_user patches here in case
anybody cares, but these are the pre-rebased ones, I'll make them work
with the new world order as it happens. The main change is:
(a) unify around a common special calling convention:
- %bx is clobbered
- %cx contains the user address on input, and the error value on output
- %ax/%dx contains the actual value (input for put, output for get,
of course)
(b) unify around using just a "call", using the model that
get/put_user already did.
- use "*_nocheck" for the double-underscore versions
- this still has to use inline asm because the calling convention is odd
- otherwise basically just a "call __{get,put}_user_[nocheck_]X"
where X is the size.
IOW, we unify around one single calling convention., and one single
model for actually getting things done.
I still want to remove the double-underscore versions entirely some
day - they have absolutely zero advantages compared to the full "do
address_ok as part of the operation" - but that's a separate thing. At
least they can be unified.
And the reason for this all is obviously that now *only* the
"unsafe_{get,put}_user()" cases with the error label output are the
"fast inlined" cases. They are the only ones that _can_ be done
quickly inline, since the slow clac/stac is not part of them. Plus
they already have that unified usage model of the error label, even if
unsafe_get_user() currently does it manually because "asm goto" with
outputs doesn't work in existing compilers.
Comments?
I suspect people won't care, but I thought I'd post these so that
there won't be any surprises during the next merge window when I apply
them after merging the set_fs() removal branch..
Linus
[-- Attachment #2: 0001-x86-Make-__get_user-generate-an-out-of-line-call.patch --]
[-- Type: text/x-patch, Size: 10283 bytes --]
From 52c7574a0d15722df52158a3d766803662d9a6ff Mon Sep 17 00:00:00 2001
From: Linus Torvalds <torvalds@linux-foundation.org>
Date: Wed, 8 Apr 2020 12:50:01 -0700
Subject: [PATCH 1/6] x86: Make __get_user() generate an out-of-line call
Instead of inlining the whole stac/lfence/mov/clac sequence (which also
requires individual exception table entries and several asm instruction
alternatives entries), just generate "call __get_user_nocheck_X" for the
__get_user() cases.
We can use all the same infrastructure that we already do for the
regular "get_user()", and the end result is simpler source code, and
much simpler code generation.
It also measn that when I introduce asm goto with input for
"unsafe_get_user()", there are no nasty interactions with the
__get_user() code.
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
---
arch/x86/include/asm/uaccess.h | 128 ++++++++++++++-------------------
arch/x86/lib/getuser.S | 60 ++++++++++++++++
2 files changed, 114 insertions(+), 74 deletions(-)
diff --git a/arch/x86/include/asm/uaccess.h b/arch/x86/include/asm/uaccess.h
index ecefaffd15d4..cf5a3f61db3b 100644
--- a/arch/x86/include/asm/uaccess.h
+++ b/arch/x86/include/asm/uaccess.h
@@ -96,25 +96,14 @@ static inline bool pagefault_disabled(void);
likely(!__range_not_ok(addr, size, user_addr_max())); \
})
-/*
- * These are the main single-value transfer routines. They automatically
- * use the right size if we just have the right pointer type.
- *
- * This gets kind of ugly. We want to return _two_ values in "get_user()"
- * and yet we don't want to do any pointers, because that is too much
- * of a performance impact. Thus we have a few rather ugly macros here,
- * and hide all the ugliness from the user.
- *
- * The "__xxx" versions of the user access functions are versions that
- * do not verify the address space, that must have been done previously
- * with a separate "access_ok()" call (this is used when we do multiple
- * accesses to the same area of user memory).
- */
-
extern int __get_user_1(void);
extern int __get_user_2(void);
extern int __get_user_4(void);
extern int __get_user_8(void);
+extern int __get_user_nocheck_1(void);
+extern int __get_user_nocheck_2(void);
+extern int __get_user_nocheck_4(void);
+extern int __get_user_nocheck_8(void);
extern int __get_user_bad(void);
#define __uaccess_begin() stac()
@@ -138,25 +127,12 @@ extern int __get_user_bad(void);
#define __typefits(x,type,not) \
__builtin_choose_expr(sizeof(x)<=sizeof(type),(unsigned type)0,not)
-/**
- * get_user - Get a simple variable from user space.
- * @x: Variable to store result.
- * @ptr: Source address, in user space.
- *
- * Context: User context only. This function may sleep if pagefaults are
- * enabled.
- *
- * This macro copies a single simple variable from user space to kernel
- * space. It supports simple types like char and int, but not larger
- * data types like structures or arrays.
- *
- * @ptr must have pointer-to-simple-variable type, and the result of
- * dereferencing @ptr must be assignable to @x without a cast.
- *
- * Return: zero on success, or -EFAULT on error.
- * On error, the variable @x is set to zero.
- */
/*
+ * This is used for both get_user() and __get_user() to expand to
+ * the proper special function call that has odd calling conventions
+ * due to returning both a value and an error, and that depends on
+ * the size of the pointer passed in.
+ *
* Careful: we have to cast the result to the type of the pointer
* for sign reasons.
*
@@ -169,13 +145,12 @@ extern int __get_user_bad(void);
* Clang/LLVM cares about the size of the register, but still wants
* the base register for something that ends up being a pair.
*/
-#define get_user(x, ptr) \
+#define do_get_user_call(fn,x,ptr) \
({ \
int __ret_gu; \
register __inttype(*(ptr)) __val_gu asm("%"_ASM_DX); \
__chk_user_ptr(ptr); \
- might_fault(); \
- asm volatile("call __get_user_%P4" \
+ asm volatile("call __" #fn "_%P4" \
: "=a" (__ret_gu), "=r" (__val_gu), \
ASM_CALL_CONSTRAINT \
: "0" (ptr), "i" (sizeof(*(ptr)))); \
@@ -183,6 +158,49 @@ extern int __get_user_bad(void);
__builtin_expect(__ret_gu, 0); \
})
+/**
+ * get_user - Get a simple variable from user space.
+ * @x: Variable to store result.
+ * @ptr: Source address, in user space.
+ *
+ * Context: User context only. This function may sleep if pagefaults are
+ * enabled.
+ *
+ * This macro copies a single simple variable from user space to kernel
+ * space. It supports simple types like char and int, but not larger
+ * data types like structures or arrays.
+ *
+ * @ptr must have pointer-to-simple-variable type, and the result of
+ * dereferencing @ptr must be assignable to @x without a cast.
+ *
+ * Return: zero on success, or -EFAULT on error.
+ * On error, the variable @x is set to zero.
+ */
+#define get_user(x,ptr) ({ might_fault(); do_get_user_call(get_user,x,ptr); })
+
+/**
+ * __get_user - Get a simple variable from user space, with less checking.
+ * @x: Variable to store result.
+ * @ptr: Source address, in user space.
+ *
+ * Context: User context only. This function may sleep if pagefaults are
+ * enabled.
+ *
+ * This macro copies a single simple variable from user space to kernel
+ * space. It supports simple types like char and int, but not larger
+ * data types like structures or arrays.
+ *
+ * @ptr must have pointer-to-simple-variable type, and the result of
+ * dereferencing @ptr must be assignable to @x without a cast.
+ *
+ * Caller must check the pointer with access_ok() before calling this
+ * function.
+ *
+ * Return: zero on success, or -EFAULT on error.
+ * On error, the variable @x is set to zero.
+ */
+#define __get_user(x,ptr) do_get_user_call(get_user_nocheck,x,ptr)
+
#define __put_user_x(size, x, ptr, __ret_pu) \
asm volatile("call __put_user_" #size : "=a" (__ret_pu) \
: "0" ((typeof(*(ptr)))(x)), "c" (ptr) : "ebx")
@@ -367,19 +385,6 @@ __pu_label: \
__builtin_expect(__pu_err, 0); \
})
-#define __get_user_nocheck(x, ptr, size) \
-({ \
- int __gu_err; \
- __inttype(*(ptr)) __gu_val; \
- __typeof__(ptr) __gu_ptr = (ptr); \
- __typeof__(size) __gu_size = (size); \
- __uaccess_begin_nospec(); \
- __get_user_size(__gu_val, __gu_ptr, __gu_size, __gu_err); \
- __uaccess_end(); \
- (x) = (__force __typeof__(*(ptr)))__gu_val; \
- __builtin_expect(__gu_err, 0); \
-})
-
/* FIXME: this hack is definitely wrong -AK */
struct __large_struct { unsigned long buf[100]; };
#define __m(x) (*(struct __large_struct __user *)(x))
@@ -396,31 +401,6 @@ struct __large_struct { unsigned long buf[100]; };
: : ltype(x), "m" (__m(addr)) \
: : label)
-/**
- * __get_user - Get a simple variable from user space, with less checking.
- * @x: Variable to store result.
- * @ptr: Source address, in user space.
- *
- * Context: User context only. This function may sleep if pagefaults are
- * enabled.
- *
- * This macro copies a single simple variable from user space to kernel
- * space. It supports simple types like char and int, but not larger
- * data types like structures or arrays.
- *
- * @ptr must have pointer-to-simple-variable type, and the result of
- * dereferencing @ptr must be assignable to @x without a cast.
- *
- * Caller must check the pointer with access_ok() before calling this
- * function.
- *
- * Return: zero on success, or -EFAULT on error.
- * On error, the variable @x is set to zero.
- */
-
-#define __get_user(x, ptr) \
- __get_user_nocheck((x), (ptr), sizeof(*(ptr)))
-
/**
* __put_user - Write a simple value into user space, with less checking.
* @x: Value to copy to user space.
diff --git a/arch/x86/lib/getuser.S b/arch/x86/lib/getuser.S
index c8a85b512796..2cd902e06062 100644
--- a/arch/x86/lib/getuser.S
+++ b/arch/x86/lib/getuser.S
@@ -35,6 +35,8 @@
#include <asm/smap.h>
#include <asm/export.h>
+#define ASM_BARRIER_NOSPEC ALTERNATIVE "", "lfence", X86_FEATURE_LFENCE_RDTSC
+
.text
SYM_FUNC_START(__get_user_1)
mov PER_CPU_VAR(current_task), %_ASM_DX
@@ -114,6 +116,52 @@ SYM_FUNC_START(__get_user_8)
SYM_FUNC_END(__get_user_8)
EXPORT_SYMBOL(__get_user_8)
+/* .. and the same for __get_user, just without the range checks */
+SYM_FUNC_START(__get_user_nocheck_1)
+ ASM_STAC
+ ASM_BARRIER_NOSPEC
+6: movzbl (%_ASM_AX),%edx
+ xor %eax,%eax
+ ASM_CLAC
+ ret
+SYM_FUNC_END(__get_user_nocheck_1)
+EXPORT_SYMBOL(__get_user_nocheck_1)
+
+SYM_FUNC_START(__get_user_nocheck_2)
+ ASM_STAC
+ ASM_BARRIER_NOSPEC
+7: movzwl (%_ASM_AX),%edx
+ xor %eax,%eax
+ ASM_CLAC
+ ret
+SYM_FUNC_END(__get_user_nocheck_2)
+EXPORT_SYMBOL(__get_user_nocheck_2)
+
+SYM_FUNC_START(__get_user_nocheck_4)
+ ASM_STAC
+ ASM_BARRIER_NOSPEC
+8: movl (%_ASM_AX),%edx
+ xor %eax,%eax
+ ASM_CLAC
+ ret
+SYM_FUNC_END(__get_user_nocheck_4)
+EXPORT_SYMBOL(__get_user_nocheck_4)
+
+SYM_FUNC_START(__get_user_nocheck_8)
+ ASM_STAC
+ ASM_BARRIER_NOSPEC
+#ifdef CONFIG_X86_64
+9: movq (%_ASM_AX),%rdx
+#else
+9: movl (%_ASM_AX),%edx
+10: movl 4(%_ASM_AX),%ecx
+#endif
+ xor %eax,%eax
+ ASM_CLAC
+ ret
+SYM_FUNC_END(__get_user_nocheck_8)
+EXPORT_SYMBOL(__get_user_nocheck_8)
+
SYM_CODE_START_LOCAL(.Lbad_get_user_clac)
ASM_CLAC
@@ -134,6 +182,7 @@ bad_get_user_8:
SYM_CODE_END(.Lbad_get_user_8_clac)
#endif
+/* get_user */
_ASM_EXTABLE_UA(1b, .Lbad_get_user_clac)
_ASM_EXTABLE_UA(2b, .Lbad_get_user_clac)
_ASM_EXTABLE_UA(3b, .Lbad_get_user_clac)
@@ -143,3 +192,14 @@ SYM_CODE_END(.Lbad_get_user_8_clac)
_ASM_EXTABLE_UA(4b, .Lbad_get_user_8_clac)
_ASM_EXTABLE_UA(5b, .Lbad_get_user_8_clac)
#endif
+
+/* __get_user */
+ _ASM_EXTABLE_UA(6b, .Lbad_get_user_clac)
+ _ASM_EXTABLE_UA(7b, .Lbad_get_user_clac)
+ _ASM_EXTABLE_UA(8b, .Lbad_get_user_clac)
+#ifdef CONFIG_X86_64
+ _ASM_EXTABLE_UA(9b, .Lbad_get_user_clac)
+#else
+ _ASM_EXTABLE_UA(9b, .Lbad_get_user_8_clac)
+ _ASM_EXTABLE_UA(10b, .Lbad_get_user_8_clac)
+#endif
--
2.28.0.218.gc12ef3d349
[-- Attachment #3: 0002-x86-Make-__put_user-generate-an-out-of-line-call.patch --]
[-- Type: text/x-patch, Size: 9905 bytes --]
From 3b07edf57b7d5a705a2fcf1ec92c9399efa51441 Mon Sep 17 00:00:00 2001
From: Linus Torvalds <torvalds@linux-foundation.org>
Date: Wed, 8 Apr 2020 13:36:49 -0700
Subject: [PATCH 2/6] x86: Make __put_user() generate an out-of-line call
Instead of inlining the stac/mov/clac sequence (which also requires
individual exception table entries and several asm instruction
alternatives entries), just generate "call __put_user_nocheck_X" for the
__put_user() cases, the same way we changed __get_user earlier.
Unlike the get_user() case, we didn't have the same nice infrastructure
to just generate the call with a single case, so this actually has to
change some of the infrastructure in order to do this. But that only
cleans up the code further.
So now, instead of using a case statement for the sizes, we just do the
same thing we've done on tge get_user() side for a long time: use the
size as an immediate constant to the asm, and generate the asm that way
directly.
In order to handle the special case of 64-bit data on a 32-bit kernel, I
needed to change the calling convention slightly: the data is passed in
%eax[:%edx], the pointer in %ecx, and the return value is also returned
in %ecx. It used to be returned in %eax, but because of how %eax can
now be a double register input, we don't want mix that with a
single-register output.
The actual low-level asm is easier to handle: we'll just share the code
between the checking and non-checking case, with the non-checking case
jumping into the middle of the function. That may sound a bit too
special, but this code is all very very special anyway, so...
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
---
arch/x86/include/asm/uaccess.h | 119 ++++++++++++---------------------
arch/x86/lib/putuser.S | 22 ++++--
2 files changed, 60 insertions(+), 81 deletions(-)
diff --git a/arch/x86/include/asm/uaccess.h b/arch/x86/include/asm/uaccess.h
index cf5a3f61db3b..9a96399d76f0 100644
--- a/arch/x86/include/asm/uaccess.h
+++ b/arch/x86/include/asm/uaccess.h
@@ -201,11 +201,6 @@ extern int __get_user_bad(void);
*/
#define __get_user(x,ptr) do_get_user_call(get_user_nocheck,x,ptr)
-#define __put_user_x(size, x, ptr, __ret_pu) \
- asm volatile("call __put_user_" #size : "=a" (__ret_pu) \
- : "0" ((typeof(*(ptr)))(x)), "c" (ptr) : "ebx")
-
-
#ifdef CONFIG_X86_32
#define __put_user_goto_u64(x, addr, label) \
@@ -217,25 +212,41 @@ extern int __get_user_bad(void);
: : "A" (x), "r" (addr) \
: : label)
-#define __put_user_x8(x, ptr, __ret_pu) \
- asm volatile("call __put_user_8" : "=a" (__ret_pu) \
- : "A" ((typeof(*(ptr)))(x)), "c" (ptr) : "ebx")
#else
#define __put_user_goto_u64(x, ptr, label) \
__put_user_goto(x, ptr, "q", "er", label)
-#define __put_user_x8(x, ptr, __ret_pu) __put_user_x(8, x, ptr, __ret_pu)
#endif
extern void __put_user_bad(void);
/*
* Strange magic calling convention: pointer in %ecx,
- * value in %eax(:%edx), return value in %eax. clobbers %rbx
+ * value in %eax(:%edx), return value in %ecx. clobbers %rbx
*/
extern void __put_user_1(void);
extern void __put_user_2(void);
extern void __put_user_4(void);
extern void __put_user_8(void);
+extern void __put_user_nocheck_1(void);
+extern void __put_user_nocheck_2(void);
+extern void __put_user_nocheck_4(void);
+extern void __put_user_nocheck_8(void);
+
+#define do_put_user_call(fn,x,ptr) \
+({ \
+ int __ret_pu; \
+ register __typeof__(*(ptr)) __val_pu asm("%"_ASM_AX); \
+ __chk_user_ptr(ptr); \
+ __val_pu = (x); \
+ asm volatile("call __" #fn "_%P[size]" \
+ : "=c" (__ret_pu), \
+ ASM_CALL_CONSTRAINT \
+ : "0" (ptr), \
+ "r" (__val_pu), \
+ [size] "i" (sizeof(*(ptr))) \
+ :"ebx"); \
+ __builtin_expect(__ret_pu, 0); \
+})
/**
* put_user - Write a simple value into user space.
@@ -254,32 +265,29 @@ extern void __put_user_8(void);
*
* Return: zero on success, or -EFAULT on error.
*/
-#define put_user(x, ptr) \
-({ \
- int __ret_pu; \
- __typeof__(*(ptr)) __pu_val; \
- __chk_user_ptr(ptr); \
- might_fault(); \
- __pu_val = x; \
- switch (sizeof(*(ptr))) { \
- case 1: \
- __put_user_x(1, __pu_val, ptr, __ret_pu); \
- break; \
- case 2: \
- __put_user_x(2, __pu_val, ptr, __ret_pu); \
- break; \
- case 4: \
- __put_user_x(4, __pu_val, ptr, __ret_pu); \
- break; \
- case 8: \
- __put_user_x8(__pu_val, ptr, __ret_pu); \
- break; \
- default: \
- __put_user_x(X, __pu_val, ptr, __ret_pu); \
- break; \
- } \
- __builtin_expect(__ret_pu, 0); \
-})
+#define put_user(x, ptr) ({ might_fault(); do_put_user_call(put_user,x,ptr); })
+
+/**
+ * __put_user - Write a simple value into user space, with less checking.
+ * @x: Value to copy to user space.
+ * @ptr: Destination address, in user space.
+ *
+ * Context: User context only. This function may sleep if pagefaults are
+ * enabled.
+ *
+ * This macro copies a single simple value from kernel space to user
+ * space. It supports simple types like char and int, but not larger
+ * data types like structures or arrays.
+ *
+ * @ptr must have pointer-to-simple-variable type, and @x must be assignable
+ * to the result of dereferencing @ptr.
+ *
+ * Caller must check the pointer with access_ok() before calling this
+ * function.
+ *
+ * Return: zero on success, or -EFAULT on error.
+ */
+#define __put_user(x, ptr) do_put_user_call(put_user_nocheck,x,ptr)
#define __put_user_size(x, ptr, size, label) \
do { \
@@ -370,21 +378,6 @@ do { \
: [umem] "m" (__m(addr)), \
[efault] "i" (-EFAULT), "0" (err))
-#define __put_user_nocheck(x, ptr, size) \
-({ \
- __label__ __pu_label; \
- int __pu_err = -EFAULT; \
- __typeof__(*(ptr)) __pu_val = (x); \
- __typeof__(ptr) __pu_ptr = (ptr); \
- __typeof__(size) __pu_size = (size); \
- __uaccess_begin(); \
- __put_user_size(__pu_val, __pu_ptr, __pu_size, __pu_label); \
- __pu_err = 0; \
-__pu_label: \
- __uaccess_end(); \
- __builtin_expect(__pu_err, 0); \
-})
-
/* FIXME: this hack is definitely wrong -AK */
struct __large_struct { unsigned long buf[100]; };
#define __m(x) (*(struct __large_struct __user *)(x))
@@ -401,30 +394,6 @@ struct __large_struct { unsigned long buf[100]; };
: : ltype(x), "m" (__m(addr)) \
: : label)
-/**
- * __put_user - Write a simple value into user space, with less checking.
- * @x: Value to copy to user space.
- * @ptr: Destination address, in user space.
- *
- * Context: User context only. This function may sleep if pagefaults are
- * enabled.
- *
- * This macro copies a single simple value from kernel space to user
- * space. It supports simple types like char and int, but not larger
- * data types like structures or arrays.
- *
- * @ptr must have pointer-to-simple-variable type, and @x must be assignable
- * to the result of dereferencing @ptr.
- *
- * Caller must check the pointer with access_ok() before calling this
- * function.
- *
- * Return: zero on success, or -EFAULT on error.
- */
-
-#define __put_user(x, ptr) \
- __put_user_nocheck((__typeof__(*(ptr)))(x), (ptr), sizeof(*(ptr)))
-
extern unsigned long
copy_from_user_nmi(void *to, const void __user *from, unsigned long n);
extern __must_check long
diff --git a/arch/x86/lib/putuser.S b/arch/x86/lib/putuser.S
index 7c7c92db8497..b34a17763f28 100644
--- a/arch/x86/lib/putuser.S
+++ b/arch/x86/lib/putuser.S
@@ -25,7 +25,9 @@
* Inputs: %eax[:%edx] contains the data
* %ecx contains the address
*
- * Outputs: %eax is error code (0 or -EFAULT)
+ * Outputs: %ecx is error code (0 or -EFAULT)
+ *
+ * Clobbers: %ebx needed for task pointer
*
* These functions should not modify any other registers,
* as they get called from within inline assembly.
@@ -38,13 +40,15 @@ SYM_FUNC_START(__put_user_1)
ENTER
cmp TASK_addr_limit(%_ASM_BX),%_ASM_CX
jae .Lbad_put_user
+SYM_INNER_LABEL(__put_user_nocheck_1, SYM_L_GLOBAL)
ASM_STAC
1: movb %al,(%_ASM_CX)
- xor %eax,%eax
+ xor %ecx,%ecx
ASM_CLAC
ret
SYM_FUNC_END(__put_user_1)
EXPORT_SYMBOL(__put_user_1)
+EXPORT_SYMBOL(__put_user_nocheck_1)
SYM_FUNC_START(__put_user_2)
ENTER
@@ -52,13 +56,15 @@ SYM_FUNC_START(__put_user_2)
sub $1,%_ASM_BX
cmp %_ASM_BX,%_ASM_CX
jae .Lbad_put_user
+SYM_INNER_LABEL(__put_user_nocheck_2, SYM_L_GLOBAL)
ASM_STAC
2: movw %ax,(%_ASM_CX)
- xor %eax,%eax
+ xor %ecx,%ecx
ASM_CLAC
ret
SYM_FUNC_END(__put_user_2)
EXPORT_SYMBOL(__put_user_2)
+EXPORT_SYMBOL(__put_user_nocheck_2)
SYM_FUNC_START(__put_user_4)
ENTER
@@ -66,13 +72,15 @@ SYM_FUNC_START(__put_user_4)
sub $3,%_ASM_BX
cmp %_ASM_BX,%_ASM_CX
jae .Lbad_put_user
+SYM_INNER_LABEL(__put_user_nocheck_4, SYM_L_GLOBAL)
ASM_STAC
3: movl %eax,(%_ASM_CX)
- xor %eax,%eax
+ xor %ecx,%ecx
ASM_CLAC
ret
SYM_FUNC_END(__put_user_4)
EXPORT_SYMBOL(__put_user_4)
+EXPORT_SYMBOL(__put_user_nocheck_4)
SYM_FUNC_START(__put_user_8)
ENTER
@@ -80,21 +88,23 @@ SYM_FUNC_START(__put_user_8)
sub $7,%_ASM_BX
cmp %_ASM_BX,%_ASM_CX
jae .Lbad_put_user
+SYM_INNER_LABEL(__put_user_nocheck_8, SYM_L_GLOBAL)
ASM_STAC
4: mov %_ASM_AX,(%_ASM_CX)
#ifdef CONFIG_X86_32
5: movl %edx,4(%_ASM_CX)
#endif
- xor %eax,%eax
+ xor %ecx,%ecx
ASM_CLAC
RET
SYM_FUNC_END(__put_user_8)
EXPORT_SYMBOL(__put_user_8)
+EXPORT_SYMBOL(__put_user_nocheck_8)
SYM_CODE_START_LOCAL(.Lbad_put_user_clac)
ASM_CLAC
.Lbad_put_user:
- movl $-EFAULT,%eax
+ movl $-EFAULT,%ecx
RET
SYM_CODE_END(.Lbad_put_user_clac)
--
2.28.0.218.gc12ef3d349
^ permalink raw reply related
* Re: [RFC PATCH v2 1/3] mm/gup: fix gup_fast with dynamic page table folding
From: Gerald Schaefer @ 2020-09-09 17:25 UTC (permalink / raw)
To: Dave Hansen
Cc: Peter Zijlstra, Dave Hansen, linux-mm, Paul Mackerras,
linux-sparc, Alexander Gordeev, Claudio Imbrenda, Will Deacon,
linux-arch, linux-s390, Vasily Gorbik, Christian Borntraeger,
Richard Weinberger, linux-x86, Russell King, Jason Gunthorpe,
Ingo Molnar, Catalin Marinas, Andrey Ryabinin, Heiko Carstens,
Arnd Bergmann, John Hubbard, Jeff Dike, linux-um, Borislav Petkov,
Andy Lutomirski, Thomas Gleixner, linux-arm, linux-power, LKML,
Andrew Morton, Linus Torvalds, Mike Rapoport
In-Reply-To: <aacad1b7-f121-44a5-f01d-385cb0f6351e@intel.com>
On Wed, 9 Sep 2020 09:18:46 -0700
Dave Hansen <dave.hansen@intel.com> wrote:
> On 9/9/20 5:29 AM, Gerald Schaefer wrote:
> > This only works well as long there are real pagetable pointers involved,
> > that can also be used for iteration. For gup_fast, or any other future
> > pagetable walkers using the READ_ONCE logic w/o lock, that is not true.
> > There are pointers involved to local pXd values on the stack, because of
> > the READ_ONCE logic, and our middle-level iteration will suddenly iterate
> > over such stack pointers instead of pagetable pointers.
>
> By "There are pointers involved to local pXd values on the stack", did
> you mean "locate" instead of "local"? That sentence confused me.
>
> Which code is it, exactly that allocates these troublesome on-stack pXd
> values, btw?
It is the gup_pXd_range() call sequence in mm/gup.c. It starts in
gup_pgd_range() with "pgdp = pgd_offset(current->mm, addr)" and then
the "pgd_t pgd = READ_ONCE(*pgdp)" which creates the first local
stack variable "pgd".
The next-level call to gup_p4d_range() gets this "pgd" value as
input, but not the original pgdp pointer where it was read from.
This is already the essential difference to other pagetable walkers
like e.g. walk_pXd_range() in mm/pagewalk.c, where the original
pointer is passed through. With READ_ONCE, that pointer must not
be further de-referenced, so instead the value is passed over.
In gup_p4d_range() we then have "p4dp = p4d_offset(&pgd, addr)",
with &pgd being a pointer to the passed over pgd value, so that's
the first pXd pointer that does not point directly to the pXd in
the page table, but a local stack variable.
With folded p4d, p4d_offset(&pgd, addr) will simply return
the passed-in &pgd pointer, so we now also have p4dp point to that.
That continues with "p4d_t p4d = READ_ONCE(*p4dp)", and that second
stack variable passed to gup_huge_pud() and so on. Due to inlining,
all those variables will not really be passed anywhere, but simply
sit on the stack.
So far, IIUC, that would also happen on x86 (or everywhere else
actually) for folded levels, i.e. some pXd_offset() calls would
simply return the passed in (stack) value pointer. This works
as designed, and it will not lead to the "iteration over stack
pointer" for anybody but s390, because the pXd_addr_end()
boundaries usually take care that you always return to pgd
level for iteration, and that is the only level with a real
pagetable pointer. For s390, we stay at the first non-folded
level and do the iteration there, which is fine for other
pagetable walkers using the original pointers, but not for
the READ_ONCE-style gup_fast.
I actually had to draw myself a picture to get some hold of
this, or rather a walk-through with a certain pud-crossing
range in a folded 3-level scenario. Not sure if I would have
understood my explanation above w/o that, but I hope you can
make some sense out of it. Or draw yourself a picture :-)
^ permalink raw reply
* Re: [RFC PATCH v2 1/3] mm/gup: fix gup_fast with dynamic page table folding
From: Dave Hansen @ 2020-09-09 16:18 UTC (permalink / raw)
To: Gerald Schaefer
Cc: Peter Zijlstra, Dave Hansen, linux-mm, Paul Mackerras,
linux-sparc, Alexander Gordeev, Claudio Imbrenda, Will Deacon,
linux-arch, linux-s390, Vasily Gorbik, Christian Borntraeger,
Richard Weinberger, linux-x86, Russell King, Jason Gunthorpe,
Ingo Molnar, Catalin Marinas, Andrey Ryabinin, Heiko Carstens,
Arnd Bergmann, John Hubbard, Jeff Dike, linux-um, Borislav Petkov,
Andy Lutomirski, Thomas Gleixner, linux-arm, linux-power, LKML,
Andrew Morton, Linus Torvalds, Mike Rapoport
In-Reply-To: <20200909142904.00b72921@thinkpad>
On 9/9/20 5:29 AM, Gerald Schaefer wrote:
> This only works well as long there are real pagetable pointers involved,
> that can also be used for iteration. For gup_fast, or any other future
> pagetable walkers using the READ_ONCE logic w/o lock, that is not true.
> There are pointers involved to local pXd values on the stack, because of
> the READ_ONCE logic, and our middle-level iteration will suddenly iterate
> over such stack pointers instead of pagetable pointers.
By "There are pointers involved to local pXd values on the stack", did
you mean "locate" instead of "local"? That sentence confused me.
Which code is it, exactly that allocates these troublesome on-stack pXd
values, btw?
> This will be addressed by making the pXd_addr_end() dynamic, for which
> we need to see the pXd value in order to determine its level / type.
Thanks for the explanation!
^ permalink raw reply
* Re: [RFC PATCH v2 0/3] mm/gup: fix gup_fast with dynamic page table folding
From: Gerald Schaefer @ 2020-09-09 16:12 UTC (permalink / raw)
To: Christophe Leroy
Cc: Peter Zijlstra, Catalin Marinas, Dave Hansen, linux-mm,
Paul Mackerras, linux-sparc, Alexander Gordeev, Claudio Imbrenda,
Will Deacon, linux-arch, linux-s390, Vasily Gorbik,
Jason Gunthorpe, Richard Weinberger, linux-x86, Russell King,
Christian Borntraeger, Ingo Molnar, Andrey Ryabinin, Jeff Dike,
Arnd Bergmann, John Hubbard, Heiko Carstens, linux-um,
Borislav Petkov, Andy Lutomirski, Thomas Gleixner, linux-arm,
Linus Torvalds, LKML, Andrew Morton, linux-power, Mike Rapoport
In-Reply-To: <20200908193650.1c1511d0@thinkpad>
On Tue, 8 Sep 2020 19:36:50 +0200
Gerald Schaefer <gerald.schaefer@linux.ibm.com> wrote:
[..]
>
> It seems now that the generalization is very well accepted so far,
> apart from some apparent issues on arm. Also, merging 2 + 3 and
> putting them first seems to be acceptable, so we could do that for
> v3, if there are no objections.
>
> Of course, we first need to address the few remaining issues for
> arm(32?), which do look quite confusing to me so far. BTW, sorry for
> the compile error with patch 3, I guess we did the cross-compile only
> for 1 + 2 applied, to see the bloat-o-meter changes. But I guess
> patch 3 already proved its usefulness by that :-)
Umm, replace "arm" with "power", sorry. No issues on arm so far, but
also no ack I think.
Thanks to Christophe for the power change, and to Mike for volunteering
for some cross compilation and cross-arch testing. Will send v3 with
merged and re-ordered patches after some more testing.
^ permalink raw reply
* Re: [PATCH v3] powerpc/pseries: explicitly reschedule during drmem_lmb list traversal
From: Michael Ellerman @ 2020-09-09 13:40 UTC (permalink / raw)
To: Nathan Lynch, linuxppc-dev; +Cc: tyreld, cheloha, ldufour
In-Reply-To: <20200813151131.2070161-1-nathanl@linux.ibm.com>
On Thu, 13 Aug 2020 10:11:31 -0500, Nathan Lynch wrote:
> The drmem lmb list can have hundreds of thousands of entries, and
> unfortunately lookups take the form of linear searches. As long as
> this is the case, traversals have the potential to monopolize the CPU
> and provoke lockup reports, workqueue stalls, and the like unless
> they explicitly yield.
>
> Rather than placing cond_resched() calls within various
> for_each_drmem_lmb() loop blocks in the code, put it in the iteration
> expression of the loop macro itself so users can't omit it.
>
> [...]
Applied to powerpc/next.
[1/1] powerpc/pseries: explicitly reschedule during drmem_lmb list traversal
https://git.kernel.org/powerpc/c/9d6792ffe140240ae54c881cc4183f9acc24b4df
cheers
^ permalink raw reply
* Re: [PATCH 0/5] powerpc: Remove five unused variables
From: Michael Ellerman @ 2020-09-09 13:37 UTC (permalink / raw)
To: mpe, zhengbin, linuxppc-dev, benh, paulus
In-Reply-To: <1574144074-142032-1-git-send-email-zhengbin13@huawei.com>
On Tue, 19 Nov 2019 14:14:29 +0800, zhengbin wrote:
> zhengbin (5):
> powerpc/fadump: Remove set but not used variable 'elf'
> powerpc/perf: Remove set but not used variable 'target'
> powerpc/powernv: Remove set but not used variable 'total_vfs'
> powerpc/powernv: Remove set but not used variable 'pdn'
> powerpc/powernv: Remove set but not used variable 'parent'
>
> [...]
Patches 1, 2 & 5 applied to powerpc/next.
[1/5] powerpc/fadump: Remove set but not used variable 'elf'
https://git.kernel.org/powerpc/c/738e6cad0ace88edec8f4ffa082749ad5df26409
[2/5] powerpc/perf: Remove set but not used variable 'target'
https://git.kernel.org/powerpc/c/ef23cf9a89a7aec19a29d548d1e219d436b23b6e
[5/5] powerpc/powernv: Remove set but not used variable 'parent'
https://git.kernel.org/powerpc/c/18102e4bcc47f5b5ac70e2e4461d022c1ee6df24
cheers
^ permalink raw reply
* Re: [PATCH v2 0/4] ocxl: Cleanup AFU interrupt allocation
From: Michael Ellerman @ 2020-09-09 13:37 UTC (permalink / raw)
To: ukrishn, clg, christophe_lombard, linuxppc-dev, ajd, mrochs,
Frederic Barrat
Cc: haren, groug
In-Reply-To: <20200403153838.29224-1-fbarrat@linux.ibm.com>
On Fri, 3 Apr 2020 17:38:34 +0200, Frederic Barrat wrote:
> Short series to cleanup AFU interrupt allocation for opencapi.
> Current code was using its own allocation service, calling opal
> directly to get the trigger page. This is not needed and we can use
> xive to achieve the same thing. The only caveat is that the trigger
> page address is only valid after the interrupt has been mapped, but
> that is not a problem with the way the code is using it.
> No functional change.
>
> [...]
Applied to powerpc/next.
[1/4] scsi: cxlflash: Access interrupt trigger page from xive directly
https://git.kernel.org/powerpc/c/1e89da5ef9c28c673e86048c89ef9495618d987d
[2/4] ocxl: Access interrupt trigger page from xive directly
https://git.kernel.org/powerpc/c/ad857d47df6a1adc9798558701dd5426643b859f
[3/4] ocxl: Don't return trigger page when allocating an interrupt
https://git.kernel.org/powerpc/c/dde6f18a8779dcd88d9fd5d6336032fee7e07fcd
[4/4] ocxl: Remove custom service to allocate interrupts
https://git.kernel.org/powerpc/c/374f6178f3483dcad151fc14b2fad92ed6652f07
cheers
^ permalink raw reply
* Re: [PATCH] powerpc: hwrng; fix missing of_node_put()
From: Michael Ellerman @ 2020-09-09 13:37 UTC (permalink / raw)
To: Michael Ellerman, Nicholas Mc Guire
Cc: linuxppc-dev, Paul Mackerras, linux-kernel
In-Reply-To: <1530522496-14816-1-git-send-email-hofrat@osadl.org>
On Mon, 2 Jul 2018 11:08:16 +0200, Nicholas Mc Guire wrote:
> The call to of_find_compatible_node() returns a node pointer with refcount
> incremented thus it must be explicitly decremented here before returning.
Applied to powerpc/next.
[1/1] powerpc/pseries: Fix missing of_node_put() in rng_init()
https://git.kernel.org/powerpc/c/67c3e59443f5fc77be39e2ce0db75fbfa78c7965
cheers
^ permalink raw reply
* Re: [PATCH] powerpc: icp-hv: fix missing of_node_put in success path
From: Michael Ellerman @ 2020-09-09 13:37 UTC (permalink / raw)
To: Benjamin Herrenschmidt, Nicholas Mc Guire
Cc: linuxppc-dev, Paul Mackerras, linux-kernel
In-Reply-To: <1530691407-3991-1-git-send-email-hofrat@osadl.org>
On Wed, 4 Jul 2018 10:03:27 +0200, Nicholas Mc Guire wrote:
> Both of_find_compatible_node() and of_find_node_by_type() will
> return a refcounted node on success - thus for the success path
> the node must be explicitly released with a of_node_put().
Applied to powerpc/next.
[1/1] powerpc/icp-hv: Fix missing of_node_put() in success path
https://git.kernel.org/powerpc/c/d3e669f31ec35856f5e85df9224ede5bdbf1bc7b
cheers
^ permalink raw reply
* Re: [PATCH 1/6] powerpc/powernv/smp: Fix spurious DBG() warning
From: Michael Ellerman @ 2020-09-09 13:37 UTC (permalink / raw)
To: Oliver O'Halloran, linuxppc-dev
In-Reply-To: <20200804005410.146094-2-oohall@gmail.com>
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1347 bytes --]
On Tue, 4 Aug 2020 10:54:05 +1000, Oliver O'Halloran wrote:
> When building with W=1 we get the following warning:
>
> arch/powerpc/platforms/powernv/smp.c: In function ‘pnv_smp_cpu_kill_self’:
> arch/powerpc/platforms/powernv/smp.c:276:16: error: suggest braces around
> empty body in an ‘if’ statement [-Werror=empty-body]
> 276 | cpu, srr1);
> | ^
> cc1: all warnings being treated as errors
>
> [...]
Applied to powerpc/next.
[1/6] powerpc/powernv/smp: Fix spurious DBG() warning
https://git.kernel.org/powerpc/c/f6bac19cf65c5be21d14a0c9684c8f560f2096dd
[2/6] powerpc/powernv: Include asm/powernv.h from the local powernv.h
https://git.kernel.org/powerpc/c/8471c1dd93de9a2278d41c527b76291e4ace8f1c
[3/6] powerpc/powernv: Staticify functions without prototypes
https://git.kernel.org/powerpc/c/3b70464aa78917e88c1d4bfc2100c344c0eda8e0
[4/6] powerpc/powernv: Fix spurious kerneldoc warnings in opal-prd.c
https://git.kernel.org/powerpc/c/fb248c3121af713f31736af359608491544cfc23
[5/6] powerpc/powernv: Remove set but not used variable 'parent'
https://git.kernel.org/powerpc/c/18102e4bcc47f5b5ac70e2e4461d022c1ee6df24
[6/6] powerpc/nx: Don't pack struct coprocessor_request_block
https://git.kernel.org/powerpc/c/3ced132a055c4e5046d21732393ae6848ff309e0
cheers
^ permalink raw reply
* Re: [PATCH] cxl: Rework error message for incompatible slots
From: Michael Ellerman @ 2020-09-09 13:37 UTC (permalink / raw)
To: ajd, christophe_lombard, Frederic Barrat, linuxppc-dev; +Cc: stable
In-Reply-To: <20200407115601.25453-1-fbarrat@linux.ibm.com>
On Tue, 7 Apr 2020 13:56:01 +0200, Frederic Barrat wrote:
> Improve the error message shown if a capi adapter is plugged on a
> capi-incompatible slot directly under the PHB (no intermediate switch).
Applied to powerpc/next.
[1/1] cxl: Rework error message for incompatible slots
https://git.kernel.org/powerpc/c/40ac790d99c6dd16b367d5c2339e446a5f1b0593
cheers
^ permalink raw reply
* Re: [PATCH] powerpc/oprofile: fix spelling mistake "contex" -> "context"
From: Michael Ellerman @ 2020-09-09 13:37 UTC (permalink / raw)
To: oprofile-list, Michael Ellerman, Benjamin Herrenschmidt,
Paul Mackerras, linuxppc-dev, Colin King, Robert Richter
Cc: kernel-janitors, linux-kernel
In-Reply-To: <20200804174316.402425-1-colin.king@canonical.com>
On Tue, 4 Aug 2020 18:43:16 +0100, Colin King wrote:
> There is a spelling mistake in a pr_debug message. Fix it.
Applied to powerpc/next.
[1/1] powerpc/oprofile: fix spelling mistake "contex" -> "context"
https://git.kernel.org/powerpc/c/346427e668163e85cbbe14e4d9a2ddd49df1536c
cheers
^ permalink raw reply
* Re: [v3 1/2] dts: ppc: t4240rdb: remove interrupts property
From: Michael Ellerman @ 2020-09-09 13:37 UTC (permalink / raw)
To: alexandre.belloni, robh+dt, a.zummo, mpe, leoyang.li, benh,
Biwen Li
Cc: linux-rtc, devicetree, linuxppc-dev, linux-kernel, Biwen Li
In-Reply-To: <20200527034228.23793-1-biwen.li@oss.nxp.com>
On Wed, 27 May 2020 11:42:27 +0800, Biwen Li wrote:
> Since the interrupt pin for RTC DS1374 is not connected
> to the CPU on T4240RDB, remove the interrupt property
> from the device tree.
>
> This also fix the following warning for hwclock.util-linux:
> $ hwclock.util-linux
> hwclock.util-linux: select() to /dev/rtc0
> to wait for clock tick timed out
Applied to powerpc/next.
[1/2] powerpc/dts/t4240rdb: remove interrupts property
https://git.kernel.org/powerpc/c/8c7614d648037b0776e0b76cb62911be3b059ea4
[2/2] powerc/dtc/t1024rdb: remove interrupts property
https://git.kernel.org/powerpc/c/843dc8ee23d1b353fa9cc24da3e52be0111d5931
cheers
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox