2011-04-14 10:12:55     kernel BUG at kernel/workqueue.c:399! in 2010R5 on BF-561 SMP

Document created by Aaronwu Employee on Aug 26, 2013
Version 1Show Document
  • View in full screen mode

2011-04-14 10:12:55     kernel BUG at kernel/workqueue.c:399! in 2010R5 on BF-561 SMP

Alf Nilsson (SWEDEN)

Message: 99845   

 

Hi all,

 

I am getting the following dump when running our application on custom hardware.

 

But I have found a way to at least reproduce the same BUG code on the BF-561 EZKIT, which is displayed below:

 

------------[ cut here ]------------

kernel BUG at kernel/workqueue.c:399!

Kernel panic - not syncing: BUG()

Hardware Trace:

   0 Target : <0x000045c8> { _trap_c + 0x0 }

     Source : <0x0000affc> { _exception_to_level5 + 0xb4 } JUMP.L

   1 Target : <0x0000afca> { _exception_to_level5 + 0x82 }

     Source : <0x0000afc6> { _exception_to_level5 + 0x7e } IF !CC JUMP pcrel

   2 Target : <0x0000af48> { _exception_to_level5 + 0x0 }

     Source : <0x0000adec> { _bfin_return_from_exception + 0x20 } RTX

   3 Target : <0x0000adcc> { _bfin_return_from_exception + 0x0 }

     Source : <0x0000aea0> { _ex_trap_c + 0x84 } JUMP.S

   4 Target : <0x0000ae34> { _ex_trap_c + 0x18 }

     Source : <0x0000ae30> { _ex_trap_c + 0x14 } IF !CC JUMP pcrel

   5 Target : <0x0000ae1c> { _ex_trap_c + 0x0 }

     Source : <0x0000b11c> { _trap + 0xb4 } JUMP (P4)

   6 Target : <0x0000b0dc> { _trap + 0x74 }

     Source : <0x0000b0d8> { _trap + 0x70 } IF !CC JUMP pcrel

   7 Target : <0x0000b0c2> { _trap + 0x5a }

     Source : <0x0000b0be> { _trap + 0x56 } IF CC JUMP pcrel

   8 Target : <0x0000b0ae> { _trap + 0x46 }

     Source : <0x0000b09c> { _trap + 0x34 } JUMP.S

   9 Target : <0x0000b068> { _trap + 0x0 }

      FAULT : <0x00027c88> { _run_workqueue + 0xd4 } BUG

     Source : <0x00027c2c> { _run_workqueue + 0x78 } IF !CC JUMP pcrel

  10 Target : <0x00027c24> { _run_workqueue + 0x70 }

     Source : <0x0000cdfc> { ___raw_uncached_fetch_asm + 0x24 } RTS

  11 Target : <0x0000cdd8> { ___raw_uncached_fetch_asm + 0x0 }

     Source : <0x00027c20> { _run_workqueue + 0x6c } JUMP.L

  12 Target : <0x00027c02> { _run_workqueue + 0x4e }

     Source : <0x0000cac6> { ___raw_spin_unlock_asm + 0x16 } RTS

  13 Target : <0x0000cac4> { ___raw_spin_unlock_asm + 0x14 }

     Source : <0x0000c906> { _put_core_lock + 0x1a } RTS

  14 Target : <0x0000c8ec> { _put_core_lock + 0x0 }

     Source : <0x0000ca36> { _end_lock_coherent + 0x20 } JUMP.S

  15 Target : <0x0000ca16> { _end_lock_coherent + 0x0 }

     Source : <0x0000cac0> { ___raw_spin_unlock_asm + 0x10 } CALL pcrel

Stack info:

SP: [0x0204fda0] <0x0204fda0> /* kernel dynamic memory (maybe user-space) */

Memory from 0x0204fda0 to 02050000

0204fda0:[00143f44] 00118e66  0204fe80  00143f44  00176b46  00176b46  00176b46  0204fdd0

0204fdc0: 00004a00  0204fe80  00008008  00000000  0000003f  0000001f  02824cfc  00000000

0204fde0: 00000001  02824d08  0083718c  00000000  0000c9aa  fffffffe  0204fe30  0000e9d0

0204fe00: 00000001  feb00000  02824c2c  00000000  02824c00  02824c2c  00000001  feb00000

