Skip to contentSkip to conversation

mmc: sdhci-s3c: support the broken voltage.

PATCH In review Jaehoon Chung 2 participants 3 messages Jan 31, 2012

Subsystems (3)
lore
Share & tools
lore

Jaehoon Chung

author maintainer
#0 lore raw

PATCH 2/2 mmc: sdhci-s3c: support the broken voltage.

Samsung-SoC need to add the MMC_CAP2_BROKEN_VOLTAGE.

---
 drivers/mmc/host/sdhci-s3c.c |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)
drivers/mmc/host/sdhci-s3c.c +3 -4
index d065e37..e7e2b6b 100644
@@ -521,9 +521,12 @@ static int __devinit sdhci_s3c_probe(struct platform_device *pdev)
 	if (pdata->cd_type == S3C_SDHCI_CD_PERMANENT)
 		host->mmc->caps = MMC_CAP_NONREMOVABLE;
 
+	/* It supports additional host capabilities if needed */
 	if (pdata->host_caps)
 		host->mmc->caps |= pdata->host_caps;
 
+	host->mmc->caps2 = MMC_CAP2_BROKEN_VOLTAGE;
+
 	if (pdata->pm_caps)
 		host->mmc->pm_caps |= pdata->pm_caps;
 
@@ -543,10 +546,6 @@ static int __devinit sdhci_s3c_probe(struct platform_device *pdev)
 		sdhci_s3c_ops.get_max_clock = sdhci_cmu_get_max_clock;
 	}
 
-	/* It supports additional host capabilities if needed */
-	if (pdata->host_caps)
-		host->mmc->caps |= pdata->host_caps;
-
 	ret = sdhci_add_host(host);
 	if (ret) {
 		dev_err(dev, "sdhci_add_host() failed\n");
#1 lore raw
Quoted 14 lines · Jaehoon Chung

Samsung-SoC need to add the MMC_CAP2_BROKEN_VOLTAGE.

---
 drivers/mmc/host/sdhci-s3c.c |    7 +++----

 1 files changed, 3 insertions(+), 4 deletions(-)
drivers/mmc/host/sdhci-s3c.c +0 -0
index d065e37..e7e2b6b 100644

drivers/mmc/host/sdhci-s3c.c static int __devinit sdhci_s3c_probe(struct platform_device *pdev) · line 528

Quoted 8 lines
drivers/mmc/host/sdhci-s3c.c +2 -0
@@ -521,9 +521,12 @@ static int __devinit sdhci_s3c_probe(struct platform_device *pdev)
        if (pdata->cd_type == S3C_SDHCI_CD_PERMANENT)
                host->mmc->caps = MMC_CAP_NONREMOVABLE;
 
+       /* It supports additional host capabilities if needed */
        if (pdata->host_caps)
                host->mmc->caps |= pdata->host_caps;
 
+       host->mmc->caps2 = MMC_CAP2_BROKEN_VOLTAGE;

Dont you think this should be set in the machine specific platform data structure. If done in the machine specific file
only if (pdata->host_caps2)

              host->mmc->caps2 |= pdata->host_caps2

would be more generic to pull all the caps2 fields

Quoted 19 lines
drivers/mmc/host/sdhci-s3c.c +1 -5
+
        if (pdata->pm_caps)
                host->mmc->pm_caps |= pdata->pm_caps;
 
@@ -543,10 +546,6 @@ static int __devinit sdhci_s3c_probe(struct platform_device *pdev)
                sdhci_s3c_ops.get_max_clock = sdhci_cmu_get_max_clock;
        }
 
-       /* It supports additional host capabilities if needed */
-       if (pdata->host_caps)
-               host->mmc->caps |= pdata->host_caps;
-
        ret = sdhci_add_host(host);
        if (ret) {
                dev_err(dev, "sdhci_add_host() failed\n");
--

To unsubscribe from this list: send the line "unsubscribe linux-mmc" in the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

author maintainer
#2 lore raw
Quoted 22 lines · Girish K S
Quoted 21 lines · Jaehoon Chung

Samsung-SoC need to add the MMC_CAP2_BROKEN_VOLTAGE.

---
 drivers/mmc/host/sdhci-s3c.c |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)
drivers/mmc/host/sdhci-s3c.c +1 -0
index d065e37..e7e2b6b 100644
@@ -521,9 +521,12 @@ static int __devinit sdhci_s3c_probe(struct platform_device *pdev)
       if (pdata->cd_type == S3C_SDHCI_CD_PERMANENT)
               host->mmc->caps = MMC_CAP_NONREMOVABLE;
 
+       /* It supports additional host capabilities if needed */
       if (pdata->host_caps)
               host->mmc->caps |= pdata->host_caps;
 
Quoted 7 lines

drivers/mmc/host/sdhci-s3c.c static int __devinit sdhci_s3c_probe(struct platform_device *pdev) · line 528

Quoted 1 line
drivers/mmc/host/sdhci-s3c.c +1 -0
+       host->mmc->caps2 = MMC_CAP2_BROKEN_VOLTAGE;

Dont you think this should be set in the machine specific platform data structure. If done in the machine specific file
only if (pdata->host_caps2)

              host->mmc->caps2 |= pdata->host_caps2

would be more generic to pull all the caps2 fields

Right..i think also that.
Actually I sent the second capability patch for Samsung-SoC before... Kukjin Kim didn't accept the patch.
http://www.mail-archive.com/[email protected]/msg07456.html
http://www.mail-archive.com/[email protected]/msg07455.html

I will resend the patch..if he will accept them..

Best Regards,
Jaehoon Chung

Quoted 25 lines
Quoted 17 lines
drivers/mmc/host/sdhci-s3c.c +1 -5
+
       if (pdata->pm_caps)
               host->mmc->pm_caps |= pdata->pm_caps;
 
@@ -543,10 +546,6 @@ static int __devinit sdhci_s3c_probe(struct platform_device *pdev)
               sdhci_s3c_ops.get_max_clock = sdhci_cmu_get_max_clock;
       }
 
-       /* It supports additional host capabilities if needed */
-       if (pdata->host_caps)
-               host->mmc->caps |= pdata->host_caps;
-
       ret = sdhci_add_host(host);
       if (ret) {
               dev_err(dev, "sdhci_add_host() failed\n");
--
Quoted 3 lines

To unsubscribe from this list: send the line "unsubscribe linux-mmc" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html