svn commit: r257519 - head/sys/arm/ti

Ian Lepore ian at FreeBSD.org
Fri Nov 1 19:29:59 UTC 2013


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;
 		}
 	}
 


More information about the svn-src-all mailing list