extern void rockchip_mmc_of_probe(struct device_node *np,struct rk_sdmmc_of *mmc_property);
#endif
+#ifdef MMC_QUIRK_INIT_IMPROVE
static struct platform_device *sdmmc_pdev;
static struct dw_mci_drv_data *sdmmc_drv_data;
static struct platform_device *sdio_pdev;
{
dw_mci_pltfm_register(sdio_pdev, sdio_drv_data);
}
+#endif
static int dw_mci_rockchip_probe(struct platform_device *pdev)
match = of_match_node(dw_mci_rockchip_match, pdev->dev.of_node);
drv_data = match->data;
-
+
+#ifdef MMC_QUIRK_INIT_IMPROVE
if(strcmp(pdev->dev.of_node->type,"sdmmc") == 0){
sdmmc_pdev = pdev;
sdmmc_drv_data = drv_data;
sdio_drv_data = drv_data;
INIT_DELAYED_WORK(&drv_data->dw_mci_sdio_delayed_work, dw_mci_sdio_delayed_work);
return schedule_delayed_work(&drv_data->dw_mci_sdio_delayed_work, msecs_to_jiffies(50));
- }else{
+ }else
+#endif
/*eMMC*/
return dw_mci_pltfm_register(pdev, drv_data);
- }
}
static struct platform_driver dw_mci_rockchip_pltfm_driver = {
#ifndef _DW_MMC_H_
#define _DW_MMC_H_
+#include "rk_sdmmc_of.h"
#define DW_MMC_240A 0x240a
struct dw_mci_drv_data {
unsigned long *caps;
unsigned int *hold_reg_flag;
+ #ifdef MMC_QUIRK_INIT_IMPROVE
struct delayed_work dw_mci_sdmmc_delayed_work;
struct delayed_work dw_mci_sdio_delayed_work;
+ #endif
int (*init)(struct dw_mci *host);
int (*setup_clock)(struct dw_mci *host);
void (*prepare_command)(struct dw_mci *host, u32 *cmdr);