AnsweredAssumed Answered

SPI Burst Transfer on I.MX6 for long bytes stings

Question asked by Steven Yu on Dec 21, 2018
Latest reply on Dec 21, 2018 by Steven Yu

Hi All,

 

We would like to have higher throughput for SPI interface, and we have patch this attach file, and it works fine for 16bytes/32bytes data, but when we read 492 bytes data, it looks like DMA, IRQ or something error. Do you have any suggestion ?

 

spi-imx: imx6q add single burst transfer support - Patchwork 

 

_c_spi_read_alt ==> size: 492
mx51_ecspi_config: bits=8, len=6, mode=0, width=1,1
mx51_ecspi_config: bits=8, len=2, mode=1, width=1,1
mx51_ecspi_config: bits=8, len=492, mode=1, width=1,1
Single Burst config->len=492 reg:0x0000007a cfg:0x00000001 ctrl:0xf5f030f1

mx51_ecspi_config: bits=8, len=4, mode=1, width=1,1
mx51_ecspi_config: bits=8, len=4, mode=0, width=1,1
spi_rx_skb: hif->type=0 >= 10 ; len=0
------------[ cut here ]------------
Kernel BUG at 7f0f8020 [verbose debug info unavailable]
Internal error: Oops - BUG: 0 [#1] PREEMPT SMP ARM
Modules linked in: nrc(O) mac80211 cfg80211 g_ether usb_f_rndis u_ether libcomposite configfs evbug
CPU: 0 PID: 3480 Comm: spi-rx Tainted: G O 4.1.15 #72
Hardware name: Freescale i.MX6 Ultralite (Device Tree)
task: 88258000 ti: 88af0000 task.ti: 88af0000
PC is at spi_rx_thread+0x7b0/0x8a8 [nrc]
LR is at _raw_spin_unlock_irqrestore+0x28/0x54
pc : [<7f0f8020>] lr : [<807192d0>] psr: 600d0013
sp : 88af1f00 ip : 00000000 fp : 00000001
r10: 88580400 r9 : 88580678 r8 : 889c14c0
r7 : 8858067c r6 : 88af1f2c r5 : 8858067a r4 : 8894acc0
r3 : 00000000 r2 : 00000000 r1 : 800d0013 r0 : 00000000
Flags: nZCv IRQs on FIQs on Mode SVC_32 ISA ARM Segment kernel
Control: 10c53c7d Table: 8896806a DAC: 00000015
Process spi-rx (pid: 3480, stack limit = 0x88af0210)
Stack: (0x88af1f00 to 0x88af2000)
1f00: 00000001 889c14c0 000001e0 00000000 80a536fc 88a2dc20 00000000 885f4800
1f20: 8894acc0 80715c38 88a1bd28 00000000 88258000 80065fe4 88af1f38 88af1f38
1f40: 88580400 00000000 88b50780 88580400 7f0f7870 00000000 00000000 00000000
1f60: 00000000 8004f198 00000000 00000000 00000000 88580400 00000000 00000000
1f80: 88af1f80 88af1f80 00000000 00000000 88af1f90 88af1f90 88af1fac 88b50780
1fa0: 8004f0bc 00000000 00000000 8000f528 00000000 00000000 00000000 00000000
1fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
1fe0: 00000000 00000000 00000000 00000000 00000013 00000000 8bf59811 8bf59c11
[<7f0f8020>] (spi_rx_thread [nrc]) from [<8004f198>] (kthread+0xdc/0xf4)
[<8004f198>] (kthread) from [<8000f528>] (ret_from_fork+0x14/0x2c)
Code: e88d5000 eb47379c e3a00064 eb3e13c2 (e7f001f2)
---[ end trace 38c7bbdfb977dcee ]---

 

Regards,

Steven Yu

Outcomes