From patchwork Mon Feb 8 17:03:19 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Bonzini X-Patchwork-Id: 61420 Delivered-To: patch@linaro.org Received: by 10.112.43.199 with SMTP id y7csp1559675lbl; Mon, 8 Feb 2016 09:13:28 -0800 (PST) X-Received: by 10.140.220.78 with SMTP id q75mr37492830qhb.77.1454951608006; Mon, 08 Feb 2016 09:13:28 -0800 (PST) Return-Path: Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id g51si22526072qge.96.2016.02.08.09.13.27 for (version=TLS1 cipher=AES128-SHA bits=128/128); Mon, 08 Feb 2016 09:13:27 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Authentication-Results: mx.google.com; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom=qemu-devel-bounces+patch=linaro.org@nongnu.org; dkim=fail header.i=@gmail.com Received: from localhost ([::1]:46928 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aSpNP-00039W-Co for patch@linaro.org; Mon, 08 Feb 2016 12:13:27 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43751) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aSpEJ-00043N-CS for qemu-devel@nongnu.org; Mon, 08 Feb 2016 12:04:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aSpEG-0006vt-3a for qemu-devel@nongnu.org; Mon, 08 Feb 2016 12:04:03 -0500 Received: from mail-wm0-x234.google.com ([2a00:1450:400c:c09::234]:37640) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aSpEF-0006vp-T6 for qemu-devel@nongnu.org; Mon, 08 Feb 2016 12:04:00 -0500 Received: by mail-wm0-x234.google.com with SMTP id g62so125524579wme.0 for ; Mon, 08 Feb 2016 09:03:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=QOfav0kEvfURcNjSRdeP7/Fj4+gmQ+JbRO5O+9frlSE=; b=QXlpQRhnyLAnNghtLdwqsnJfdZkEMCx2LRDSdUVs2cGobYLdhYBGXebRHhOOxjmvxq 7n/bbQaG/O1aAxfh+ztHuiRlxwbYniGZR9bHA47L4fHYnh26/yhudwxKAmm+z0Lrg4Y9 PqeAak0ipkNKzYhUUpMmMSofIYpEKzkDAoI4oyyTNAYMkELJNHTDJniagoUPeoEBm5Gv B3CtQZ4m6Si68cW+wJOlRb7i42++G3jGe6xTH3Ld9J7XYEdyh/m2Oq2VyUUlJfJcaZYj haCXGYcbVx/rEbaaByMsrCBRE5ySG6cdnTQE+fHsX7NE0Y0sLX8jVNxu5ceOYRd9FmB7 F7fg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=QOfav0kEvfURcNjSRdeP7/Fj4+gmQ+JbRO5O+9frlSE=; b=NwrQUnB/SbUPDhUw0OnpGpMgdIvC8AKmnesBr8UllxMZw/nfo6WyYznsGjs2kzJ4Ck I7OeIyaOjNzYksEn2hYTxxHMt1Dd3IImqr7N3lQR5ah0oJhXsZ2FoCz1U+JKXrqM653X x188VJJpm5z96nezJAPtbAP7C8BSiDMDlBaJp7IDKLbTp7rlg7lZRvrBRM5+Thk5zbZ5 lNugj5ohb7GMatNTKHqjsejN8GToiq1K03D1UGbp+CM+HOincgCUXIzxitYqG3ie5eku 2LCYpfb2Jrz6DPV+ByD8XSdPjP+hKMmf0IhK+9nsolellC7vVvdJJX1n++nPdhRL2pWM 3lAQ== X-Gm-Message-State: AG10YOSEBk3Mi3YLKkcVVKeTC4Y+zifVwhKecmp5H3A/LM1P58Cyfd4ASgHjorIRKK1CQw== X-Received: by 10.28.111.135 with SMTP id c7mr28774642wmi.46.1454951038956; Mon, 08 Feb 2016 09:03:58 -0800 (PST) Received: from 640k.lan (94-39-141-130.adsl-ull.clienti.tiscali.it. [94.39.141.130]) by smtp.gmail.com with ESMTPSA id b1sm30651442wjy.0.2016.02.08.09.03.58 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 08 Feb 2016 09:03:58 -0800 (PST) From: Paolo Bonzini To: qemu-devel@nongnu.org Date: Mon, 8 Feb 2016 18:03:19 +0100 Message-Id: <1454950999-64128-29-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1454950999-64128-1-git-send-email-pbonzini@redhat.com> References: <1454950999-64128-1-git-send-email-pbonzini@redhat.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:400c:c09::234 Cc: Peter Maydell , Xiao Guangrong , Corey Minyard , "Michael S. Tsirkin" , Stefan Hajnoczi , Shannon Zhao Subject: [Qemu-devel] [PULL 28/28] ipmi_bmc_sim: Add break to correct watchdog NMI check X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org From: Corey Minyard It was falling through when it should have been a break. Found by Coverity. The logic could be simplified a bit with a fallthrough, probably the original thought, but that would be less clear, I think. Cc: Paolo Bonzini Cc: Michael S. Tsirkin Cc: Peter Maydell Cc: Shannon Zhao Cc: Xiao Guangrong Cc: Stefan Hajnoczi Signed-off-by: Corey Minyard Message-Id: <1452519152-6500-3-git-send-email-minyard@acm.org> Signed-off-by: Paolo Bonzini --- hw/ipmi/ipmi_bmc_sim.c | 2 ++ 1 file changed, 2 insertions(+) -- 1.8.3.1 diff --git a/hw/ipmi/ipmi_bmc_sim.c b/hw/ipmi/ipmi_bmc_sim.c index b3796af..f8b2176 100644 --- a/hw/ipmi/ipmi_bmc_sim.c +++ b/hw/ipmi/ipmi_bmc_sim.c @@ -1135,6 +1135,8 @@ static void set_watchdog_timer(IPMIBmcSim *ibs, rsp[2] = IPMI_CC_INVALID_DATA_FIELD; return; } + break; + default: /* We don't support PRE_SMI */ rsp[2] = IPMI_CC_INVALID_DATA_FIELD;