Received: from eggs.gnu.org ([2001:4830:134:3::10]:37826) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ehLfS-0000tv-Iu for qemu-devel@nongnu.org; Thu, 01 Feb 2018 15:42:16 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ehLeM-0003fK-2j for qemu-devel@nongnu.org; Thu, 01 Feb 2018 15:41:08 -0500 Received: from 1.mo1.mail-out.ovh.net ([178.32.127.22]:38493) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1ehKq3-0002ed-KJ for qemu-devel@nongnu.org; Thu, 01 Feb 2018 14:48:03 -0500 Received: from player691.ha.ovh.net (gw6.ovh.net [213.251.189.206]) by mo1.mail-out.ovh.net (Postfix) with ESMTP id EAD9FD41ED for ; Thu, 1 Feb 2018 20:47:53 +0100 (CET) From: Greg Kurz Date: Thu, 01 Feb 2018 20:47:41 +0100 Message-ID: <151751446151.11348.15065690714406381610.stgit@bahia.lan> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] [PATCH] spapr: add missing break in h_get_cpu_characteristics() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, David Gibson , Suraj Jitindar Singh , Alexey Kardashevskiy Detected by Coverity (CID 1385702). This fixes the recently added hypercall to let guests properly apply Spectre and Meltdown workarounds. Fixes: c59704b25473 "target/ppc/spapr: Add H-Call H_GET_CPU_CHARACTERISTICS" Signed-off-by: Greg Kurz --- hw/ppc/spapr_hcall.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/ppc/spapr_hcall.c b/hw/ppc/spapr_hcall.c index 4d0e6eb0cf1d..596f58378a40 100644 --- a/hw/ppc/spapr_hcall.c +++ b/hw/ppc/spapr_hcall.c @@ -1697,6 +1697,7 @@ static target_ulong h_get_cpu_characteristics(PowerPCCPU *cpu, switch (safe_indirect_branch) { case SPAPR_CAP_FIXED: characteristics |= H_CPU_CHAR_BCCTRL_SERIALISED; + break; default: /* broken */ assert(safe_indirect_branch == SPAPR_CAP_BROKEN); break;