0204fe20: 02824c98  00000000  00000000  0000007f  00000001  00119e74  00000fff  00000000

0204fe40: 000ad2ca  000ad2ca  00000fff  00000000  00000000  0000000b  0000b000  00172000

0204fe60: ffe02014  00008008  00002021  00839f64  ffe05000  0204fea8  00011c16  00000480

0204fe80: 00000480  00008008  00002021  00000000  0204ff5c  00000480  00027c88  00027c24

0204fea0: 00849f60  02002040  02a404bd  0009feb4  02a404bc  0009feb4  00000000  00000000

0204fec0: 00000013  00000000  00000013  00000000  00000000  00000000  00000000  00000000

0204fee0: 00000000  00000000  00000000  00000000  00000000  00000000  00000000  00000000

0204ff00: 02a4a2e8  02a49949  00000000  0083718c  00000000  000af54c  02824cb8  00849f60

0204ff20: 00839f60  00172008  02824cb8  02824ca0  00172000  0204e000  00839f64  ffe05000

0204ff40: 00839f60  0000ffff  fffffffc  00849f60  00849f60  02824ca0  00000006  00001027

0204ff60: 0204e000  0204e000  0204e000  00000000  00027d12  00839f60  00027cd4  00000000

0204ff80: 00839f6c  0204ff9c  00839f64  00000000  00001027  0204e000  0204e000  00000000

0204ffa0: 02039060  0002b060  0204ffa8  0204ffa8 <0002ad3e> 0202bf18  00839f60  00000000

0204ffc0: 00000000  00000000  00000000  0002ace4  00000000  00000000  00000000  0204ffdc

0204ffe0: 0204ffdc <0000161e> 00000000  00000000  00000000  00000000  ffffffff  00000006

Return addresses in stack:

    address : <0x0002ad3e> { _kthread + 0x5a }

    address : <0x0000161e> { _kernel_thread_helper + 0x6 }

CPU1: stopping

Hardware Trace:

   0 Target : <0x00118de4> { _dump_stack + 0x0 }

     Source : <0x0000c2ba> { _ipi_handler_int1 + 0x112 } CALL pcrel

   1 Target : <0x0000c2ba> { _ipi_handler_int1 + 0x112 }

     Source : <0x00118f0c> { _printk + 0x14 } RTS

   2 Target : <0x00118f08> { _printk + 0x10 }

     Source : <0x0001a14a> { _vprintk + 0x1b2 } RTS

   3 Target : <0x0001a13e> { _vprintk + 0x1a6 }

     Source : <0x0001a112> { _vprintk + 0x17a } IF CC JUMP pcrel

   4 Target : <0x0001a10a> { _vprintk + 0x172 }

     Source : <0x0001a2c2> { _vprintk + 0x32a } JUMP.S

   5 Target : <0x0001a2c2> { _vprintk + 0x32a }

     Source : <0x00019d02> { _release_console_sem + 0x21e } RTS

   6 Target : <0x00019cbc> { _release_console_sem + 0x1d8 }

     Source : <0x0011a83c> { __raw_spin_unlock_irqrestore + 0x44 } RTS

   7 Target : <0x0011a836> { __raw_spin_unlock_irqrestore + 0x3e }

     Source : <0x0011a80a> { __raw_spin_unlock_irqrestore + 0x12 } IF CC JUMP pcrel (BP)

   8 Target : <0x0011a804> { __raw_spin_unlock_irqrestore + 0xc }

     Source : <0x0000cac6> { ___raw_spin_unlock_asm + 0x16 } RTS

   9 Target : <0x0000cac4> { ___raw_spin_unlock_asm + 0x14 }

     Source : <0x0000c906> { _put_core_lock + 0x1a } RTS

  10 Target : <0x0000c8ec> { _put_core_lock + 0x0 }

     Source : <0x0000ca36> { _end_lock_coherent + 0x20 } JUMP.S

  11 Target : <0x0000ca16> { _end_lock_coherent + 0x0 }

     Source : <0x0000cac0> { ___raw_spin_unlock_asm + 0x10 } CALL pcrel

  12 Target : <0x0000cab8> { ___raw_spin_unlock_asm + 0x8 }

     Source : <0x0000c8b8> { _get_core_lock + 0x40 } RTS

  13 Target : <0x0000c89c> { _get_core_lock + 0x24 }

     Source : <0x0000c88c> { _get_core_lock + 0x14 } IF CC JUMP pcrel

  14 Target : <0x0000c878> { _get_core_lock + 0x0 }

     Source : <0x0000cab4> { ___raw_spin_unlock_asm + 0x4 } JUMP.L

  15 Target : <0x0000cab0> { ___raw_spin_unlock_asm + 0x0 }

     Source : <0x0011a800> { __raw_spin_unlock_irqrestore + 0x8 } CALL pcrel

