From owner-svn-soc-all@FreeBSD.ORG Sun Sep 15 09:49:12 2013 Return-Path: Delivered-To: svn-soc-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id E6F611B1 for ; Sun, 15 Sep 2013 09:49:12 +0000 (UTC) (envelope-from zcore@FreeBSD.org) Received: from socsvn.freebsd.org (socsvn.freebsd.org [IPv6:2001:1900:2254:206a::50:2]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id D4A8F2861 for ; Sun, 15 Sep 2013 09:49:12 +0000 (UTC) Received: from socsvn.freebsd.org ([127.0.1.124]) by socsvn.freebsd.org (8.14.7/8.14.7) with ESMTP id r8F9nC3U015262 for ; Sun, 15 Sep 2013 09:49:12 GMT (envelope-from zcore@FreeBSD.org) Received: (from www@localhost) by socsvn.freebsd.org (8.14.7/8.14.6/Submit) id r8F9nClW015257 for svn-soc-all@FreeBSD.org; Sun, 15 Sep 2013 09:49:12 GMT (envelope-from zcore@FreeBSD.org) Date: Sun, 15 Sep 2013 09:49:12 GMT Message-Id: <201309150949.r8F9nClW015257@socsvn.freebsd.org> X-Authentication-Warning: socsvn.freebsd.org: www set sender to zcore@FreeBSD.org using -f From: zcore@FreeBSD.org To: svn-soc-all@FreeBSD.org Subject: socsvn commit: r257360 - soc2013/zcore/head/usr.sbin/bhyve MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-soc-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the entire Summer of Code repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Sep 2013 09:49:13 -0000 Author: zcore Date: Sun Sep 15 09:49:12 2013 New Revision: 257360 URL: http://svnweb.FreeBSD.org/socsvn/?view=rev&rev=257360 Log: fix used uninitialized Modified: soc2013/zcore/head/usr.sbin/bhyve/pci_ahci.c Modified: soc2013/zcore/head/usr.sbin/bhyve/pci_ahci.c ============================================================================== --- soc2013/zcore/head/usr.sbin/bhyve/pci_ahci.c Sun Sep 15 09:48:50 2013 (r257359) +++ soc2013/zcore/head/usr.sbin/bhyve/pci_ahci.c Sun Sep 15 09:49:12 2013 (r257360) @@ -219,7 +219,7 @@ break; default: WPRINTF(("unsupported fis type %d\n", ft)); - break; + return; } memcpy(p->rfis + offset, fis, len); if (irq) { @@ -1573,8 +1573,10 @@ value = pci_ahci_host_read(sc, offset); else if (offset < AHCI_OFFSET + sc->ports * AHCI_STEP) value = pci_ahci_port_read(sc, offset); - else + else { + value = 0; DPRINTF(("pci_ahci: unknown i/o read offset 0x%"PRIx64"\n", offset)); + } pthread_mutex_unlock(&sc->mtx);