INFO: task nvmap-bz:45 blocked for more than 80 seconds - Jetson TK1

Hi,
I am working on Jetson TK1,L4T version is R21.3. I open the kernel config CONFIG_DETECT_HUNG_TASK for debuging my custom driver module. Because the system would hung up when i runing app with my driver.
But after i booting the new compiled kernel, i get errors before i do anything(insmod my driver or start some app):

ubuntu@tegra-ubuntu:~$ [  200.056259] INFO: task nvmap-bz:45 blocked for more than 80 seconds.
[  200.062879] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
[  200.070880] nvmap-bz        D c08b49c0     0    45      2 0x00000000
[  200.077899] [<c08b49c0>] (__schedule+0x3c4/0x764) from [<c009b334>] (kthread+0xbc/0xe4)
[  200.086239] [<c009b334>] (kthread+0xbc/0xe4) from [<c000f358>] (ret_from_fork+0x14/0x20)
[  200.100313] Backtrace for cpu 0 (current):
[  200.104986] CPU: 0 PID: 48 Comm: khungtaskd Not tainted 3.10.40-gd93729d-dirty #3
[  200.113029] [<c001723c>] (unwind_backtrace+0x0/0x140) from [<c00136f4>] (show_stack+0x18/0x1c)
[  200.122066] [<c00136f4>] (show_stack+0x18/0x1c) from [<c0015f0c>] (smp_send_all_cpu_backtrace+0x78/0xf4)
[  200.132343] [<c0015f0c>] (smp_send_all_cpu_backtrace+0x78/0xf4) from [<c00e55d0>] (check_hung_uninterruptible_tasks+0x33c/0x354)
[  200.144628] [<c00e55d0>] (check_hung_uninterruptible_tasks+0x33c/0x354) from [<c00e563c>] (watchdog+0x54/0x58)
[  200.155401] [<c00e563c>] (watchdog+0x54/0x58) from [<c009b358>] (kthread+0xe0/0xe4)
[  200.163379] [<c009b358>] (kthread+0xe0/0xe4) from [<c000f358>] (ret_from_fork+0x14/0x20)
[  200.173732] 
[  200.173732] sending IPI to all other CPUs:
[  200.180001] Kernel panic - not syncing: hung_task: blocked tasks
[  200.186011] CPU: 0 PID: 48 Comm: khungtaskd Not tainted 3.10.40-gd93729d-dirty #3
[  200.193532] [<c001723c>] (unwind_backtrace+0x0/0x140) from [<c00136f4>] (show_stack+0x18/0x1c)
[  200.202151] [<c00136f4>] (show_stack+0x18/0x1c) from [<c08b2120>] (panic+0xa0/0x20c)
[  200.209904] [<c08b2120>] (panic+0xa0/0x20c) from [<c00e55dc>] (check_hung_uninterruptible_tasks+0x348/0x354)
[  200.219723] [<c00e55dc>] (check_hung_uninterruptible_tasks+0x348/0x354) from [<c00e563c>] (watchdog+0x54/0x58)
[  200.229718] [<c00e563c>] (watchdog+0x54/0x58) from [<c009b358>] (kthread+0xe0/0xe4)
[  200.237387] [<c009b358>] (kthread+0xe0/0xe4) from [<c000f358>] (ret_from_fork+0x14/0x20)

Then, i found the nvmap-bz task and disable CONFIG_TEGRA_NVMAP. After that, my driver works fine.

Is there a bug in the nvmap?

I would say there isn’t enough information to make any conclusion.

Since the issue only started when your driver was loaded, I would start by looking for blocks of code in your driver which might in some way prevent code outside of your own driver from executing under some circumstances. In reality the error messages above do not say nvmap failed, the messages say that something prevented nvmap from running.

How complicated is your driver?

Thanks for your reply!

I will check.

The issue is fixed and will be available in the next release.

Hi,

Testing Bluetooth file transfer,using Ubuntu 14.04 GUI:

While transferring the file from Jetson tk1 to paired device using GUI, system hangs/shows the following message:

[ 180.929683] INFO: rcu_preempt detected stalls on CPUs/tasks:
[ 180.935342] 0: (2 GPs behind) idle=397/1/0 softirq=18166/18167
[ 180.941332] (detected by 2, t=21002 jiffies, g=6799, c=6798, q=90)

[ 215.669368] BUG: soft lockup - CPU#2 stuck for 22s! [nvmap-bz:49]
[ 271.669368] BUG: soft lockup - CPU#2 stuck for 23s! [nvmap-bz:49]

Test conducted with the following:

echo 0 > /sys/devices/system/cpu/cpuquiet/tegra_cpuquiet/enable
echo G > /sys/kernel/cluster/active
echo N > /sys/module/cpuidle/parameters/power_down_in_idle

echo 1 > /sys/devices/system/cpu/cpu1/online
echo 1 > /sys/devices/system/cpu/cpu2/online
echo 1 > /sys/devices/system/cpu/cpu3/online

echo “performance” > /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
echo “performance” > /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
echo “performance” > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
echo “performance” > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

cat /sys/devices/system/cpu/online

Please do the needful.