Message ID | 1323294468-13904-2-git-send-email-agust@denx.de |
---|---|
State | Accepted, archived |
Commit | bfe6f6235fdfa130ad8c5a8898ef4d3a37bcad8c |
Delegated to: | Andy Fleming |
Headers | show |
Hi Anatolij, On Thu, Dec 8, 2011 at 5:47 AM, Anatolij Gustschin <agust@denx.de> wrote: > Fix: > mv_sdhci.c: In function 'mv_sdh_init': > mv_sdhci.c:47:22: warning: the comparison will always > evaluate as 'true' for the address of 'mv_sdhci_writeb' > will never be NULL [-Waddress] > > Signed-off-by: Anatolij Gustschin <agust@denx.de> > Cc: Lei Wen <leiwen@marvell.com> > Cc: Andy Fleming <afleming@freescale.com> > --- > drivers/mmc/mv_sdhci.c | 3 +-- > 1 files changed, 1 insertions(+), 2 deletions(-) > > diff --git a/drivers/mmc/mv_sdhci.c b/drivers/mmc/mv_sdhci.c > index 1501974..2fe34b6 100644 > --- a/drivers/mmc/mv_sdhci.c > +++ b/drivers/mmc/mv_sdhci.c > @@ -44,8 +44,7 @@ int mv_sdh_init(u32 regbase, u32 max_clk, u32 min_clk, u32 quirks) > host->quirks = quirks; > #ifdef CONFIG_MMC_SDHCI_IO_ACCESSORS > memset(&mv_ops, 0, sizeof(struct sdhci_ops)); > - if (mv_sdhci_writeb != NULL) > - mv_ops.write_b = mv_sdhci_writeb; > + mv_ops.write_b = mv_sdhci_writeb; > host->ops = &mv_ops; > #endif > if (quirks & SDHCI_QUIRK_REG32_RW) > -- > 1.7.5.4 > > _______________________________________________ > U-Boot mailing list > U-Boot@lists.denx.de > http://lists.denx.de/mailman/listinfo/u-boot Thanks for pointing it out! Acked-by: Lei Wen <leiwen@marvell.com>
On Wed, Dec 7, 2011 at 3:47 PM, Anatolij Gustschin <agust@denx.de> wrote: > Fix: > mv_sdhci.c: In function 'mv_sdh_init': > mv_sdhci.c:47:22: warning: the comparison will always > evaluate as 'true' for the address of 'mv_sdhci_writeb' > will never be NULL [-Waddress] > > Signed-off-by: Anatolij Gustschin <agust@denx.de> > Cc: Lei Wen <leiwen@marvell.com> > Cc: Andy Fleming <afleming@freescale.com> Applied, thanks! Andy
diff --git a/drivers/mmc/mv_sdhci.c b/drivers/mmc/mv_sdhci.c index 1501974..2fe34b6 100644 --- a/drivers/mmc/mv_sdhci.c +++ b/drivers/mmc/mv_sdhci.c @@ -44,8 +44,7 @@ int mv_sdh_init(u32 regbase, u32 max_clk, u32 min_clk, u32 quirks) host->quirks = quirks; #ifdef CONFIG_MMC_SDHCI_IO_ACCESSORS memset(&mv_ops, 0, sizeof(struct sdhci_ops)); - if (mv_sdhci_writeb != NULL) - mv_ops.write_b = mv_sdhci_writeb; + mv_ops.write_b = mv_sdhci_writeb; host->ops = &mv_ops; #endif if (quirks & SDHCI_QUIRK_REG32_RW)
Fix: mv_sdhci.c: In function 'mv_sdh_init': mv_sdhci.c:47:22: warning: the comparison will always evaluate as 'true' for the address of 'mv_sdhci_writeb' will never be NULL [-Waddress] Signed-off-by: Anatolij Gustschin <agust@denx.de> Cc: Lei Wen <leiwen@marvell.com> Cc: Andy Fleming <afleming@freescale.com> --- drivers/mmc/mv_sdhci.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-)