Skip to contentSkip to conversation

s3cmci: add better support for no card detect or write protect available

PATCH New [email protected] 1 participant 1 message Oct 1, 2009

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 28/42 s3cmci: add better support for no card detect or write protect available

From: Ben Dooks <[email protected]>

Add better support for omitting either the card detect or the write protect GPIOs if the board does not support it. Add the fields no_wprotect and no_detect to the platform data which when set indicate the absence of the respective GPIOs.

Note, this also fixes a minor bug where it tries to free IRQ0 if there is no detect gpio available.

---

 arch/arm/plat-s3c24xx/include/plat/mci.h |    2 
 drivers/mmc/host/s3cmci.c                |   44 +++++++++++----------
 2 files changed, 26 insertions(+), 20 deletions(-)
arch/arm/plat-s3c24xx/include/plat/mci.h renamed from arch/arm/plat-s3c24xx/include/plat/mci.h~s3cmci-add-better-support-for-no-card-detect-or-write-protect-available +2 -0
diff -puN arch/arm/plat-s3c24xx/include/plat/mci.h~s3cmci-add-better-support-for-no-card-detect-or-write-protect-available arch/arm/plat-s3c24xx/include/plat/mci.h
@@ -2,6 +2,8 @@
 #define _ARCH_MCI_H
 
 struct s3c24xx_mci_pdata {
+	unsigned int	no_wprotect : 1;
+	unsigned int	no_detect : 1;
 	unsigned int	wprotect_invert : 1;
 	unsigned int	detect_invert : 1;   /* set => detect active high. */
 	unsigned int	use_dma : 1;
drivers/mmc/host/s3cmci.c renamed from drivers/mmc/host/s3cmci.c~s3cmci-add-better-support-for-no-card-detect-or-write-protect-available +24 -20

82 lines not on this page · raw message

_