Re: [PATCH 06/12] mci: sdhci: Use Linux defines for SDHCI_HOST_CONTROL register

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jan 26, 2022 at 09:32:33AM +0300, Antony Pavlov wrote:
> On Mon,  7 Jun 2021 12:44:05 +0200
> Sascha Hauer <s.hauer@xxxxxxxxxxxxxx> wrote:
> 
> Hi Sascha!
> 
> > To ease porting and comparing of Linux code.
> > 
> > Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx>
> > ---
> >  drivers/mci/arasan-sdhci.c       | 12 ++++++------
> >  drivers/mci/atmel-sdhci-common.c | 14 +++++++-------
> >  drivers/mci/dove-sdhci.c         | 10 +++++-----
> >  drivers/mci/sdhci.h              | 17 ++++++++++++-----
> >  4 files changed, 30 insertions(+), 23 deletions(-)
> > 
> > diff --git a/drivers/mci/arasan-sdhci.c b/drivers/mci/arasan-sdhci.c
> > index e22db4cfa3..e02f222345 100644
> > --- a/drivers/mci/arasan-sdhci.c
> > +++ b/drivers/mci/arasan-sdhci.c
> 
> ...
> 
> > @@ -200,21 +200,21 @@ static void arasan_sdhci_set_ios(struct mci_host *mci, struct mci_ios *ios)
> >  	}
> >  
> >  	val = sdhci_read8(&host->sdhci, SDHCI_HOST_CONTROL) &
> > -			~(SDHCI_DATA_WIDTH_4BIT | SDHCI_DATA_WIDTH_8BIT);
> > +			~(SDHCI_CTRL_8BITBUS | SDHCI_CTRL_8BITBUS);
> >  
> >  	switch (ios->bus_width) {
> >  	case MMC_BUS_WIDTH_8:
> > -		val |= SDHCI_DATA_WIDTH_8BIT;
> > +		val |= SDHCI_CTRL_8BITBUS;
> >  		break;
> >  	case MMC_BUS_WIDTH_4:
>                      ^^^^^^^^
> > -		val |= SDHCI_DATA_WIDTH_4BIT;
>                                   ^^^^^^^^^^^
> > +		val |= SDHCI_CTRL_8BITBUS;
>                                   ^^^^^^^
> Is this correct?

Nope, indeed not. Fortunately it's fixed in the same series in "[PATCH
08/12] mci: sdhci: arasan: Use sdhci_set_bus_width()". The other places
need fixing though, patch is out.

Thanks for noting

Sascha

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux