From 760eb697b475c0e58e3dfcf45ca4d9ec13bcbb8e Mon Sep 17 00:00:00 2001 From: Ian Lepore Date: Fri, 1 Nov 2013 19:29:59 +0000 Subject: [PATCH] The ability to do 8-bit implies 4-bit capability too. Rearrange the cases and add a fallthrough comment to make that happen. --- sys/arm/ti/ti_sdhci.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/sys/arm/ti/ti_sdhci.c b/sys/arm/ti/ti_sdhci.c index 736a9f23010f..6ea6110d2c0a 100644 --- a/sys/arm/ti/ti_sdhci.c +++ b/sys/arm/ti/ti_sdhci.c @@ -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; } }