summaryrefslogtreecommitdiffstats
path: root/drivers/mmc/core/Kconfig
diff options
context:
space:
mode:
authorBen Hutchings <ben@decadent.org.uk>2009-12-14 18:01:29 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2009-12-15 08:53:35 -0800
commitbd68e0838fe85794b06892054772fa013a8d1986 (patch)
treeadb0a3a1aad94f756b7d3d2f8e077877a0b982d0 /drivers/mmc/core/Kconfig
parentc78402e95dd8238ee2b0e6e62b9a0c8b2bb9bba9 (diff)
downloadlinux-stable-bd68e0838fe85794b06892054772fa013a8d1986.tar.gz
linux-stable-bd68e0838fe85794b06892054772fa013a8d1986.tar.bz2
linux-stable-bd68e0838fe85794b06892054772fa013a8d1986.zip
mmc: add module parameter to set whether cards are assumed removable
Some people run general-purpose distribution kernels on netbooks with a card that is physically non-removable or logically non-removable (e.g. used for /home) and cannot be cleanly unmounted during suspend. Add a module parameter to set whether cards are assumed removable or non-removable, with the default set by CONFIG_MMC_UNSAFE_RESUME. In general, it is not possible to tell whether a card present in an MMC slot after resume is the same that was there before suspend. So there are two possible behaviours, each of which will cause data loss in some cases: CONFIG_MMC_UNSAFE_RESUME=n (default): Cards are assumed to be removed during suspend. Any filesystem on them must be unmounted before suspend; otherwise, buffered writes will be lost. CONFIG_MMC_UNSAFE_RESUME=y: Cards are assumed to remain present during suspend. They must not be swapped during suspend; otherwise, buffered writes will be flushed to the wrong card. Currently the choice is made at compile time and this allows that to be overridden at module load time. Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Cc: Wouter van Heyst <larstiq@larstiq.dyndns.org> Cc: <linux-mmc@vger.kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/mmc/core/Kconfig')
-rw-r--r--drivers/mmc/core/Kconfig4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/mmc/core/Kconfig b/drivers/mmc/core/Kconfig
index ab37a6d9d32a..bb22ffd76ef8 100644
--- a/drivers/mmc/core/Kconfig
+++ b/drivers/mmc/core/Kconfig
@@ -3,7 +3,7 @@
#
config MMC_UNSAFE_RESUME
- bool "Allow unsafe resume (DANGEROUS)"
+ bool "Assume MMC/SD cards are non-removable (DANGEROUS)"
help
If you say Y here, the MMC layer will assume that all cards
stayed in their respective slots during the suspend. The
@@ -14,3 +14,5 @@ config MMC_UNSAFE_RESUME
This option is usually just for embedded systems which use
a MMC/SD card for rootfs. Most people should say N here.
+ This option sets a default which can be overridden by the
+ module parameter "removable=0" or "removable=1".