Stack info:

SP: [0x0204be40] <0x0204be40> /* kernel dynamic memory */

Memory from 0x0204be40 to 0204c000

0204be40:[0000003f] 0000c2be  00000002  0000003f  0017d268  00000001  0000001f  0017026c

0204be60:<0003b640> 02008ae0  0017d264  0017b430  00000046  00000000  00000000  00000046

0204be80: 0000b5e2  0003cd78  00185940  0003cd48  00187140  00000046  00000000  0000001f

0204bea0: 00000000  0001e8b2  0017b430  00000006 <00004b1c> 007b0c08  00000046  000a0118

0204bec0: 02b126d8  000a00f8  0000b5e2  ffc00014  ffe05000  0204a008  00001e64  00000000

0204bee0: 00000000  00000000  00001eac  00008090  0000c000  00000000  02a1c000  02b837ae

0204bf00: 00001eac  00001e78  00000007  02002060  02b126e3  000a0118  02b126d8  000a00f8

0204bf20: 00000000  00000000  00000013  00000000  00000013  00000000  00000000  00000000

0204bf40: 00000000  00000000  00000000  00000000  00000000  00000000  00000000  00000000

0204bf60: 00000000  00000004  00000000  02be5e40  028e353c  02be5fea  0204c000  0017026c

0204bf80: 00001e64  ffe05000  0017b430  00172070  0000000e  0204a000  0204a008  00001e64

0204bfa0: 0000001f  00000000  00000004  0000001f  00172000  0000ffff  0000ffff  0204a000

0204bfc0: 00000006  0204a008  00001e64  0000001f <00001e4a> 001172ae  00172070  ffe05000

0204bfe0: 0204c000  0019d1ea  00000000  00000000  00000000  00000000  00000000  00000000

Return addresses in stack:

    address : <0x0003b640> { _handle_IRQ_event + 0x5c }

    address : <0x00004b1c> { _asm_do_IRQ + 0xb0 }

    address : <0x00001e4a> { _cpu_idle + 0x5a }

------------------------

 

What I do is build 2010R5 with SMP support for the BF-561 EZKIT.

 

The do to following:

 

cd /mnt

 

ls -lR / > temp

 

cat temp

 

cat temp ( a few times, then it will go boom )

 

Sometimes it crashes on the first time I write cat, but it always crashes before I have done cat 10 times.

 

I always assume that I am the main cause of the problem, but here I do not feel I am doing so much wrong.

 

Any suggestions?

 

Cheers,

 

//Affe

QuoteReplyEditDelete

 

 

2011-04-15 04:32:39     Re: kernel BUG at kernel/workqueue.c:399! in 2010R5 on BF-561 SMP

Aaron Wu (CHINA)

Message: 99880   

 

Looks like it's a failure in the tty driver caused by a bug in Linux workqueue, it's already filed for a solution from the upstream, for details visit https://blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=6465. Actually this has nothing to do with the SMP thing. I can reproduce the problem you reported on a BF537 board.

QuoteReplyEditDelete

 

 

2011-04-15 08:49:02     Re: kernel BUG at kernel/workqueue.c:399! in 2010R5 on BF-561 SMP

Alf Nilsson (SWEDEN)

Message: 99888   

 

I have tried both with and without SMP active, and have only managed to reproduce it when using SMP. But I will do further tests to see if I can get the non-SMP version to report the error.

QuoteReplyEditDelete

 

 

2011-04-15 16:14:58     Re: kernel BUG at kernel/workqueue.c:399! in 2010R5 on BF-561 SMP

Mike Frysinger (UNITED STATES)

Message: 99895   

 

if you could disqualify the serial port as the issue, that'd be good.  i.e. redirect the output of cat into /dev/null rather than writing it to the serial port.  if you have a network connection, see if you have problems doing it over a telnet session.

 

if that works, do something on the console like:

hexdump /dev/urandom

Attachments

    Outcomes