生命不止,奋斗不息。
分类: 嵌入式
2013-07-01 23:49:45
/*在Devs.c (arch\arm\plat-s3c24xx)
中添加*/
#include
#include
/*SDI */
static struct resource s3c_sdi_resource[] = {
[0] = {
.start = S3C24XX_PA_SDI,
.end = S3C24XX_PA_SDI + S3C24XX_SZ_SDI - 1,
.flags = IORESOURCE_MEM,
},
[1] = {
.start = IRQ_SDI,
.end = IRQ_SDI,
.flags = IORESOURCE_IRQ,
}
};
struct platform_device s3c_device_sdi = {
.name = "s3c2410-sdi",
.id = -1,
.num_resources = ARRAY_SIZE(s3c_sdi_resource),
.resource = s3c_sdi_resource,
};
EXPORT_SYMBOL(s3c_device_sdi);
/*在Mach-smdk2440.c (arch\arm\mach-s3c2440)
中*/
static struct platform_device *s3c2440_devices[] __initdata = {
/*添加*/
&s3c_device_sdi,
};
s3c_device_sdi.dev.platform_data = &s3c2440_mmc_cfg;
之后会出现mmc0: error -110 whilst initialising SD card的错误
解决办法
S3cmci.c (drivers\mmc\host)
添加
#include
在 s3cmci_disable_irq(host, true);后
添加udelay(50);