* [PATCH] ARM: mach-imx: mx25_3ds: add write-protect and card-detect for SD
@ 2011-02-26 15:19 Shawn Guo
2011-02-26 15:38 ` Wolfram Sang
0 siblings, 1 reply; 2+ messages in thread
From: Shawn Guo @ 2011-02-26 15:19 UTC (permalink / raw)
To: linux-arm-kernel
Signed-off-by: Shawn Guo <shawn.guo@freescale.com>
---
arch/arm/mach-imx/mach-mx25_3ds.c | 13 ++++++++++++-
1 files changed, 12 insertions(+), 1 deletions(-)
diff --git a/arch/arm/mach-imx/mach-mx25_3ds.c b/arch/arm/mach-imx/mach-mx25_3ds.c
index 66b6cdd..561f07f 100644
--- a/arch/arm/mach-imx/mach-mx25_3ds.c
+++ b/arch/arm/mach-imx/mach-mx25_3ds.c
@@ -41,6 +41,7 @@
#include <mach/common.h>
#include <mach/mx25.h>
#include <mach/iomux-mx25.h>
+#include <mach/esdhc.h>
#include "devices-imx25.h"
@@ -103,6 +104,8 @@ static iomux_v3_cfg_t mx25pdk_pads[] = {
MX25_PAD_SD1_DATA1__SD1_DATA1,
MX25_PAD_SD1_DATA2__SD1_DATA2,
MX25_PAD_SD1_DATA3__SD1_DATA3,
+ MX25_PAD_A14__GPIO_2_0, /* WriteProtect */
+ MX25_PAD_A15__GPIO_2_1, /* CardDetect */
};
static const struct fec_platform_data mx25_fec_pdata __initconst = {
@@ -200,6 +203,14 @@ static const struct fsl_usb2_platform_data otg_device_pdata __initconst = {
.phy_mode = FSL_USB2_PHY_UTMI,
};
+#define SD1_GPIO_WP IMX_GPIO_NR(2, 0)
+#define SD1_GPIO_CD IMX_GPIO_NR(2, 1)
+
+static const struct esdhc_platform_data mx25pdk_esdhc_pdata __initconst = {
+ .wp_gpio = SD1_GPIO_WP,
+ .cd_gpio = SD1_GPIO_CD,
+};
+
static void __init mx25pdk_init(void)
{
mxc_iomux_v3_setup_multiple_pads(mx25pdk_pads,
@@ -217,7 +228,7 @@ static void __init mx25pdk_init(void)
imx25_add_fec(&mx25_fec_pdata);
imx25_add_imx_keypad(&mx25pdk_keymap_data);
- imx25_add_sdhci_esdhc_imx(0, NULL);
+ imx25_add_sdhci_esdhc_imx(0, &mx25pdk_esdhc_pdata);
}
static void __init mx25pdk_timer_init(void)
--
1.7.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [PATCH] ARM: mach-imx: mx25_3ds: add write-protect and card-detect for SD
2011-02-26 15:19 [PATCH] ARM: mach-imx: mx25_3ds: add write-protect and card-detect for SD Shawn Guo
@ 2011-02-26 15:38 ` Wolfram Sang
0 siblings, 0 replies; 2+ messages in thread
From: Wolfram Sang @ 2011-02-26 15:38 UTC (permalink / raw)
To: linux-arm-kernel
On Sat, Feb 26, 2011 at 11:19:04PM +0800, Shawn Guo wrote:
> Signed-off-by: Shawn Guo <shawn.guo@freescale.com>
Acked-by: Wolfram Sang <w.sang@pengutronix.de>
--
Pengutronix e.K. | Wolfram Sang |
Industrial Linux Solutions | http://www.pengutronix.de/ |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20110226/37c6053b/attachment.sig>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-02-26 15:38 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-02-26 15:19 [PATCH] ARM: mach-imx: mx25_3ds: add write-protect and card-detect for SD Shawn Guo
2011-02-26 15:38 ` Wolfram Sang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).