x86/shadow: Use ERR_PTR infrastructure for sh_emulate_map_dest()
authorAndrew Cooper <andrew.cooper3@citrix.com>
Fri, 8 Sep 2017 16:05:33 +0000 (19:05 +0300)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Tue, 12 Sep 2017 10:29:55 +0000 (11:29 +0100)
commit19cee44abfdf162a25d86f999d9a50bcfdf468bc
treefa6ab455fccb47c391175ad66580204a02374552
parent41c48004d1d8bcf3aa8151c252575dc1992a42e3
x86/shadow: Use ERR_PTR infrastructure for sh_emulate_map_dest()

sh_emulate_map_dest() predates the introduction of the generic ERR_PTR()
infrastructure, but take the opportunity to avoid opencoding it.

The chosen error constants require need to be negative to work with IS_ERR(),
but no other changes.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Tim Deegan <tim@xen.org>
Reviewed-by: Wei Liu <wei.liu2@citrix.com>
xen/arch/x86/mm/shadow/multi.c
xen/arch/x86/mm/shadow/private.h