Skip to contentSkip to conversation

mmc: omap_hsmmc: Add guards around omap_hsmmc_get_cfg()

PATCH New Tom Rini 3 participants 5 messages Jun 4, 2020 – Jun 18, 2020 MMC, SD and SDIO

lore
Share & tools
lore

Tom Rini

author
#0 lore raw

PATCH 1/1 mmc: omap_hsmmc: Add guards around omap_hsmmc_get_cfg()

We only call the function omap_hsmmc_get_cfg in the case of OMAP34XX or when we have to iodelay recalibration. Add guards for these checks as clang will otherwise warn.

Cc Peng Fan <[email protected]>
Cc Lokesh Vutla <[email protected]>

---
Aside, Lokesh, can you please add drivers/mmc/omap_hsmmc.c to the general TI entry MAINTAINERS entry? Thanks!

---
 drivers/mmc/omap_hsmmc.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/mmc/omap_hsmmc.c +3 -0
index 8636cd713a36..0e05fe4cfcbb 100644
@@ -175,6 +175,8 @@ static inline struct omap_hsmmc_data *omap_hsmmc_get_data(struct mmc *mmc)
 	return (struct omap_hsmmc_data *)mmc->priv;
 #endif
 }
+
+#if defined(CONFIG_OMAP34XX) || defined(CONFIG_IODELAY_RECALIBRATION)
 static inline struct mmc_config *omap_hsmmc_get_cfg(struct mmc *mmc)
 {
 #if CONFIG_IS_ENABLED(DM_MMC)
@@ -184,6 +186,7 @@ static inline struct mmc_config *omap_hsmmc_get_cfg(struct mmc *mmc)
 	return &((struct omap_hsmmc_data *)mmc->priv)->cfg;
 #endif
 }
+#endif
 
 #if defined(OMAP_HSMMC_USE_GPIO) && !CONFIG_IS_ENABLED(DM_MMC)
 static int omap_mmc_setup_gpio_in(int gpio, const char *label)
Signature · 1 line
2.17.1
#1 lore raw

PATCH 1/1 mmc: omap_hsmmc: Add guards around omap_hsmmc_get_cfg()

Quoted 34 lines

Subject: [PATCH] mmc: omap_hsmmc: Add guards around omap_hsmmc_get_cfg()

We only call the function omap_hsmmc_get_cfg in the case of OMAP34XX or when we have to iodelay recalibration. Add guards for these checks as clang will otherwise warn.

Cc Peng Fan <[email protected]>
Cc Lokesh Vutla <[email protected]>

---
Aside, Lokesh, can you please add drivers/mmc/omap_hsmmc.c to the general TI entry MAINTAINERS entry? Thanks!

---
 drivers/mmc/omap_hsmmc.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/mmc/omap_hsmmc.c +2 -0
index 8636cd713a36..0e05fe4cfcbb 100644
@@ -175,6 +175,8 @@ static inline struct omap_hsmmc_data
 *omap_hsmmc_get_data(struct mmc *mmc)
 	return (struct omap_hsmmc_data *)mmc->priv;  #endif  }
+
+#if defined(CONFIG_OMAP34XX) ||
 defined(CONFIG_IODELAY_RECALIBRATION)
 static inline struct mmc_config *omap_hsmmc_get_cfg(struct mmc *mmc)

{ #if CONFIG_IS_ENABLED(DM_MMC) @@ -184,6 +186,7 @@ static inline struct mmc_config *omap_hsmmc_get_cfg(struct mmc *mmc)

drivers/mmc/omap_hsmmc.c +1 -0
 	return &((struct omap_hsmmc_data *)mmc->priv)->cfg;  #endif  }
+#endif
 
 #if defined(OMAP_HSMMC_USE_GPIO)
Quoted 4 lines

&& !CONFIG_IS_ENABLED(DM_MMC) static int omap_mmc_setup_gpio_in(int gpio, const char *label) --
2.17.1

#2 lore raw

PATCH 1/1 mmc: omap_hsmmc: Add guards around omap_hsmmc_get_cfg()

In reply to Tom Rini
Quoted 7 lines · Tom Rini

We only call the function omap_hsmmc_get_cfg in the case of OMAP34XX or when we have to iodelay recalibration. Add guards for these checks as clang will otherwise warn.

Cc Peng Fan <[email protected]>
Cc Lokesh Vutla <[email protected]>
Quoted 3 lines

---
Aside, Lokesh, can you please add drivers/mmc/omap_hsmmc.c to the general TI entry MAINTAINERS entry? Thanks!

We have a subsystem maintainer for MMC. IIUC, all the patches should go through subsystem if one is available, so I intentionally did not add omap_hsmmc under TI. Is my understanding wrong?

Thanks and regards,
Lokesh

author
#3 lore raw

PATCH 1/1 mmc: omap_hsmmc: Add guards around omap_hsmmc_get_cfg()

Quoted 13 lines · Lokesh Vutla
Quoted 7 lines · Tom Rini

We only call the function omap_hsmmc_get_cfg in the case of OMAP34XX or when we have to iodelay recalibration. Add guards for these checks as clang will otherwise warn.

Cc Peng Fan <[email protected]>
Cc Lokesh Vutla <[email protected]>
Quoted 7 lines
Quoted 3 lines

---
Aside, Lokesh, can you please add drivers/mmc/omap_hsmmc.c to the general TI entry MAINTAINERS entry? Thanks!

We have a subsystem maintainer for MMC. IIUC, all the patches should go through subsystem if one is available, so I intentionally did not add omap_hsmmc under TI. Is my understanding wrong?

Yes. While there is a subsystem maintainer, they aren't going to know the IP-block quirks as well as the custodian for a given SoC, so individual drivers should be listed under the SoC/arch entry as well. get_maintainers.pl will list both when queried. Thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20200605/32b5bb43/attachment.sig>