From 7104e2d5a85b4b786d6a63568beffe1e185547bb Mon Sep 17 00:00:00 2001 From: Pierre Ossman Date: Wed, 4 Oct 2006 02:15:41 -0700 Subject: [PATCH] mmc: use own work queue The MMC layer uses the standard work queue for doing card detection. As this queue is shared with other crucial subsystems, the effects of a long (and perhaps buggy) detection can cause the system to be unusable. E.g. the keyboard stops working while the detection routine is running. The solution is to add a specific mmc work queue to run the detection code in. This is similar to how other subsystems handle detection (a full kernel thread is the most common theme). Signed-off-by: Pierre Ossman Cc: Russell King Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/mmc/mmc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'drivers/mmc/mmc.c') diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c index 5b9caa7978d..ee8863c123e 100644 --- a/drivers/mmc/mmc.c +++ b/drivers/mmc/mmc.c @@ -1166,9 +1166,9 @@ static void mmc_setup(struct mmc_host *host) void mmc_detect_change(struct mmc_host *host, unsigned long delay) { if (delay) - schedule_delayed_work(&host->detect, delay); + mmc_schedule_delayed_work(&host->detect, delay); else - schedule_work(&host->detect); + mmc_schedule_work(&host->detect); } EXPORT_SYMBOL(mmc_detect_change); @@ -1311,7 +1311,7 @@ EXPORT_SYMBOL(mmc_remove_host); */ void mmc_free_host(struct mmc_host *host) { - flush_scheduled_work(); + mmc_flush_scheduled_work(); mmc_free_host_sysfs(host); } -- cgit v1.2.3