* Re: FW: [PATCH v2] mmc: host: sdhci: Fix parameter of sdhci_do_start_signal_voltage_switch()
[not found] <25B60CDC2F704E4E9D88FFD52780CB4C0BDE525A28@SC-VEXCH1.marvell.com>
@ 2013-02-16 4:22 ` Kevin Liu
2013-02-18 15:50 ` Fabio Estevam
0 siblings, 1 reply; 2+ messages in thread
From: Kevin Liu @ 2013-02-16 4:22 UTC (permalink / raw)
To: Fabio Estevam; +Cc: Chris Ball, linux-mmc, Ulf Hansson
> -----Original Message-----
> From: Fabio Estevam [mailto:fabio.estevam@freescale.com]
> Sent: Thursday, February 14, 2013 8:35 PM
> To: cjb@laptop.org
> Cc: Kevin Liu; linux-mmc@vger.kernel.org; ulf.hansson@linaro.org; Fabio Estevam
> Subject: [PATCH v2] mmc: host: sdhci: Fix parameter of sdhci_do_start_signal_voltage_switch()
>
> Commit 3714f4315354 (mmc: sdhci: update signal voltage switch code) changed the
> type of the second parameter of sdhci_do_start_signal_voltage_switch(), from
> "struct mmc_ios *ios" to "int signal_voltage" which causes the following build
> warning:
>
> drivers/mmc/host/sdhci.c:2044:2: warning: initialization from incompatible pointer type [enabled by default]
> drivers/mmc/host/sdhci.c:2044:2: warning: (near initialization for 'sdhci_ops.start_signal_voltage_switch') [enabled by default]
>
> Use the previous type so that it matches the start_signal_voltage_switch()
> definition from host.h.
>
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
> ---
> Changes since v1:
> - Fix it inside sdhci to avoid breakage on other mmc controllers
>
> drivers/mmc/host/sdhci.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
> index 735526b..51bbba4 100644
> --- a/drivers/mmc/host/sdhci.c
> +++ b/drivers/mmc/host/sdhci.c
> @@ -1675,7 +1675,7 @@ static void sdhci_enable_sdio_irq(struct mmc_host *mmc, int enable)
> }
>
> static int sdhci_do_start_signal_voltage_switch(struct sdhci_host *host,
> - int signal_voltage)
> + struct mmc_ios *ios)
> {
> u16 ctrl;
> int ret;
> @@ -1689,7 +1689,7 @@ static int sdhci_do_start_signal_voltage_switch(struct sdhci_host *host,
>
> ctrl = sdhci_readw(host, SDHCI_HOST_CONTROL2);
>
> - switch (signal_voltage) {
> + switch (ios->signal_voltage) {
> case MMC_SIGNAL_VOLTAGE_330:
> /* Set 1.8V Signal Enable in the Host Control2 register to 0 */
> ctrl &= ~SDHCI_CTRL_VDD_180;
> @@ -1762,7 +1762,7 @@ static int sdhci_do_start_signal_voltage_switch(struct sdhci_host *host,
> }
>
> static int sdhci_start_signal_voltage_switch(struct mmc_host *mmc,
> - int signal_voltage)
> + struct mmc_ios *ios)
> {
> struct sdhci_host *host = mmc_priv(mmc);
> int err;
> @@ -1770,7 +1770,7 @@ static int sdhci_start_signal_voltage_switch(struct mmc_host *mmc,
> if (host->version < SDHCI_SPEC_300)
> return 0;
> sdhci_runtime_pm_get(host);
> - err = sdhci_do_start_signal_voltage_switch(host, signal_voltage);
> + err = sdhci_do_start_signal_voltage_switch(host, ios);
> sdhci_runtime_pm_put(host);
> return err;
> }
Fabio,
Thanks a lot for finding this and quick fix!
My original purpose is to change the argument type from ios to
signal_voltage. But the code change for mmc core was not integrated
into Johan's final patchset ([PATCH v6 5/5] mmc: core: Fixup signal
voltage switch).
So I still prefer your first version. I submit below patch for this just now:
"[PATCH] mmc: core: update start_signal_voltage_switch argument type"
Please help to reivew and can I add your name to the signoff?
Chris,
Can I suggest to combine my above patch with Fabio's patch? I think
they are related.
Thanks
Kevin
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: FW: [PATCH v2] mmc: host: sdhci: Fix parameter of sdhci_do_start_signal_voltage_switch()
2013-02-16 4:22 ` FW: [PATCH v2] mmc: host: sdhci: Fix parameter of sdhci_do_start_signal_voltage_switch() Kevin Liu
@ 2013-02-18 15:50 ` Fabio Estevam
0 siblings, 0 replies; 2+ messages in thread
From: Fabio Estevam @ 2013-02-18 15:50 UTC (permalink / raw)
To: Kevin Liu; +Cc: Chris Ball, linux-mmc, Ulf Hansson, Fabio Estevam
Kevin Liu wrote:
> Thanks a lot for finding this and quick fix!
> My original purpose is to change the argument type from ios to
> signal_voltage. But the code change for mmc core was not integrated
> into Johan's final patchset ([PATCH v6 5/5] mmc: core: Fixup signal
> voltage switch).
> So I still prefer your first version. I submit below patch for this just now:
Chris has already applied my patch, so if you need to make further changes, just send incremental patches on top of it.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-02-18 15:32 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <25B60CDC2F704E4E9D88FFD52780CB4C0BDE525A28@SC-VEXCH1.marvell.com>
2013-02-16 4:22 ` FW: [PATCH v2] mmc: host: sdhci: Fix parameter of sdhci_do_start_signal_voltage_switch() Kevin Liu
2013-02-18 15:50 ` Fabio Estevam
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.