summaryrefslogtreecommitdiff
path: root/drivers/mmc/core/sdio_bus.c
diff options
context:
space:
mode:
authorPhilippe Langlais <philippe.langlais@stericsson.com>2012-04-06 11:51:14 +0200
committerPhilippe Langlais <philippe.langlais@stericsson.com>2012-04-06 11:51:14 +0200
commit3b5766214a67f24913d4e046fc30eed7ec0ddc35 (patch)
tree65388dec2a13f78ede772136281607ae6c8ca9b7 /drivers/mmc/core/sdio_bus.c
parent70526554173aa46c8b13a59992b6fbc555fd4ee0 (diff)
parent78be8d8ebeafc24368e897c7fc78c301c1caf3c8 (diff)
Merge remote-tracking branch 'jstultz/linaro-android-3.3' into stable-android-ux500-3.3-1
Conflicts: arch/arm/common/Makefile drivers/gpu/Makefile drivers/misc/Kconfig drivers/misc/Makefile drivers/mmc/card/block.c drivers/mmc/core/core.c drivers/video/Kconfig include/net/bluetooth/hci.h include/net/bluetooth/hci_core.h include/net/bluetooth/sco.h kernel/printk.c net/bluetooth/hci_conn.c net/bluetooth/hci_event.c net/bluetooth/l2cap_core.c net/bluetooth/mgmt.c net/bluetooth/sco.c
Diffstat (limited to 'drivers/mmc/core/sdio_bus.c')
-rw-r--r--drivers/mmc/core/sdio_bus.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/drivers/mmc/core/sdio_bus.c b/drivers/mmc/core/sdio_bus.c
index 40989e6bb53..7a0b801714b 100644
--- a/drivers/mmc/core/sdio_bus.c
+++ b/drivers/mmc/core/sdio_bus.c
@@ -24,6 +24,10 @@
#include "sdio_cis.h"
#include "sdio_bus.h"
+#ifdef CONFIG_MMC_EMBEDDED_SDIO
+#include <linux/mmc/host.h>
+#endif
+
/* show configuration fields */
#define sdio_config_attr(field, format_string) \
static ssize_t \
@@ -257,7 +261,14 @@ static void sdio_release_func(struct device *dev)
{
struct sdio_func *func = dev_to_sdio_func(dev);
- sdio_free_func_cis(func);
+#ifdef CONFIG_MMC_EMBEDDED_SDIO
+ /*
+ * If this device is embedded then we never allocated
+ * cis tables for this func
+ */
+ if (!func->card->host->embedded_sdio_data.funcs)
+#endif
+ sdio_free_func_cis(func);
if (func->info)
kfree(func->info);