xen/domain: Call lock_profile_deregister_struct() from common code
authorAndrew Cooper <andrew.cooper3@citrix.com>
Mon, 3 Sep 2018 11:10:48 +0000 (12:10 +0100)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Tue, 4 Sep 2018 12:25:44 +0000 (13:25 +0100)
commit10e042c43ecdc0d25c6fbcf5c4889dda5d226591
treeb1d339d0f2d0a13cb2a1ec4746f2cf1fa2f134af
parent9247403d271bcb0071e87fd1fd6aee662aacfdde
xen/domain: Call lock_profile_deregister_struct() from common code

lock_profile_register_struct() is called from common code, but the matching
deregister was previously only called from x86 code.

The practical upshot of this when using CONFIG_LOCK_PROFILE, destroyed domains
on ARM (and in particular, the freed page behind struct domain) remain on the
lockprofile linked list, which will become corrupt when the page is reused.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Wei Liu <wei.liu2@citrix.com>
xen/arch/x86/domain.c
xen/common/domain.c