Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

block/partitions/acorn: Remove redundant assignments

Get rid of redundant assignments to a variable slot from function
adfspart_check_ADFS. It is being assigned a value that is never read
as we are breaking out from the switch case and the function ends.

Reported by clang-tidy [deadcode.DeadStores]

Signed-off-by: Michal Orzel <michalorzel.eng@gmail.com>
Link: https://lore.kernel.org/r/20220423113811.13335-3-michalorzel.eng@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>

authored by

Michal Orzel and committed by
Jens Axboe
83472682 7ab89db9

+2 -2
+2 -2
block/partitions/acorn.c
··· 282 282 #ifdef CONFIG_ACORN_PARTITION_RISCIX 283 283 case PARTITION_RISCIX_SCSI: 284 284 case PARTITION_RISCIX_MFM: 285 - slot = riscix_partition(state, start_sect, slot, 285 + riscix_partition(state, start_sect, slot, 286 286 nr_sects); 287 287 break; 288 288 #endif 289 289 290 290 case PARTITION_LINUX: 291 - slot = linux_partition(state, start_sect, slot, 291 + linux_partition(state, start_sect, slot, 292 292 nr_sects); 293 293 break; 294 294 }