Hi all,
the background is 1) using dm368 board receiving video data from spi interface; 2) decode the received video data and display it; 3) the video data is encoded and transmitted by another dm368 board which using spi interface too; 4)these two board is spi master all, but decode board uses external clock, and the other board uses internal clock, so the data can be transferred from encode board to decode board; 5) the spi driver i used is spidev, dma mode, 8 bits per word, 2MHz clock.
the problem i am facing is :
at most time, the data can be read correctly and in time, but some time it hang, the following message is console log when spi read hang:
Backtrace:
[<c036bf60>] (schedule+0x0/0x380) from [<c036c91c>] (schedule_timeout+0x24/0x220)
[<c036c8f8>] (schedule_timeout+0x0/0x220) from [<c036c774>] (wait_for_common+0xf4/0x1bc)
r7:7fffffff r6:c2d81e9c r5:c206e640 r4:c2d81e58
[<c036c680>] (wait_for_common+0x0/0x1bc) from [<c036c8cc>] (wait_for_completion+0x18/0x1c)
[<c036c8b4>] (wait_for_completion+0x0/0x1c) from [<c0220f70>] (spidev_sync+0xac/0xc8)
[<c0220ec4>] (spidev_sync+0x0/0xc8) from [<c0221118>] (spidev_read+0x8c/0xf0)
r5:c2d81ec0 r4:c2d81f08
[<c022108c>] (spidev_read+0x0/0xf0) from [<c009f470>] (vfs_read+0xb8/0x164)
[<c009f3b8>] (vfs_read+0x0/0x164) from [<c009f5e0>] (sys_read+0x44/0x70)
r8:40b3de0c r7:0000000c r6:c2954400 r5:00000000 r4:00000000
[<c009f59c>] (sys_read+0x0/0x70) from [<c002df40>] (ret_fast_syscall+0x0/0x28)
r8:c002e0c4 r7:00000003 r6:40b3f684 r5:00000002 r4:00000002
when i close the video decode thread, the spi read is ok.
the reason i think is dma problem with spi read and video decode, am i right? and how can i fix it?
thank you all.
