From patchwork Tue Apr 1 04:31:09 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Crosthwaite X-Patchwork-Id: 335662 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 0F7C81400AE for ; Tue, 1 Apr 2014 15:32:13 +1100 (EST) Received: from localhost ([::1]:52510 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WUqMr-0005xE-Jd for incoming@patchwork.ozlabs.org; Tue, 01 Apr 2014 00:32:09 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42220) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WUqMW-0005x1-VV for qemu-devel@nongnu.org; Tue, 01 Apr 2014 00:31:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WUqMQ-0003aP-Nc for qemu-devel@nongnu.org; Tue, 01 Apr 2014 00:31:48 -0400 Received: from mail-qa0-f48.google.com ([209.85.216.48]:47945) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WUqMQ-0003aG-KO for qemu-devel@nongnu.org; Tue, 01 Apr 2014 00:31:42 -0400 Received: by mail-qa0-f48.google.com with SMTP id m5so9068547qaj.35 for ; Mon, 31 Mar 2014 21:31:42 -0700 (PDT) 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; bh=VnbnOyV5pGpQfzcvpIKv4V7JkANwLN4BVLMa19B71lw=; b=Q8RCXysU3xb5pHjOsuc5j2NxPyu8ccXjfRCE4yCs7TtGFEZ/LigKq6zHIpEMkxwiG/ mZfeiuMZthPIEPryln+ojpHqlFOJvUcpbtEn/DsOPJB+ElOhvB4ckgxEoa3zSergmh6C 1jQg35uZREdXr7XGvNgruCSEJLf3BaUzbJEzhRcamGl/E0q2ljkNY39doeE730uYM2Wv y6iw87JUXRo1/TUGMJIbtsRoDPw9/pham/MEsDfVBR0YLR+W70LzOGY5l4hDE5YiF9Ch oizV9Tjjlvlfq/jyqQQxah0i8ZDS9vgeNu4clGUBGwOrtfOdrLdpiHZHsiHpCA+M+b5W px+w== X-Gm-Message-State: ALoCoQlL+P1GDwM5jyrNCpWzOLiA8qfn+j/sCslUUUrYXg4CLkkbm8OYDkdbXl5skngLP9e2aal+ X-Received: by 10.140.41.80 with SMTP id y74mr84818qgy.104.1396326702152; Mon, 31 Mar 2014 21:31:42 -0700 (PDT) Received: from localhost ([149.199.62.254]) by mx.google.com with ESMTPSA id p2sm32528096qah.38.2014.03.31.21.31.41 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Mon, 31 Mar 2014 21:31:41 -0700 (PDT) From: Peter Crosthwaite To: qemu-devel@nongnu.org Date: Mon, 31 Mar 2014 21:31:09 -0700 Message-Id: <74147b4c017c904364955cc73107f90e6ac8ba74.1396326389.git.peter.crosthwaite@xilinx.com> X-Mailer: git-send-email 1.9.1.1.gbb9f595 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.85.216.48 Cc: peter.maydell@linaro.org Subject: [Qemu-devel] [PATCH for-2.0 v1 1/1] timer: cadence_ttc: Fix match register write logic 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+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org This switch logic should not fall through. Fix. Signed-off-by: Peter Crosthwaite Reviewed-by: Peter Maydell --- Spotted by Coverity (via PMM) hw/timer/cadence_ttc.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/timer/cadence_ttc.c b/hw/timer/cadence_ttc.c index a279bce..28cb328 100644 --- a/hw/timer/cadence_ttc.c +++ b/hw/timer/cadence_ttc.c @@ -346,11 +346,13 @@ static void cadence_ttc_write(void *opaque, hwaddr offset, case 0x34: case 0x38: s->reg_match[0] = value & 0xffff; + break; case 0x3c: /* match register */ case 0x40: case 0x44: s->reg_match[1] = value & 0xffff; + break; case 0x48: /* match register */ case 0x4c: