Hi, If have created an cape for which both CAN interfaces are used. They both work as intended while connected to an bus but if I disconnect one of them the kernel process interrupt irq/42-can0 or irq/43-can1 runs at approx 50% cpu utilization each. Disconnecting both makes the system almost none responding.
Here is from TOP: PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 16755 root -51 0 0 0 0 S 53.9 0.0 27:49.78 irq/42-can0 uname -a Linux beaglebone 4.14.79-ti-rt-r84 #1 SMP PREEMPT RT Tue Nov 13 20:33:45 UTC 2018 armv7l GNU/Linux Each CAN interface are initilized using /sbin/ip link set can0 type can bitrate 500000 And the issues happens instantly if I try cansend canX <sid>#<data> on the busses. I have tried /sbin/ip link set can0 type can bitrate 500000 restart-ms 100 but it did not help. As far I know, the CPU usage might be valid since the CAN bus standard specs that it should retry until success. However, if I try sending alot of packages: cangen can0 -g 5 -I 42A -L 1 -v can1 42A#E0 can1 42A#BF can1 42A#9D can1 42A#8A can1 42A#8D can1 42A#74 can1 42A#BB can1 42A#ED can1 42A#4B can1 42A#C5 can1 42A#86 write: No buffer space available. But the irq/42-can0 still utilize 50% usage and does not die. If I stop the interface ifconfig can0 down the irq/42-can0 process disappears but that would require me to create somekind of user space program to check the state and start/stop until reconnected and during this, the process will stlil eat up most of the BBB's CPU power due to the -51 priority thus not optimal. Dmesg shows this after the Non buffer space available: [536657.476659] [<c0dbc52c>] (do_page_fault) from [<c0101370>] (do_PrefetchAbort+0x58/0xd0) [536657.476667] [<c0101370>] (do_PrefetchAbort) from [<c0dbbf8c>] (ret_from_exception+0x0/0x14) [536657.476671] Exception stack(0xd8fadfb0 to 0xd8fadff8) [536657.476676] dfa0: 00000000 b6eda0b4 00000000 b6e3e051 [536657.476684] dfc0: 00000001 00000000 b6ed7798 00000001 b6eda0b4 00000001 00484000 00000000 [536657.476692] dfe0: b6e15109 becd2530 b6e14eeb b6e3e050 00070030 ffffffff [536696.690295] INFO: rcu_preempt detected stalls on CPUs/tasks: [536696.690313] Tasks blocked on level-0 rcu_node (CPUs 0-0): P16900 [536696.690322] (detected by 0, t=5252 jiffies, g=58839897, c=58839896, q=5053) [536696.690339] cansend R running task 0 16900 7599 0x00000000 [536696.690397] [<c0db68d4>] (__schedule) from [<c0db7410>] (preempt_schedule_irq+0x58/0x84) [536696.690413] [<c0db7410>] (preempt_schedule_irq) from [<c0dbb964>] (svc_preempt+0x8/0x2c) [536696.690435] [<c0dbb964>] (svc_preempt) from [<c0287a04>] (filemap_map_pages+0x1ec/0x38c) [536696.690449] [<c0287a04>] (filemap_map_pages) from [<c02c83a0>] (handle_mm_fault+0x584/0xc30) [536696.690461] [<c02c83a0>] (handle_mm_fault) from [<c0dbc52c>] (do_page_fault+0x34c/0x430) [536696.690473] [<c0dbc52c>] (do_page_fault) from [<c0101370>] (do_PrefetchAbort+0x58/0xd0) [536696.690484] [<c0101370>] (do_PrefetchAbort) from [<c0dbbf8c>] (ret_from_exception+0x0/0x14) [536696.690489] Exception stack(0xd8fadfb0 to 0xd8fadff8) [536696.690497] dfa0: 00000000 00000000 00000000 ffffffff [536696.690506] dfc0: 00000001 00000000 b6ed7798 00000001 b6eda0b4 00000001 00484000 00000000 [536696.690513] dfe0: b6e15109 becd2530 b6e14ef5 b6e606b8 60070030 ffffffff Anyone know a good way fix this cpu utilization? /Kusk -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/beagleboard/86315028-b3d2-4013-9e16-12d0eacbee24%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
