From: jekhor@gmail.com (Yauhen Kharuzhy)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 04/10] ARM: S3C2416: Add support of SD/MMC card detect on SMDK2416
Date: Sun, 28 Nov 2010 20:30:22 +0200 [thread overview]
Message-ID: <1290969027-10178-4-git-send-email-jekhor@gmail.com> (raw)
In-Reply-To: <1290969027-10178-1-git-send-email-jekhor@gmail.com>
Enable card detect by GPIO pin on hsmmc1 device (SD0 on SMDK2416
board) and enable card polling on hsmmc0 (SD1).
Signed-off-by: Yauhen Kharuzhy <jekhor@gmail.com>
---
arch/arm/mach-s3c2416/mach-smdk2416.c | 16 ++++++++++++++++
1 files changed, 16 insertions(+), 0 deletions(-)
diff --git a/arch/arm/mach-s3c2416/mach-smdk2416.c b/arch/arm/mach-s3c2416/mach-smdk2416.c
index 7fc3664..ad2497c 100644
--- a/arch/arm/mach-s3c2416/mach-smdk2416.c
+++ b/arch/arm/mach-s3c2416/mach-smdk2416.c
@@ -46,6 +46,7 @@
#include <plat/devs.h>
#include <plat/cpu.h>
#include <plat/nand.h>
+#include <plat/sdhci.h>
#include <plat/regs-fb-v4.h>
#include <plat/fb.h>
@@ -159,6 +160,18 @@ static struct s3c_fb_platdata smdk2416_fb_platdata = {
.vidcon1 = VIDCON1_INV_HSYNC | VIDCON1_INV_VSYNC,
};
+static struct s3c_sdhci_platdata smdk2416_hsmmc0_pdata __initdata = {
+ .max_width = 4,
+ .cd_type = S3C_SDHCI_CD_GPIO,
+ .ext_cd_gpio = S3C2410_GPF(1),
+ .ext_cd_gpio_invert = 1,
+};
+
+static struct s3c_sdhci_platdata smdk2416_hsmmc1_pdata __initdata = {
+ .max_width = 4,
+ .cd_type = S3C_SDHCI_CD_NONE,
+};
+
static struct platform_device *smdk2416_devices[] __initdata = {
&s3c_device_fb,
&s3c_device_wdt,
@@ -180,6 +193,9 @@ static void __init smdk2416_machine_init(void)
s3c_i2c0_set_platdata(NULL);
s3c_fb_set_platdata(&smdk2416_fb_platdata);
+ s3c_sdhci0_set_platdata(&smdk2416_hsmmc0_pdata);
+ s3c_sdhci1_set_platdata(&smdk2416_hsmmc1_pdata);
+
gpio_request(S3C2410_GPB(4), "USBHost Power");
gpio_direction_output(S3C2410_GPB(4), 1);
--
1.7.2.3
next prev parent reply other threads:[~2010-11-28 18:30 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-28 18:30 [PATCH 01/10] SMDK2416: Select MACH_SMDK, S3C_DEV_NAND, S3C_DEV_USB_HOST Yauhen Kharuzhy
2010-11-28 18:30 ` [PATCH 02/10] ARM S3C2416: Add address map and clock definitions for HSMMC0 Yauhen Kharuzhy
2010-11-30 7:21 ` Kukjin Kim
2010-11-30 8:21 ` Yauhen Kharuzhy
2010-12-03 12:46 ` Kukjin Kim
2010-11-28 18:30 ` [PATCH 03/10] ARM: S3C2416: Add platform helpers for setup SDHCI Yauhen Kharuzhy
2010-11-30 7:37 ` Kukjin Kim
2010-11-30 8:34 ` Yauhen Kharuzhy
2010-12-01 9:57 ` [PATCH v2] " Yauhen Kharuzhy
2010-12-02 20:06 ` Yauhen Kharuzhy
2010-12-10 1:35 ` Kukjin Kim
2010-11-28 18:30 ` Yauhen Kharuzhy [this message]
2010-11-28 18:30 ` [PATCH 05/10] ARM S3C2443: Select properly ARM core type Yauhen Kharuzhy
2010-11-29 11:08 ` Kukjin Kim
2010-11-29 11:25 ` Yauhen Kharuzhy
2010-11-30 8:45 ` Ben Dooks
2010-11-28 18:30 ` [PATCH 06/10] ARM S3C24XX: Compile NAND device definition for SMDK boards Yauhen Kharuzhy
2010-11-30 7:45 ` Kukjin Kim
2010-11-30 8:27 ` Yauhen Kharuzhy
2010-12-03 12:37 ` Kukjin Kim
2010-12-03 13:24 ` Yauhen Kharuzhy
2010-11-28 18:30 ` [PATCH 07/10] ARM S3C2443: Implement GPIO pull-up/down configuration methods Yauhen Kharuzhy
2010-11-30 8:10 ` Kukjin Kim
2010-11-28 18:30 ` [PATCH 08/10] ARM SAMSUNG: Don't export __init functions to modules Yauhen Kharuzhy
2010-11-28 18:30 ` [PATCH 09/10] ARM S3C2412: Fix typo in CONFIG_CPU_S3C2412_ONLY definition Yauhen Kharuzhy
2010-11-30 7:38 ` Kukjin Kim
2010-11-30 8:47 ` Ben Dooks
2010-11-29 10:51 ` [PATCH 01/10] SMDK2416: Select MACH_SMDK, S3C_DEV_NAND, S3C_DEV_USB_HOST Kukjin Kim
2010-11-29 11:22 ` Yauhen Kharuzhy
2010-12-03 12:25 ` Kukjin Kim
2010-12-03 12:39 ` Yauhen Kharuzhy
2010-12-03 12:50 ` Kukjin Kim
2010-11-30 8:33 ` Ben Dooks
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1290969027-10178-4-git-send-email-jekhor@gmail.com \
--to=jekhor@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).