[Letux-kernel] [PATCH 00/20] A bunch of JZ4730 fixups for letux-kernel

Paul Boddie paul at boddie.org.uk
Fri Dec 11 23:58:44 CET 2020


On Friday, 11 December 2020 08:38:36 CET H. Nikolaus Schaller wrote:
>
> No, there was already reward because it made the jz4370 dma succeed in
> probe. Even if it is still wrong we would not have found other minor
> issues.

I have been updating the documentation with some discoveries about the JZ4730 
from the legacy kernel and other documentation:

https://projects.goldelico.com/p/letux400/page/DMA/

To attempt to provide no-descriptor transfer support, I have made a patch that 
populates the registers from prepared descriptors when DMA is initiated. I 
don't know how reasonable this idea is, though.

> What I think we should also try to identify is why the MMC is not detected
> at all. At least there should be some indication, even if DMA can not read.
> 
> This could be an gpio or regulator or mmc-host driver issue.
> 
> If I find time for a debug session I could try to find how card insert
> detection works and if it works...

I guess I can review this at some point. From a quick look at the board-
minipc.h file from the legacy kernel, the pin assignments look correct in our 
device tree:

* Power is on PA21 (pin 21) and is active low
* Card detect is on PC0 (pin 64) and is active low
* Write protect is on PC2 (pin 66)

One interesting thing I see in the legacy code is when an explicit test is 
made for the card, the pin mode is changed to being a plain GPIO before 
testing and then restored to IRQ generation afterwards. However, this may just 
be relevant for this old code and its particular way of doing things.

With regard to the modern kernel, I see that the MMC driver should revert to a 
non-DMA operating mode if the DMA channels cannot be acquired.

Anyway, those are my thoughts for today!

Paul
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Introduce-JZ4730-no-descriptor-transfers-instead.patch
Type: text/x-patch
Size: 5007 bytes
Desc: not available
URL: <http://lists.goldelico.com/pipermail/letux-kernel/attachments/20201211/fbafb68b/attachment.bin>


More information about the Letux-kernel mailing list