Re: [U-Boot] [PATCH 2/2] MMC: add marvell sdhci driver
Hi Prafulla, On Fri, Jun 17, 2011 at 3:33 PM, Prafulla Wadaskar wrote: > > >> -Original Message- >> From: Lei Wen [mailto:lei...@marvell.com] >> Sent: Thursday, June 16, 2011 8:48 PM >> To: Andy Fleming; Rob Herring; u-boot@lists.denx.de; Prafulla Wadaskar; >> Yu Tang; Prabhanjan Sarnaik; Ashish Karkare >> Subject: [PATCH 2/2] MMC: add marvell sdhci driver >> >> This could support both armada100 and pantheon serial in the mainline, >> while this driver also be tested to support upcoming mg, mmp2 and mmp3 >> hardware. >> >> Signed-off-by: Lei Wen >> --- >> drivers/mmc/Makefile | 1 + >> drivers/mmc/sdhci-mv.c | 21 + > > The file name should be mv_sdhci.c > >> 2 files changed, 22 insertions(+), 0 deletions(-) >> create mode 100644 drivers/mmc/sdhci-mv.c >> >> diff --git a/drivers/mmc/Makefile b/drivers/mmc/Makefile >> index 50b5117..fd84389 100644 >> --- a/drivers/mmc/Makefile >> +++ b/drivers/mmc/Makefile >> @@ -39,6 +39,7 @@ COBJS-$(CONFIG_OMAP_HSMMC) += omap_hsmmc.o >> COBJS-$(CONFIG_PXA_MMC) += pxa_mmc.o >> COBJS-$(CONFIG_S5P_MMC) += s5p_mmc.o >> COBJS-$(CONFIG_SDHCI) += sdhci.o >> +COBJS-$(CONFIG_SDHCI_MV) += sdhci-mv.o > > Same here CONFIG_MV_SDHCI > >> >> COBJS := $(COBJS-y) >> SRCS := $(COBJS:.o=.c) >> diff --git a/drivers/mmc/sdhci-mv.c b/drivers/mmc/sdhci-mv.c >> new file mode 100644 >> index 000..97d79ee >> --- /dev/null >> +++ b/drivers/mmc/sdhci-mv.c >> @@ -0,0 +1,21 @@ >> +#include >> +#include >> +#include >> + >> +static char *MVSDH_NAME = "sdh-mv"; > > "mv_sdhci" sounds better. > I have no concern with the name change, this would be included in next patch set. Best regards, Lei ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 2/2] MMC: add marvell sdhci driver
> -Original Message- > From: Lei Wen [mailto:lei...@marvell.com] > Sent: Thursday, June 16, 2011 8:48 PM > To: Andy Fleming; Rob Herring; u-boot@lists.denx.de; Prafulla Wadaskar; > Yu Tang; Prabhanjan Sarnaik; Ashish Karkare > Subject: [PATCH 2/2] MMC: add marvell sdhci driver > > This could support both armada100 and pantheon serial in the mainline, > while this driver also be tested to support upcoming mg, mmp2 and mmp3 > hardware. > > Signed-off-by: Lei Wen > --- > drivers/mmc/Makefile |1 + > drivers/mmc/sdhci-mv.c | 21 + The file name should be mv_sdhci.c > 2 files changed, 22 insertions(+), 0 deletions(-) > create mode 100644 drivers/mmc/sdhci-mv.c > > diff --git a/drivers/mmc/Makefile b/drivers/mmc/Makefile > index 50b5117..fd84389 100644 > --- a/drivers/mmc/Makefile > +++ b/drivers/mmc/Makefile > @@ -39,6 +39,7 @@ COBJS-$(CONFIG_OMAP_HSMMC) += omap_hsmmc.o > COBJS-$(CONFIG_PXA_MMC) += pxa_mmc.o > COBJS-$(CONFIG_S5P_MMC) += s5p_mmc.o > COBJS-$(CONFIG_SDHCI) += sdhci.o > +COBJS-$(CONFIG_SDHCI_MV) += sdhci-mv.o Same here CONFIG_MV_SDHCI > > COBJS:= $(COBJS-y) > SRCS := $(COBJS:.o=.c) > diff --git a/drivers/mmc/sdhci-mv.c b/drivers/mmc/sdhci-mv.c > new file mode 100644 > index 000..97d79ee > --- /dev/null > +++ b/drivers/mmc/sdhci-mv.c > @@ -0,0 +1,21 @@ > +#include > +#include > +#include > + > +static char *MVSDH_NAME = "sdh-mv"; "mv_sdhci" sounds better. Regards.. Prafulla . . > +int mv_sdh_init(u32 regbase, u32 max_clk, u32 min_clk, u32 quirks) > +{ > + struct sdhci_host *host = NULL; > + host = (struct sdhci_host *)malloc(sizeof(struct sdhci_host)); > + if (!host) { > + printf("sdh_host malloc fail!\n"); > + return 1; > + } > + > + host->name = MVSDH_NAME; > + host->ioaddr = (void *)regbase; > + host->quirks = quirks; > + host->version = sdhci_readw(host, SDHCI_HOST_VERSION); > + add_sdhci(host, max_clk, min_clk); > + return 0; > +} > -- > 1.7.0.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 2/2] MMC: add marvell sdhci driver
This could support both armada100 and pantheon serial in the mainline, while this driver also be tested to support upcoming mg, mmp2 and mmp3 hardware. Signed-off-by: Lei Wen --- drivers/mmc/Makefile |1 + drivers/mmc/sdhci-mv.c | 21 + 2 files changed, 22 insertions(+), 0 deletions(-) create mode 100644 drivers/mmc/sdhci-mv.c diff --git a/drivers/mmc/Makefile b/drivers/mmc/Makefile index 50b5117..fd84389 100644 --- a/drivers/mmc/Makefile +++ b/drivers/mmc/Makefile @@ -39,6 +39,7 @@ COBJS-$(CONFIG_OMAP_HSMMC) += omap_hsmmc.o COBJS-$(CONFIG_PXA_MMC) += pxa_mmc.o COBJS-$(CONFIG_S5P_MMC) += s5p_mmc.o COBJS-$(CONFIG_SDHCI) += sdhci.o +COBJS-$(CONFIG_SDHCI_MV) += sdhci-mv.o COBJS := $(COBJS-y) SRCS := $(COBJS:.o=.c) diff --git a/drivers/mmc/sdhci-mv.c b/drivers/mmc/sdhci-mv.c new file mode 100644 index 000..97d79ee --- /dev/null +++ b/drivers/mmc/sdhci-mv.c @@ -0,0 +1,21 @@ +#include +#include +#include + +static char *MVSDH_NAME = "sdh-mv"; +int mv_sdh_init(u32 regbase, u32 max_clk, u32 min_clk, u32 quirks) +{ + struct sdhci_host *host = NULL; + host = (struct sdhci_host *)malloc(sizeof(struct sdhci_host)); + if (!host) { + printf("sdh_host malloc fail!\n"); + return 1; + } + + host->name = MVSDH_NAME; + host->ioaddr = (void *)regbase; + host->quirks = quirks; + host->version = sdhci_readw(host, SDHCI_HOST_VERSION); + add_sdhci(host, max_clk, min_clk); + return 0; +} -- 1.7.0.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot