Commit 4c80d057 authored by Christian Borntraeger's avatar Christian Borntraeger

s390/uv: handle destroy page legacy interface

Older firmware can return rc=0x107 rrc=0xd for destroy page if the
page is already non-secure. This should be handled like a success
as already done by newer firmware.
Signed-off-by: default avatarChristian Borntraeger <borntraeger@de.ibm.com>
Fixes: 1a80b54d ("s390/uv: add destroy page call")
Reviewed-by: default avatarDavid Hildenbrand <david@redhat.com>
Acked-by: default avatarCornelia Huck <cohuck@redhat.com>
Reviewed-by: default avatarJanosch Frank <frankja@linux.ibm.com>
parent 6cbf1e96
......@@ -129,8 +129,15 @@ int uv_destroy_page(unsigned long paddr)
.paddr = paddr
};
if (uv_call(0, (u64)&uvcb))
if (uv_call(0, (u64)&uvcb)) {
/*
* Older firmware uses 107/d as an indication of a non secure
* page. Let us emulate the newer variant (no-op).
*/
if (uvcb.header.rc == 0x107 && uvcb.header.rrc == 0xd)
return 0;
return -EINVAL;
}
return 0;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment