Re: ram initialization on mcp2518fd

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

 



On 16/06/2022 14.40, Marc Kleine-Budde wrote:
> On 16.06.2022 13:21:52, Rasmus Villemoes wrote:

>>> Have you enabled DMA on SPI?
>>
>> Not explicitly, but nor have I done anything to disable/not enable it,
>> so I'm not really sure what the right answer is. Is that a CONFIG_ knob
>> or module/kernel parameter?
> 
> You can use "/delete-property/ dmas;" and "/delete-property/ dma-names;"
> in your board dts on the &ecspi1 node, the module parameter "use_dma=0",
> or the kernel command line "spi-imx.use_dma=0" to disable DMA.
> 
> The SPI host driver uses PIO for smaller transfers, but switches to DMA
> mode for bigger ones (IIRC > 64 bytes). The clearing of the memory
> definitely falls into the big transfer category. The SPI DMA mode is
> broken on various kernel variants (downstream, mainline), kernel
> versions, SoC variants and used SDMA firmware versions. For the
> mcp251xfd driver DMA is also slower. So switch of DMA and try again.

Thanks! Disabling DMA did the trick, and I can now send traffic back and
forth between the two chips, and since the RAM now gets properly
initialized, I also don't get the ecc error interrupts.

There is still something to be looked at, since I see

NOHZ tick-stop error: Non-RCU local softirq work is pending, handler #08!!!

when I start the traffic test. And the dev_id reading still doesn't work
(though it's not really used for anything other than an informative
printk). But I'll have to get our hardware guys to help me do some
soldering to capture all four channels at once to see just exactly what
is going on there.

Rasmus



[Index of Archives]     [Automotive Discussions]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]     [CAN Bus]

  Powered by Linux