s390/protvirt: support ultravisor without secure storage limit
Avoid potential crash due to lack of secure storage limit. Check that max_sec_stor_addr is not 0 before adjusting vmalloc position. Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
This commit is contained in:
parent
1d6671ae46
commit
c2314cb2dd
@ -90,7 +90,8 @@ fail:
|
||||
|
||||
void adjust_to_uv_max(unsigned long *vmax)
|
||||
{
|
||||
*vmax = min_t(unsigned long, *vmax, uv_info.max_sec_stor_addr);
|
||||
if (uv_info.max_sec_stor_addr)
|
||||
*vmax = min_t(unsigned long, *vmax, uv_info.max_sec_stor_addr);
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
x
Reference in New Issue
Block a user