mci: SDHC generic driver? refactor dove-sdhci?

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

 



Hello,

I've written a driver for snps,dw-mshc, which is compatible with SDHC spec.

Basically I've just copy pasted the dove-sdhci.c one and modified a few lines to add:

* support for host_v4 mode

* 64 bit addressing

* 64-bit SDMA

* PIO mode

* Support for 10-bit clock divider (max divider of 2046 instead of 256)

Chosing between SDMA and PIO is done with Kconfig defines at compile time. It's either one or the other.

Since snps,dw-mshc and dove-sdhci share the same code, because both respect SDHC spec I would propose to rename dove-sdhci.c into sdhci.c and remove all dove mentions inside.

Then write a dove-sdhci.c which registers via the sdhci generic layer and same thing for dw-mshc.

This allows lot of code sharing between SDHC compatible devices and also eases a lot the writing of new drivers.

Would that be OK?

Thanks!

Best regards,

--

Yann


_______________________________________________
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