* A serial patchs that support FSL's eSDHC
@ 2010-09-01 9:45 Richard Zhu
2010-09-01 9:45 ` [PATCH 1/9] sdhci-1: add host's own set_power func to support the controller that used it's own power mechanism Richard Zhu
2010-09-01 10:15 ` A serial patchs that support FSL's eSDHC Wolfram Sang
0 siblings, 2 replies; 5+ messages in thread
From: Richard Zhu @ 2010-09-01 9:45 UTC (permalink / raw)
To: linux-arm-kernel
Hi All:
Can you help me to review the following serial patchs, that enable the sdhci
driver to support FSL's eSDHC on i.MX family.
Thanks in advanced.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH 1/9] sdhci-1: add host's own set_power func to support the controller that used it's own power mechanism
2010-09-01 9:45 A serial patchs that support FSL's eSDHC Richard Zhu
@ 2010-09-01 9:45 ` Richard Zhu
2010-09-01 10:15 ` A serial patchs that support FSL's eSDHC Wolfram Sang
1 sibling, 0 replies; 5+ messages in thread
From: Richard Zhu @ 2010-09-01 9:45 UTC (permalink / raw)
To: linux-arm-kernel
FSL's eSDHC controllers don't have the STANDARD POWER register in
the IC design, add the set_power api to support the FSL's eSDHC.
Signed-off-by: Richard Zhu <r65037@freescale.com>
---
drivers/mmc/host/sdhci.c | 5 +++++
drivers/mmc/host/sdhci.h | 1 +
2 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
index 7855121..2a93c27 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
@@ -1036,6 +1036,11 @@ static void sdhci_set_power(struct sdhci_host *host, unsigned short power)
{
u8 pwr;
+ if (host->ops->set_power) {
+ host->ops->set_power(host, power);
+ return;
+ }
+
if (power == (unsigned short)-1)
pwr = 0;
else {
diff --git a/drivers/mmc/host/sdhci.h b/drivers/mmc/host/sdhci.h
index 036cfae..d420b4e 100644
--- a/drivers/mmc/host/sdhci.h
+++ b/drivers/mmc/host/sdhci.h
@@ -316,6 +316,7 @@ struct sdhci_ops {
#endif
void (*set_clock)(struct sdhci_host *host, unsigned int clock);
+ void (*set_power)(struct sdhci_host *host, unsigned int power);
int (*enable_dma)(struct sdhci_host *host);
unsigned int (*get_max_clock)(struct sdhci_host *host);
--
1.7.0
^ permalink raw reply related [flat|nested] 5+ messages in thread* A serial patchs that support FSL's eSDHC
2010-09-01 9:45 A serial patchs that support FSL's eSDHC Richard Zhu
2010-09-01 9:45 ` [PATCH 1/9] sdhci-1: add host's own set_power func to support the controller that used it's own power mechanism Richard Zhu
@ 2010-09-01 10:15 ` Wolfram Sang
2010-09-02 10:06 ` Zhu Richard-R65037
1 sibling, 1 reply; 5+ messages in thread
From: Wolfram Sang @ 2010-09-01 10:15 UTC (permalink / raw)
To: linux-arm-kernel
On Wed, Sep 01, 2010 at 05:45:04PM +0800, Richard Zhu wrote:
> Can you help me to review the following serial patchs, that enable the sdhci
> driver to support FSL's eSDHC on i.MX family.
I see two major problems: First, you often modify sdhci.c to work around
the hardware-quirks. See sdhci-of-esdhc.c how it can be handled in a
seperate source-file and keep sdhci.c clean. (While at it, what is
common between the of-driver and the platform-driver should be shared).
Second, your platform-driver is a complete one, but we have a platform
core meanwhile (sdhci-pltfm.c). Please use that.
Kind regards,
Wolfram
--
Pengutronix e.K. | Wolfram Sang |
Industrial Linux Solutions | http://www.pengutronix.de/ |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20100901/3451cf26/attachment.sig>
^ permalink raw reply [flat|nested] 5+ messages in thread
* A serial patchs that support FSL's eSDHC
2010-09-01 10:15 ` A serial patchs that support FSL's eSDHC Wolfram Sang
@ 2010-09-02 10:06 ` Zhu Richard-R65037
2010-09-06 10:30 ` Wolfram Sang
0 siblings, 1 reply; 5+ messages in thread
From: Zhu Richard-R65037 @ 2010-09-02 10:06 UTC (permalink / raw)
To: linux-arm-kernel
Hi Wolfram:
Thanks for your comments.
I would change the patches and resend them later.
Best Regards,
Richard Zhu
Freescale Semiconductor
Tel: +86-021-28937189
Email:Hong-Xing.Zhu at freescale.com
-----Original Message-----
From: Wolfram Sang [mailto:w.sang at pengutronix.de]
Sent: Wednesday, 1 September, 2010 18:15
To: Zhu Richard-R65037
Cc: linux-mmc at vger.kernel.org; kernel at pengutronix.de;
linux-arm-kernel at lists.infradead.org
Subject: Re: A serial patchs that support FSL's eSDHC
On Wed, Sep 01, 2010 at 05:45:04PM +0800, Richard Zhu wrote:
> Can you help me to review the following serial patchs, that enable the
> sdhci driver to support FSL's eSDHC on i.MX family.
I see two major problems: First, you often modify sdhci.c to work around
the hardware-quirks. See sdhci-of-esdhc.c how it can be handled in a
seperate source-file and keep sdhci.c clean. (While at it, what is
common between the of-driver and the platform-driver should be shared).
Second, your platform-driver is a complete one, but we have a platform
core meanwhile (sdhci-pltfm.c). Please use that.
Kind regards,
Wolfram
--
Pengutronix e.K. | Wolfram Sang
|
Industrial Linux Solutions | http://www.pengutronix.de/
|
^ permalink raw reply [flat|nested] 5+ messages in thread
* A serial patchs that support FSL's eSDHC
2010-09-02 10:06 ` Zhu Richard-R65037
@ 2010-09-06 10:30 ` Wolfram Sang
0 siblings, 0 replies; 5+ messages in thread
From: Wolfram Sang @ 2010-09-06 10:30 UTC (permalink / raw)
To: linux-arm-kernel
Hi Richard,
(going back to the list. A few more eyes during the process will surely
help :))
On Fri, Sep 03, 2010 at 06:26:05PM +0800, Zhu Richard-R65037 wrote:
> I encounter some problems when I merge my eSDHC driver into
> sdhci-pltfm.c driver.
> In the eSDHC solution there is a little complex in the driver
> implementation refer to the HW/IC design.
> One private struct such as sdhci_fsl_host in my original codes is
> needed, and the board specified platform data (such
> as imxmmc_platform_data struct) is mandatory required too.
>
> sdhci-pltfm.c driver can't provide such kinds of APIs.
> Do you have any suggestions?
Well, I think we can do without. In a few minutes, I will post an RFC
which I just hacked. Please have a look at it, and say if you have
comments or suggestions. Hopefully you'll agree that this approach is a
lot less intrusive. I will mainly concentrate on the driver. For the
platform part, Uwe already gave a few comments. I will also reply to
some of your patches to clarify some issues.
Regards,
Wolfram
--
Pengutronix e.K. | Wolfram Sang |
Industrial Linux Solutions | http://www.pengutronix.de/ |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20100906/de6ef16d/attachment.sig>
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-09-06 10:30 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-09-01 9:45 A serial patchs that support FSL's eSDHC Richard Zhu
2010-09-01 9:45 ` [PATCH 1/9] sdhci-1: add host's own set_power func to support the controller that used it's own power mechanism Richard Zhu
2010-09-01 10:15 ` A serial patchs that support FSL's eSDHC Wolfram Sang
2010-09-02 10:06 ` Zhu Richard-R65037
2010-09-06 10:30 ` Wolfram Sang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).