From: Andrew Cooper Date: Thu, 18 Feb 2016 14:10:07 +0000 (+0100) Subject: x86: fix unintended fallthrough case from XSA-154 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=c13e5d39e5ffe0fbef84810c11bce63bdf5937fd;p=people%2Fliuw%2Fxen.git x86: fix unintended fallthrough case from XSA-154 ... and annotate the other deliberate one: Coverity objects otherwise. Signed-off-by: Andrew Cooper One of the two instances was actually a bug. Signed-off-by: Jan Beulich --- diff --git a/xen/arch/x86/mm.c b/xen/arch/x86/mm.c index ee0ddff9c6..ea3f9f2353 100644 --- a/xen/arch/x86/mm.c +++ b/xen/arch/x86/mm.c @@ -925,9 +925,11 @@ get_page_from_l1e( case 0: break; case 1: - if ( is_hardware_domain(l1e_owner) ) + if ( !is_hardware_domain(l1e_owner) ) + break; + /* fallthrough */ case -1: - return 0; + return 0; default: ASSERT_UNREACHABLE(); }