]> xenbits.xensource.com Git - xen.git/commit
x86/p2m-pt: fix (latent) page table mapping leak on do_recalc() error paths
authorJan Beulich <jbeulich@suse.com>
Tue, 26 Nov 2019 13:17:11 +0000 (14:17 +0100)
committerJan Beulich <jbeulich@suse.com>
Tue, 26 Nov 2019 13:17:11 +0000 (14:17 +0100)
commit3f1a53bef84fca5ffb4178638db14c747231851f
treee6f9b17a699e21340f300a988d8c51c7dac439df
parent48599114d3ca24157c25f6684bb9322f6dca12bb
x86/p2m-pt: fix (latent) page table mapping leak on do_recalc() error paths

There are two mappings active in the middle of do_recalc(), and hence
commit 0d0f4d78e5d1 ("p2m: change write_p2m_entry to return an error
code") should have added (or otherwise invoked) unmapping code just
like it did in p2m_next_level(), despite us not expecting any errors
here. Arrange for the existing unmap invocation to take effect in all
cases.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: George Dunlap <george.dunlap@citrix.com>
Release-acked-by: Juergen Gross <jgross@suse.com>
xen/arch/x86/mm/p2m-pt.c