Skip to content

Commit 63bc732

Browse files
ColinIanKingChristoph Hellwig
authored andcommitted
nvmet: remove redundant assignment after left shift
The left shift is followed by a re-assignment back to cc_css, the assignment is redundant. Fix this by replacing the "<<=" operator with "<<" instead. This cleans up the clang scan build warning: drivers/nvme/target/core.c:1124:10: warning: Although the value stored to 'cc_css' is used in the enclosing expression, the value is never actually read from 'cc_css' [deadcode.DeadStores] Signed-off-by: Colin Ian King <colin.i.king@gmail.com> Reviewed-by: Keith Busch <kbusch@kernel.org> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com> Signed-off-by: Christoph Hellwig <hch@lst.de>
1 parent 8832cf9 commit 63bc732

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/nvme/target/core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1123,7 +1123,7 @@ static inline u8 nvmet_cc_iocqes(u32 cc)
11231123

11241124
static inline bool nvmet_css_supported(u8 cc_css)
11251125
{
1126-
switch (cc_css <<= NVME_CC_CSS_SHIFT) {
1126+
switch (cc_css << NVME_CC_CSS_SHIFT) {
11271127
case NVME_CC_CSS_NVM:
11281128
case NVME_CC_CSS_CSI:
11291129
return true;

0 commit comments

Comments
 (0)