AnsweredAssumed Answered

Linux kernel sometimes lock for a few instants

Question asked by Leonardo Prates on Mar 5, 2015
Latest reply on Mar 12, 2015 by Leonardo Prates

I have a custom board with IMX6Q and all works good. In this board I have an external watchdog that resets the board if your input pin doesn't toggle in less than 1.6 seconds. Sometimes just after linux starts the board reboot (not always, 1 time in each 30 boots). I have looked with a scope and when this happens the driver that toggle the pin locks for more than 1.6s and my WDT reboots the board. But this lock doesn't occur only in that device driver, I have for example a led associated with kernel heartbeat function and this led locks too at same time. If I disconnect WDT from RST line I can see that when linux boot with this issue the kernel locks for 3 or 4 seconds and remains locking in aleatory way in the time until I reboot the board, but if Linux boots without the issue this never happens. No error message occurs at boot in any situation.

 

 

In resume: if board boots with problem, sometimes some drivers lock for a few seconds, without any warning or error message. After lock, kernel continue as if nothing had happened.

                  if board boots without problem, I can't see any kind of locking.

 

This happens only if CPU is in idle condition. If board boots wtih problem and I put some program to run I can't see lock anymore while program is running. If I stop the program, the lock starts again.

 

My kernel is 3.10.17 from Freescale made with Yocto and the kernel preemption is enable.

 

Thanks for any help,

 

Leonardo

Outcomes