From owner-svn-src-all@FreeBSD.ORG Fri Nov 1 19:29:59 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id B55A1520; Fri, 1 Nov 2013 19:29:59 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id A27ED2306; Fri, 1 Nov 2013 19:29:59 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id rA1JTx3C018795; Fri, 1 Nov 2013 19:29:59 GMT (envelope-from ian@svn.freebsd.org) Received: (from ian@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id rA1JTxKv018794; Fri, 1 Nov 2013 19:29:59 GMT (envelope-from ian@svn.freebsd.org) Message-Id: <201311011929.rA1JTxKv018794@svn.freebsd.org> From: Ian Lepore Date: Fri, 1 Nov 2013 19:29:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r257519 - head/sys/arm/ti X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 01 Nov 2013 19:29:59 -0000 Author: ian Date: Fri Nov 1 19:29:59 2013 New Revision: 257519 URL: http://svnweb.freebsd.org/changeset/base/257519 Log: The ability to do 8-bit implies 4-bit capability too. Rearrange the cases and add a fallthrough comment to make that happen. Modified: head/sys/arm/ti/ti_sdhci.c Modified: head/sys/arm/ti/ti_sdhci.c ============================================================================== --- head/sys/arm/ti/ti_sdhci.c Fri Nov 1 19:22:06 2013 (r257518) +++ head/sys/arm/ti/ti_sdhci.c Fri Nov 1 19:29:59 2013 (r257519) @@ -546,16 +546,17 @@ ti_sdhci_attach(device_t dev) sc->slot.host.caps &= ~(MMC_CAP_4_BIT_DATA | MMC_CAP_8_BIT_DATA); switch (prop) { - case 1: - break; + case 8: + sc->slot.host.caps |= MMC_CAP_8_BIT_DATA; + /* FALLTHROUGH */ case 4: sc->slot.host.caps |= MMC_CAP_4_BIT_DATA; break; - case 8: - sc->slot.host.caps |= MMC_CAP_8_BIT_DATA; + case 1: break; default: device_printf(dev, "Bad bus-width value %u\n", prop); + break; } }