All of lore.kernel.org
 help / color / mirror / Atom feed
From: Faiz Abbas <faiz_abbas@ti.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v4 07/15] mmc: sdhci: Make set_ios_post() return int
Date: Thu, 23 May 2019 12:37:44 -0500	[thread overview]
Message-ID: <20190523173752.28680-8-faiz_abbas@ti.com> (raw)
In-Reply-To: <20190523173752.28680-1-faiz_abbas@ti.com>

Make set_ios_post() return int to faciliate error handling in
platform drivers.

Signed-off-by: Faiz Abbas <faiz4000@gmail.com>
---
 drivers/mmc/sdhci.c       | 2 +-
 drivers/mmc/xenon_sdhci.c | 4 +++-
 include/sdhci.h           | 2 +-
 3 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/drivers/mmc/sdhci.c b/drivers/mmc/sdhci.c
index 4646dbec9f..75e6567631 100644
--- a/drivers/mmc/sdhci.c
+++ b/drivers/mmc/sdhci.c
@@ -583,7 +583,7 @@ static int sdhci_set_ios(struct mmc *mmc)
 
 	/* If available, call the driver specific "post" set_ios() function */
 	if (host->ops && host->ops->set_ios_post)
-		host->ops->set_ios_post(host);
+		return host->ops->set_ios_post(host);
 
 	return 0;
 }
diff --git a/drivers/mmc/xenon_sdhci.c b/drivers/mmc/xenon_sdhci.c
index b576511338..829b75683b 100644
--- a/drivers/mmc/xenon_sdhci.c
+++ b/drivers/mmc/xenon_sdhci.c
@@ -326,7 +326,7 @@ static void xenon_mask_cmd_conflict_err(struct sdhci_host *host)
 }
 
 /* Platform specific function for post set_ios configuration */
-static void xenon_sdhci_set_ios_post(struct sdhci_host *host)
+static int xenon_sdhci_set_ios_post(struct sdhci_host *host)
 {
 	struct xenon_sdhci_priv *priv = host->mmc->priv;
 	uint speed = host->mmc->tran_speed;
@@ -364,6 +364,8 @@ static void xenon_sdhci_set_ios_post(struct sdhci_host *host)
 
 	/* Re-init the PHY */
 	xenon_mmc_phy_set(host);
+
+	return 0;
 }
 
 /* Install a driver specific handler for post set_ios configuration */
diff --git a/include/sdhci.h b/include/sdhci.h
index 820cd16e92..3dcbc14965 100644
--- a/include/sdhci.h
+++ b/include/sdhci.h
@@ -247,7 +247,7 @@ struct sdhci_ops {
 #endif
 	int	(*get_cd)(struct sdhci_host *host);
 	void	(*set_control_reg)(struct sdhci_host *host);
-	void	(*set_ios_post)(struct sdhci_host *host);
+	int	(*set_ios_post)(struct sdhci_host *host);
 	void	(*set_clock)(struct sdhci_host *host, u32 div);
 	int (*platform_execute_tuning)(struct mmc *host, u8 opcode);
 	void (*set_delay)(struct sdhci_host *host);
-- 
2.17.1

  parent reply	other threads:[~2019-05-23 17:37 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-23 17:37 [U-Boot] [PATCH v4 00/15] Add Support for eMMC in AM65x-evm Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 01/15] arm64: dts: k3: Sync sdhci0 node from kernel and change driver name Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 02/15] mmc: am654_sdhci: Remove quirks Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 03/15] regmap: Add API regmap_init_mem_index() Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 04/15] mmc: sdhci: Add support for sdhci-caps-mask Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 05/15] mmc: sdhci: Make sdhci_set_clock() non static Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 06/15] arm: dts: k3: Add phy specific properties to SD card node Faiz Abbas
2019-05-23 18:57   ` Andreas Dannenberg
2019-05-29  9:47     ` Faiz Abbas
2019-05-23 17:37 ` Faiz Abbas [this message]
2019-05-23 17:37 ` [U-Boot] [PATCH v4 08/15] mmc: am654_sdhci: Add Support for PHY Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 09/15] configs: am65x_evm: Enable CONFIG_REGMAP Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 10/15] mmc: am654_sdhci: Use f_max in mmc_config Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 11/15] mmc: sdhci: Add support for HOST_CONTROL2 and setting UHS timings Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 12/15] mmc: am654_sdhci: Add a platform specific set_control_reg() callback Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 13/15] configs: am65x: Add configs to support environment in eMMC Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 14/15] am65x_evm: Add Support for creating a filesystem GPT partition " Faiz Abbas
2019-05-23 17:37 ` [U-Boot] [PATCH v4 15/15] configs: am65x_evm_a53: Add Support for creating GPT partitions Faiz Abbas

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=20190523173752.28680-8-faiz_abbas@ti.com \
    --to=faiz_abbas@ti.com \
    --cc=u-boot@lists.denx.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.