Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2c61d389 authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "nvmem: core: Fix msb clearing bits"

parents 464333cc f54b2984
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -899,6 +899,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);
}