mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-05 14:14:54 +00:00
[S390] Fix memory detection.
Yet another patch in the countless series of memory detection fixes: if the last area of the reported storage size is a hole the detection loop will loop forever. Just break chunk detection loop if its end is going to be larger than reported storage size. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
This commit is contained in:
parent
0d2be08893
commit
0b8da654b6
1 changed files with 3 additions and 1 deletions
|
@ -200,11 +200,13 @@ static noinline __init void find_memory_chunks(unsigned long memsize)
|
|||
cc = __tprot(addr);
|
||||
while (cc == old_cc) {
|
||||
addr += CHUNK_INCR;
|
||||
cc = __tprot(addr);
|
||||
if (addr >= memsize)
|
||||
break;
|
||||
#ifndef CONFIG_64BIT
|
||||
if (addr == ADDR2G)
|
||||
break;
|
||||
#endif
|
||||
cc = __tprot(addr);
|
||||
}
|
||||
|
||||
if (old_addr != addr &&
|
||||
|
|
Loading…
Add table
Reference in a new issue