diff --git a/drivers/nvmem/core.c b/drivers/nvmem/core.c index 6d193f3ee18b..c26785829245 100644 --- a/drivers/nvmem/core.c +++ b/drivers/nvmem/core.c @@ -900,8 +900,7 @@ static void nvmem_shift_read_buffer_in_place(struct nvmem_cell *cell, void *buf) *p-- = 0; /* clear msb bits if any leftover in the last byte */ - if (cell->nbits%BITS_PER_BYTE) - *p &= GENMASK((cell->nbits%BITS_PER_BYTE) - 1, 0); + *p &= GENMASK((cell->nbits%BITS_PER_BYTE) - 1, 0); } static int __nvmem_cell_read(struct nvmem_device *nvmem,