Not a security bug, because in fact this is never called with a NULL
argument.
Coverity CID
1055955
Signed-off-by: Tim Deegan <tim@xen.org>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
* We know we don't have any extra mappings to these pages */
{
struct page_info *pg;
- struct domain *d = p2m->domain;
+ struct domain *d;
unsigned long gfn;
p2m_type_t t;
mfn_t mfn;
if (p2m == NULL)
return;
+ d = p2m->domain;
+
p2m_lock(p2m);
/* Try to unshare any remaining shared p2m entries. Safeguard