Commit 40fcd5b9 authored by Hyuk Lee's avatar Hyuk Lee Committed by Kukjin Kim

ARM: SAMSUNG: Modified to change of bus width and host caps

This patch adds to change bus width and host capability of HSMMC,
when HSMMC is only configured with another value of bus width
and host capability from default one.
Signed-off-by: default avatarHyuk Lee <hyuk1.lee@samsung.com>
Signed-off-by: default avatarJeongbae Seo <jeongbae.seo@samsung.com>
Signed-off-by: default avatarKukjin Kim <kgene.kim@samsung.com>
parent 2b11148a
...@@ -59,17 +59,18 @@ void s3c_sdhci0_set_platdata(struct s3c_sdhci_platdata *pd) ...@@ -59,17 +59,18 @@ void s3c_sdhci0_set_platdata(struct s3c_sdhci_platdata *pd)
{ {
struct s3c_sdhci_platdata *set = &s3c_hsmmc0_def_platdata; struct s3c_sdhci_platdata *set = &s3c_hsmmc0_def_platdata;
set->max_width = pd->max_width;
set->cd_type = pd->cd_type; set->cd_type = pd->cd_type;
set->ext_cd_init = pd->ext_cd_init; set->ext_cd_init = pd->ext_cd_init;
set->ext_cd_cleanup = pd->ext_cd_cleanup; set->ext_cd_cleanup = pd->ext_cd_cleanup;
set->ext_cd_gpio = pd->ext_cd_gpio; set->ext_cd_gpio = pd->ext_cd_gpio;
set->ext_cd_gpio_invert = pd->ext_cd_gpio_invert; set->ext_cd_gpio_invert = pd->ext_cd_gpio_invert;
if (pd->max_width)
set->max_width = pd->max_width;
if (pd->cfg_gpio) if (pd->cfg_gpio)
set->cfg_gpio = pd->cfg_gpio; set->cfg_gpio = pd->cfg_gpio;
if (pd->cfg_card) if (pd->cfg_card)
set->cfg_card = pd->cfg_card; set->cfg_card = pd->cfg_card;
if (pd->host_caps) if (pd->host_caps)
set->host_caps = pd->host_caps; set->host_caps |= pd->host_caps;
} }
...@@ -59,17 +59,18 @@ void s3c_sdhci1_set_platdata(struct s3c_sdhci_platdata *pd) ...@@ -59,17 +59,18 @@ void s3c_sdhci1_set_platdata(struct s3c_sdhci_platdata *pd)
{ {
struct s3c_sdhci_platdata *set = &s3c_hsmmc1_def_platdata; struct s3c_sdhci_platdata *set = &s3c_hsmmc1_def_platdata;
set->max_width = pd->max_width;
set->cd_type = pd->cd_type; set->cd_type = pd->cd_type;
set->ext_cd_init = pd->ext_cd_init; set->ext_cd_init = pd->ext_cd_init;
set->ext_cd_cleanup = pd->ext_cd_cleanup; set->ext_cd_cleanup = pd->ext_cd_cleanup;
set->ext_cd_gpio = pd->ext_cd_gpio; set->ext_cd_gpio = pd->ext_cd_gpio;
set->ext_cd_gpio_invert = pd->ext_cd_gpio_invert; set->ext_cd_gpio_invert = pd->ext_cd_gpio_invert;
if (pd->max_width)
set->max_width = pd->max_width;
if (pd->cfg_gpio) if (pd->cfg_gpio)
set->cfg_gpio = pd->cfg_gpio; set->cfg_gpio = pd->cfg_gpio;
if (pd->cfg_card) if (pd->cfg_card)
set->cfg_card = pd->cfg_card; set->cfg_card = pd->cfg_card;
if (pd->host_caps) if (pd->host_caps)
set->host_caps = pd->host_caps; set->host_caps |= pd->host_caps;
} }
...@@ -60,17 +60,18 @@ void s3c_sdhci2_set_platdata(struct s3c_sdhci_platdata *pd) ...@@ -60,17 +60,18 @@ void s3c_sdhci2_set_platdata(struct s3c_sdhci_platdata *pd)
{ {
struct s3c_sdhci_platdata *set = &s3c_hsmmc2_def_platdata; struct s3c_sdhci_platdata *set = &s3c_hsmmc2_def_platdata;
set->max_width = pd->max_width;
set->cd_type = pd->cd_type; set->cd_type = pd->cd_type;
set->ext_cd_init = pd->ext_cd_init; set->ext_cd_init = pd->ext_cd_init;
set->ext_cd_cleanup = pd->ext_cd_cleanup; set->ext_cd_cleanup = pd->ext_cd_cleanup;
set->ext_cd_gpio = pd->ext_cd_gpio; set->ext_cd_gpio = pd->ext_cd_gpio;
set->ext_cd_gpio_invert = pd->ext_cd_gpio_invert; set->ext_cd_gpio_invert = pd->ext_cd_gpio_invert;
if (pd->max_width)
set->max_width = pd->max_width;
if (pd->cfg_gpio) if (pd->cfg_gpio)
set->cfg_gpio = pd->cfg_gpio; set->cfg_gpio = pd->cfg_gpio;
if (pd->cfg_card) if (pd->cfg_card)
set->cfg_card = pd->cfg_card; set->cfg_card = pd->cfg_card;
if (pd->host_caps) if (pd->host_caps)
set->host_caps = pd->host_caps; set->host_caps |= pd->host_caps;
} }
...@@ -63,15 +63,18 @@ void s3c_sdhci3_set_platdata(struct s3c_sdhci_platdata *pd) ...@@ -63,15 +63,18 @@ void s3c_sdhci3_set_platdata(struct s3c_sdhci_platdata *pd)
{ {
struct s3c_sdhci_platdata *set = &s3c_hsmmc3_def_platdata; struct s3c_sdhci_platdata *set = &s3c_hsmmc3_def_platdata;
set->max_width = pd->max_width;
set->cd_type = pd->cd_type; set->cd_type = pd->cd_type;
set->ext_cd_init = pd->ext_cd_init; set->ext_cd_init = pd->ext_cd_init;
set->ext_cd_cleanup = pd->ext_cd_cleanup; set->ext_cd_cleanup = pd->ext_cd_cleanup;
set->ext_cd_gpio = pd->ext_cd_gpio; set->ext_cd_gpio = pd->ext_cd_gpio;
set->ext_cd_gpio_invert = pd->ext_cd_gpio_invert; set->ext_cd_gpio_invert = pd->ext_cd_gpio_invert;
if (pd->max_width)
set->max_width = pd->max_width;
if (pd->cfg_gpio) if (pd->cfg_gpio)
set->cfg_gpio = pd->cfg_gpio; set->cfg_gpio = pd->cfg_gpio;
if (pd->cfg_card) if (pd->cfg_card)
set->cfg_card = pd->cfg_card; set->cfg_card = pd->cfg_card;
if (pd->host_caps)
set->host_caps |= pd->host_caps;
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment