Skip to contentSkip to conversation

MMC - CONFIG_HOTPLUG support

PATCH New Anderson Briglia 1 participant 1 message Dec 16, 2005 MMC, SD and SDIO

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 MMC - CONFIG_HOTPLUG support

Hi all,

This patch improves the CONFIG_HOTPLUG support on the mmc core driver. Kernel version: 2.6.15-rc4-omap1

BR,

--
Anderson Briglia

drivers/mmc/mmc_sysfs.c +13 -0
Index: linux-2.6.15-rc4/drivers/mmc/mmc_sysfs.c
===================================================================
@@ -145,6 +145,8 @@ static int mmc_bus_match(struct device *
 	return !mmc_card_bad(card);
 }
 
+#ifdef CONFIG_HOTPLUG
+
 static int
 mmc_bus_hotplug(struct device *dev, char **envp, int num_envp, char *buf,
 		int buf_size)
@@ -180,6 +182,17 @@ mmc_bus_hotplug(struct device *dev, char
 	return 0;
 }
 
+#else
+
+static int
+mmc_bus_hotplug(struct device *dev, char **envp, int num_envp, char *buf,
+		int buf_size)
+{
+	return -ENODEV;
+}
+
+#endif  /* CONFIG_HOTPLUG */
+
 static int mmc_bus_suspend(struct device *dev, pm_message_t state)
 {
 	struct mmc_driver *drv = to_mmc_driver(dev->driver);