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

Skip to content
Commit 083dd716 authored by Jiacheng Zheng's avatar Jiacheng Zheng
Browse files

mm/memblock.c: fix bug in early_dyn_memhotplug



memblock.memory.cnt will decrease if we remove all memory
blocks in a region. We will lose the next region in this
condition. The solution is we save memblock.memory.cnt
before we scan through a region and compare the new
counter with the old one after that, we decrease the idx
if we find counter changes. This way, we are always using
the correct idx before we enter next loop.

Change-Id: Id6bf83497f1048cf614e50e23484f2dea7ffcd07
Signed-off-by: default avatarJiacheng Zheng <jiaczhen@codeaurora.org>
parent 4687d601
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment