From 54c57795e848100a2502b7a39b12b784292f4576 Mon Sep 17 00:00:00 2001 From: Vasily Gorbik Date: Wed, 11 Apr 2018 19:15:24 +0200 Subject: s390/mem_detect: replace tprot loop with binary search In a situation when other memory detection methods are not available (no SCLP and no z/VM diag260), continuous online memory is assumed. Replacing tprot loop with faster binary search, as only online memory end has to be found. Reviewed-by: Heiko Carstens Reviewed-by: Martin Schwidefsky Signed-off-by: Vasily Gorbik Signed-off-by: Martin Schwidefsky --- drivers/s390/char/sclp_early_core.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'drivers/s390/char') diff --git a/drivers/s390/char/sclp_early_core.c b/drivers/s390/char/sclp_early_core.c index 0df08dcb9fe8..acfe09313852 100644 --- a/drivers/s390/char/sclp_early_core.c +++ b/drivers/s390/char/sclp_early_core.c @@ -272,7 +272,7 @@ int __init sclp_early_get_info(struct read_info_sccb *info) return 0; } -int __init sclp_early_get_meminfo(unsigned long *mem, unsigned long *rzm) +int __init sclp_early_get_memsize(unsigned long *mem) { unsigned long rnmax; unsigned long rnsize; @@ -285,7 +285,6 @@ int __init sclp_early_get_meminfo(unsigned long *mem, unsigned long *rzm) rnsize = sccb->rnsize ? sccb->rnsize : sccb->rnsize2; rnsize <<= 20; *mem = rnsize * rnmax; - *rzm = rnsize; return 0; } -- cgit v1.2.3