Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFCOMM, patchram results in HARDLOCK crash #7

Open
zimbob10k opened this issue Sep 2, 2016 · 1 comment
Open

RFCOMM, patchram results in HARDLOCK crash #7

zimbob10k opened this issue Sep 2, 2016 · 1 comment

Comments

@zimbob10k
Copy link

zimbob10k commented Sep 2, 2016

Hello,

Recently - (and on behalf of eers 4.0 and Atlants Embedded), we have been using the FriendlyArm kernel, but it suffered from a stacktrace and CPU hardlock from IRQs when using patchram, RFCOMM and HCI (if you want BLE - which we did). Attached to this ticket is our conglomeration of backport patches.

With copious amounts of debugging information, you will receive a stack trace which looks like the following for CPU hardlocks/softlocks etc... while using patchram to load the AP6212 firmware (that runs in the background using & and --enable_hci & --baudrate 112500), and for a "random" period of time, it may or may not receive BT connections (we were also broadcasting BLE beacons). This was realized because the amba tty and the tty itself were struggling with spinlocks. I also backported some barrier patches from Linus, and l2comm segfaults which were discovered at the sametime during "fixing".

Here is the stacktrace:

[  431.064000]                                                                                           
[  431.064000] =============================================                                             
[  431.068000] [ INFO: possible recursive locking detected ]                                             
[  431.076000] 3.4.39-s5p4418 #9 Not tainted                                                             
[  431.080000] ---------------------------------------------                                             
[  431.084000] swapper/1/0 is trying to acquire lock:                                                    
[  431.088000]  (&port_lock_key){-.-...}, at: [<c026a930>] uart_write+0x60/0xf4                          
[  431.096000]                                                                                           
[  431.096000] but task is already holding lock:                                                         
[  431.100000]  (&port_lock_key){-.-...}, at: [<c0271810>] pl011_int+0x24/0x518                          
[  431.108000]                                                                                           
[  431.108000] other info that might help us debug this:                                                 
[  431.116000]  Possible unsafe locking scenario:                                                        
[  431.116000]                                                                                           
[  431.120000]        CPU0                                                                               
[  431.124000]        ----                                                                               
[  431.124000]   lock(&port_lock_key);                                                                   
[  431.128000]   lock(&port_lock_key);                                                                   
[  431.132000]                                                                                           
[  431.132000]  *** DEADLOCK ***                                                                         
[  431.132000]                                                                                           
[  431.140000]  May be due to missing lock nesting notation                                              
[  431.140000]                                                                                           
[  431.144000] 1 lock held by swapper/1/0:                                                               
[  431.148000]  #0:  (&port_lock_key){-.-...}, at: [<c0271810>] pl011_int+0x24/0x518                     
[  431.156000]                                                                                           
[  431.156000] stack backtrace:                                                                          
[  431.160000] [<c0015904>] (unwind_backtrace+0x0/0x124) from [<c04d547c>] (dump_stack+0x20/0x24)        
[  431.168000] [<c04d547c>] (dump_stack+0x20/0x24) from [<c007a75c>] (__lock_acquire+0x504/0x1740)       
[  431.180000] [<c007a75c>] (__lock_acquire+0x504/0x1740) from [<c007c120>] (lock_acquire+0x118/0x13c)   
[  431.188000] [<c007c120>] (lock_acquire+0x118/0x13c) from [<c04dc550>] (_raw_spin_lock_irqsave+0x54/0x)
[  431.196000] [<c04dc550>] (_raw_spin_lock_irqsave+0x54/0x68) from [<c026a930>] (uart_write+0x60/0xf4)  
[  431.208000] [<c026a930>] (uart_write+0x60/0xf4) from [<c0378efc>] (hci_uart_tx_wakeup+0xa8/0x15c)     
[  431.216000] [<c0378efc>] (hci_uart_tx_wakeup+0xa8/0x15c) from [<c037901c>] (hci_uart_tty_wakeup+0x6c/)
[  431.224000] [<c037901c>] (hci_uart_tty_wakeup+0x6c/0x78) from [<c0250a78>] (tty_wakeup+0x48/0x68)     
[  431.232000] [<c0250a78>] (tty_wakeup+0x48/0x68) from [<c026b570>] (uart_write_wakeup+0x2c/0x30)       
[  431.244000] [<c026b570>] (uart_write_wakeup+0x2c/0x30) from [<c0271b28>] (pl011_int+0x33c/0x518)      
[  431.252000] [<c0271b28>] (pl011_int+0x33c/0x518) from [<c00a53bc>] (handle_irq_event_percpu+0xbc/0x28)
[  431.260000] [<c00a53bc>] (handle_irq_event_percpu+0xbc/0x280) from [<c00a55cc>] (handle_irq_event+0x4)
[  431.272000] [<c00a55cc>] (handle_irq_event+0x4c/0x6c) from [<c00a82cc>] (handle_level_irq+0xfc/0x118) 
[  431.280000] [<c00a82cc>] (handle_level_irq+0xfc/0x118) from [<c001e084>] (__vic_handler+0x19c/0x210)  
[  431.288000] [<c001e084>] (__vic_handler+0x19c/0x210) from [<c00a4cb4>] (generic_handle_irq+0x30/0x40) 
[  431.300000] [<c00a4cb4>] (generic_handle_irq+0x30/0x40) from [<c000f368>] (handle_IRQ+0x8c/0xc0)      
[  431.308000] [<c000f368>] (handle_IRQ+0x8c/0xc0) from [<c000858c>] (gic_handle_irq+0x4c/0x6c)          
[  431.316000] [<c000858c>] (gic_handle_irq+0x4c/0x6c) from [<c000e544>] (__irq_svc+0x44/0x78)           
[  431.324000] Exception stack(0xef0a9e88 to 0xef0a9ed0)                                                 
[  431.328000] 9e80:                   00000001 00000000 00000000 ef085280 ef0a8010 c074cc88             
[  431.336000] 9ea0: ef0a8000 00000082 c07c7300 413fc090 00000000 ef0a9f0c ef0a9ea0 ef0a9ed0             
[  431.344000] 9ec0: c0079f1c c0038420 60000113 ffffffff                                                 
[  431.352000] [<c000e544>] (__irq_svc+0x44/0x78) from [<c0038420>] (__do_softirq+0x74/0x248)            
[  431.360000] [<c0038420>] (__do_softirq+0x74/0x248) from [<c0038af0>] (irq_exit+0x64/0x78)             
[  431.368000] [<c0038af0>] (irq_exit+0x64/0x78) from [<c000f370>] (handle_IRQ+0x94/0xc0)                
[  431.376000] [<c000f370>] (handle_IRQ+0x94/0xc0) from [<c000858c>] (gic_handle_irq+0x4c/0x6c)          
[  431.384000] [<c000858c>] (gic_handle_irq+0x4c/0x6c) from [<c000e544>] (__irq_svc+0x44/0x78)           
[  431.392000] Exception stack(0xef0a9f70 to 0xef0a9fb8)                                                 
[  431.396000] 9f60:                                     00000001 00000004 00000000 ef085280             
[  431.404000] 9f80: ef0a8008 ef0a8000 10c0387d c079ddac 4000406a 413fc090 00000000 ef0a9fc4             
[  431.412000] 9fa0: ef0a9f88 ef0a9fb8 c0079f54 c000f730 20000013 ffffffff                               
[  431.420000] [<c000e544>] (__irq_svc+0x44/0x78) from [<c000f730>] (default_idle+0x38/0x40)             
[  431.428000] [<c000f730>] (default_idle+0x38/0x40) from [<c000fb18>] (cpu_idle+0xbc/0x108)             
[  431.436000] [<c000fb18>] (cpu_idle+0xbc/0x108) from [<c04d28cc>] (secondary_start_kernel+0x13c/0x164) 
[  431.444000] [<c04d28cc>] (secondary_start_kernel+0x13c/0x164) from [<40008168>] (0x40008168)          
[  432.180000] nxp_cpu_pll_change_frequency 1 800000000                                                  
[  432.188000] PLL.1, 800000(real 800000 Khz, P=3 ,M=200, S=1)                                           
[  432.192000] core_pll_change [PLL 1][P:3,M:200,S:1,K:0]                                                
[  432.196000]  set rate 800000:800000khz                                                                
[  444.088000] ------------[ cut here ]------------                                                      
[  444.092000] WARNING: at kernel/watchdog.c:237 watchdog_timer_fn+0x12c/0x300()                         
[  444.100000] Watchdog detected hard LOCKUP on cpu 1                                                    
[  444.104000] Modules linked in:                                                                        
[  444.108000] [<c0015904>] (unwind_backtrace+0x0/0x124) from [<c04d547c>] (dump_stack+0x20/0x24)        
[  444.116000] [<c04d547c>] (dump_stack+0x20/0x24) from [<c00317e0>] (warn_slowpath_common+0x5c/0x74)    
[  444.124000] [<c00317e0>] (warn_slowpath_common+0x5c/0x74) from [<c0031838>] (warn_slowpath_fmt+0x40/0)
[  444.136000] [<c0031838>] (warn_slowpath_fmt+0x40/0x48) from [<c00a4784>] (watchdog_timer_fn+0x12c/0x3)
[  444.144000] [<c00a4784>] (watchdog_timer_fn+0x12c/0x300) from [<c0056298>] (__run_hrtimer+0x148/0x23c)
[  444.156000] [<c0056298>] (__run_hrtimer+0x148/0x23c) from [<c0056b5c>] (hrtimer_interrupt+0x12c/0x280)
[  444.164000] [<c0056b5c>] (hrtimer_interrupt+0x12c/0x280) from [<c001468c>] (twd_handler+0x3c/0x48)    
[  444.172000] [<c001468c>] (twd_handler+0x3c/0x48) from [<c00a8720>] (handle_percpu_devid_irq+0xfc/0x19)
[  444.180000] [<c00a8720>] (handle_percpu_devid_irq+0xfc/0x198) from [<c00a4cb4>] (generic_handle_irq+0)
[  444.192000] [<c00a4cb4>] (generic_handle_irq+0x30/0x40) from [<c000f368>] (handle_IRQ+0x8c/0xc0)      
[  444.200000] [<c000f368>] (handle_IRQ+0x8c/0xc0) from [<c000858c>] (gic_handle_irq+0x4c/0x6c)          
[  444.208000] [<c000858c>] (gic_handle_irq+0x4c/0x6c) from [<c000e544>] (__irq_svc+0x44/0x78)           
[  444.216000] Exception stack(0xeeac9d90 to 0xeeac9dd8)                                                 
[  444.224000] 9d80:                                     00000004 00000004 00000008 00000001             
[  444.232000] 9da0: eeac9e0c c1574cc0 c1574cc0 00000001 c1574cc8 00000001 00e3f000 eeac9e04             
[  444.240000] 9dc0: 00000002 eeac9dd8 c001b744 c0081980 20000013 ffffffff                               
[  444.244000] [<c000e544>] (__irq_svc+0x44/0x78) from [<c0081980>] (generic_exec_single+0x78/0x94)      
[  444.256000] [<c0081980>] (generic_exec_single+0x78/0x94) from [<c0081b18>] (smp_call_function_single+)
[  444.264000] [<c0081b18>] (smp_call_function_single+0x17c/0x1d0) from [<c00147d4>] (twd_cpufreq_transi)
[  444.276000] [<c00147d4>] (twd_cpufreq_transition+0x38/0x44) from [<c0057f10>] (notifier_call_chain+0x)
[  444.284000] [<c0057f10>] (notifier_call_chain+0x50/0x78) from [<c0058484>] (__srcu_notifier_call_chai)
[  444.296000] [<c0058484>] (__srcu_notifier_call_chain+0x80/0xb4) from [<c00584e0>] (srcu_notifier_call)
[  444.308000] [<c00584e0>] (srcu_notifier_call_chain+0x28/0x30) from [<c0382ff0>] (cpufreq_notify_trans)
[  444.316000] [<c0382ff0>] (cpufreq_notify_transition+0x224/0x270) from [<c038ae28>] (nxp_cpufreq_chang)
[  444.328000] [<c038ae28>] (nxp_cpufreq_change_frequency+0x1c8/0x214) from [<c038b3bc>] (nxp_cpufreq_pr)
[  444.340000] [<c038b3bc>] (nxp_cpufreq_process+0xb0/0xf4) from [<c0051d20>] (kthread+0x94/0xa0)        
[  444.348000] [<c0051d20>] (kthread+0x94/0xa0) from [<c000f600>] (kernel_thread_exit+0x0/0x8)           
[  444.356000] ---[ end trace 99094091ecaea73c ]---                                                      
[  456.088000] BUG: soft lockup - CPU#0 stuck for 22s! [cpufreq-update:66]                               
[  456.096000] Modules linked in:                                                                        
[  456.100000] irq event stamp: 3264                                                                     
[  456.100000] hardirqs last  enabled at (3263): [<c00ad940>] rcu_note_context_switch+0x210/0x2a0        
[  456.108000] hardirqs last disabled at (3264): [<c04dc58c>] _raw_spin_lock_irq+0x28/0x60               
[  456.120000] softirqs last  enabled at (3250): [<c00385d0>] __do_softirq+0x224/0x248                   
[  456.124000] softirqs last disabled at (3231): [<c0038af0>] irq_exit+0x64/0x78                         
[  456.132000]                                                                                           
[  456.136000] Pid: 66, comm:       cpufreq-update                                                       
[  456.140000] CPU: 0    Tainted: G        W     (3.4.39-s5p4418 #9)                                     
[  456.144000] PC is at generic_exec_single+0x78/0x94                                                    
[  456.148000] LR is at gic_raise_softirq+0x3c/0x78                                                      
[  456.156000] pc : [<c0081980>]    lr : [<c001b744>]    psr: 20000013                                   
[  456.156000] sp : eeac9dd8  ip : 00000002  fp : eeac9e04                                               
[  456.164000] r10: 00e3f000  r9 : 00000001  r8 : c1574cc8                                               
[  456.172000] r7 : 00000001  r6 : c1574cc0  r5 : c1574cc0  r4 : eeac9e0c                                
[  456.176000] r3 : 00000001  r2 : 00000008  r1 : 00000004  r0 : 00000004                                
[  456.184000] Flags: nzCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment kernel                       
[  456.192000] Control: 10c5387d  Table: 6e25c04a  DAC: 00000015                                         
[  456.196000]                                                                                           
[  456.196000] PC: 0xc0081900:                                                                           
[  456.200000] 1900  e89da830 c05e5d72 e1a0c00d e92ddff8 e24cb004 e52de004 e8bd4000 e1a07000             
[  456.208000] 1920  e1a04001 e59f3068 e1a09002 e59f6064 e793a100 e086500a e2858008 e1a00008             
[  456.220000] 1940  eb116aed e5953004 e1a01000 e796600a e1a00008 e5854004 e5845000 e5843004             
[  456.228000] 1960  e5834000 eb116b59 e1550006 1a000001 e1a00007 ebfe4806 e3590000 089daff8             
[  456.236000] 1980  e1d431b0 e3130001 0a000000 eafffffb e89daff8 c074cc88 c0735cc0 e1a0c00d             
[  456.244000] 19a0  e92ddff0 e24cb004 e24dd01c e52de004 e8bd4000 e1a05000 e1a06001 e1a07002             
[  456.252000] 19c0  e3a01000 e3a02014 e24b0040 e1a08003 eb069f6a e3a00001 ebff760b e59f916c             
[  456.260000] 19e0  eb06e23b e3500000 e280301f e5992000 a1a03000 e1a032c3 e1a04000 e7923103             
[  456.268000]                                                                                           
[  456.268000] LR: 0xc001b6c4:                                                                           
[  456.272000] b6c4  ea000005 e59f102c e3a03000 e59f202c e1a00004 eb023437 e3a01003 e1a00004             
[  456.280000] b6e4  ebffcf2c e595101c e1a00004 eb0230a2 e3a00000 e89da830 c0752df8 c00a8624             
[  456.288000] b704  c00a8460 e1a0c00d e92ddbf0 e24cb004 e52de004 e8bd4000 e3a05000 e1a07000             
[  456.296000] b724  e59f6048 e1a04001 e59f8044 e3e00000 e2802001 e3a01004 e1a00007 eb0833ce             
[  456.304000] b744  e5963000 e1530000 c7983100 c3a02001 c1855312 cafffff5 f57ff04f e59f3014             
[  456.312000] b764  e1844805 e5933000 e5834f00 e89dabf0 c074c314 c079dd40 c074bcc4 e1a0c00d             
[  456.320000] b784  e92dd8f0 e24cb004 e52de004 e8bd4000 e3a04000 e1a05000 e59f704c e2806c02             
[  456.332000] b7a4  f57ff04f e5973018 e3530000 0a000000 e12fff33 e3843020 e2844001 e3540010             
[  456.340000]                                                                                           
[  456.340000] SP: 0xeeac9d58:                                                                           
[  456.344000] 9d58  c1574cc8 00000001 eeac9d8c eeac9d70 c000858c c000f2e8 c0081980 20000013             
[  456.352000] 9d78  ffffffff eeac9dc4 eeac9e04 eeac9d90 c000e544 c000854c 00000004 00000004             
[  456.360000] 9d98  00000008 00000001 eeac9e0c c1574cc0 c1574cc0 00000001 c1574cc8 00000001             
[  456.368000] 9db8  00e3f000 eeac9e04 00000002 eeac9dd8 c001b744 c0081980 20000013 ffffffff             
[  456.376000] 9dd8  00000001 00000000 00000001 c0014698 00000000 00000001 c04df824 ffffffff             
[  456.384000] 9df8  eeac9e4c eeac9e08 c0081b18 c0081914 eeac9e2c c1574cc0 c1574cc0 c0014698             
[  456.392000] 9e18  00000000 00000001 00000000 ffffffff 00000000 00000001 eeac9f60 00000000             
[  456.400000] 9e38  eeac9f60 ffffffff eeac9e5c eeac9e50 c00147d4 c00819a8 eeac9e84 eeac9e60             
[  456.408000]                                                                                           
[  456.408000] FP: 0xeeac9d84:                                                                           
[  456.412000] 9d84  eeac9d90 c000e544 c000854c 00000004 00000004 00000008 00000001 eeac9e0c             
[  456.420000] 9da4  c1574cc0 c1574cc0 00000001 c1574cc8 00000001 00e3f000 eeac9e04 00000002             
[  456.428000] 9dc4  eeac9dd8 c001b744 c0081980 20000013 ffffffff 00000001 00000000 00000001             
[  456.436000] 9de4  c0014698 00000000 00000001 c04df824 ffffffff eeac9e4c eeac9e08 c0081b18             
[  456.448000] 9e04  c0081914 eeac9e2c c1574cc0 c1574cc0 c0014698 00000000 00000001 00000000             
[  456.456000] 9e24  ffffffff 00000000 00000001 eeac9f60 00000000 eeac9f60 ffffffff eeac9e5c             
[  456.464000] 9e44  eeac9e50 c00147d4 c00819a8 eeac9e84 eeac9e60 c0057f10 c00147a8 c0d51f50             
[  456.472000] 9e64  c0d51f9c c0d51ff0 00000001 00000001 eeac9f60 eeac9ecc eeac9e88 c0058484             
[  456.480000]                                                                                           
[  456.480000] R4: 0xeeac9d8c:                                                                           
[  456.484000] 9d8c  c000854c 00000004 00000004 00000008 00000001 eeac9e0c c1574cc0 c1574cc0             
[  456.492000] 9dac  00000001 c1574cc8 00000001 00e3f000 eeac9e04 00000002 eeac9dd8 c001b744             
[  456.500000] 9dcc  c0081980 20000013 ffffffff 00000001 00000000 00000001 c0014698 00000000             
[  456.508000] 9dec  00000001 c04df824 ffffffff eeac9e4c eeac9e08 c0081b18 c0081914 eeac9e2c             
[  456.516000] 9e0c  c1574cc0 c1574cc0 c0014698 00000000 00000001 00000000 ffffffff 00000000             
[  456.524000] 9e2c  00000001 eeac9f60 00000000 eeac9f60 ffffffff eeac9e5c eeac9e50 c00147d4             
[  456.532000] 9e4c  c00819a8 eeac9e84 eeac9e60 c0057f10 c00147a8 c0d51f50 c0d51f9c c0d51ff0             
[  456.540000] 9e6c  00000001 00000001 eeac9f60 eeac9ecc eeac9e88 c0058484 c0057ecc 00000000             
[  456.548000]                                                                                           
[  456.548000] R5: 0xc1574c40:                                                                           
[  456.556000] 4c40  00000000 00000000 00000000 00000000 c005dee8 c156a7d8 00000000 00000000             
[  456.564000] 4c60  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.572000] 4c80  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.580000] 4ca0  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.588000] 4cc0  eeac9e0c eeac9e0c 00a100a1 00000000 dead4ead ffffffff ffffffff c0cb8f34             
[  456.596000] 4ce0  c087dd20 00000000 c05f0bc8 00000000 00000000 00000000 00000000 00000000             
[  456.604000] 4d00  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.612000] 4d20  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.620000]                                                                                           
[  456.620000] R6: 0xc1574c40:                                                                           
[  456.624000] 4c40  00000000 00000000 00000000 00000000 c005dee8 c156a7d8 00000000 00000000             
[  456.632000] 4c60  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.640000] 4c80  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.648000] 4ca0  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.656000] 4cc0  eeac9e0c eeac9e0c 00a100a1 00000000 dead4ead ffffffff ffffffff c0cb8f34             
[  456.664000] 4ce0  c087dd20 00000000 c05f0bc8 00000000 00000000 00000000 00000000 00000000             
[  456.676000] 4d00  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.684000] 4d20  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.692000]                                                                                           
[  456.692000] R8: 0xc1574c48:                                                                           
[  456.696000] 4c48  00000000 00000000 c005dee8 c156a7d8 00000000 00000000 00000000 00000000             
[  456.704000] 4c68  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.712000] 4c88  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.720000] 4ca8  00000000 00000000 00000000 00000000 00000000 00000000 eeac9e0c eeac9e0c             
[  456.728000] 4cc8  00a100a1 00000000 dead4ead ffffffff ffffffff c0cb8f34 c087dd20 00000000             
[  456.736000] 4ce8  c05f0bc8 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.744000] 4d08  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  456.752000] 4d28  00000000 00000000 00000000 00000000 00000000 00000000 00000000 c1574d40             
[  456.760000] [<c0015904>] (unwind_backtrace+0x0/0x124) from [<c04d547c>] (dump_stack+0x20/0x24)        
[  456.768000] [<c04d547c>] (dump_stack+0x20/0x24) from [<c000fffc>] (show_regs+0x4c/0x58)               
[  456.776000] [<c000fffc>] (show_regs+0x4c/0x58) from [<c00a48a4>] (watchdog_timer_fn+0x24c/0x300)      
[  456.788000] [<c00a48a4>] (watchdog_timer_fn+0x24c/0x300) from [<c0056298>] (__run_hrtimer+0x148/0x23c)
[  456.796000] [<c0056298>] (__run_hrtimer+0x148/0x23c) from [<c0056b5c>] (hrtimer_interrupt+0x12c/0x280)
[  456.804000] [<c0056b5c>] (hrtimer_interrupt+0x12c/0x280) from [<c001468c>] (twd_handler+0x3c/0x48)    
[  456.816000] [<c001468c>] (twd_handler+0x3c/0x48) from [<c00a8720>] (handle_percpu_devid_irq+0xfc/0x19)
[  456.824000] [<c00a8720>] (handle_percpu_devid_irq+0xfc/0x198) from [<c00a4cb4>] (generic_handle_irq+0)
[  456.832000] [<c00a4cb4>] (generic_handle_irq+0x30/0x40) from [<c000f368>] (handle_IRQ+0x8c/0xc0)      
[  456.844000] [<c000f368>] (handle_IRQ+0x8c/0xc0) from [<c000858c>] (gic_handle_irq+0x4c/0x6c)          
[  456.852000] [<c000858c>] (gic_handle_irq+0x4c/0x6c) from [<c000e544>] (__irq_svc+0x44/0x78)           
[  456.860000] Exception stack(0xeeac9d90 to 0xeeac9dd8)                                                 
[  456.864000] 9d80:                                     00000004 00000004 00000008 00000001             
[  456.872000] 9da0: eeac9e0c c1574cc0 c1574cc0 00000001 c1574cc8 00000001 00e3f000 eeac9e04             
[  456.880000] 9dc0: 00000002 eeac9dd8 c001b744 c0081980 20000013 ffffffff                               
[  456.888000] [<c000e544>] (__irq_svc+0x44/0x78) from [<c0081980>] (generic_exec_single+0x78/0x94)      
[  456.896000] [<c0081980>] (generic_exec_single+0x78/0x94) from [<c0081b18>] (smp_call_function_single+)
[  456.908000] [<c0081b18>] (smp_call_function_single+0x17c/0x1d0) from [<c00147d4>] (twd_cpufreq_transi)
[  456.916000] [<c00147d4>] (twd_cpufreq_transition+0x38/0x44) from [<c0057f10>] (notifier_call_chain+0x)
[  456.928000] [<c0057f10>] (notifier_call_chain+0x50/0x78) from [<c0058484>] (__srcu_notifier_call_chai)
[  456.936000] [<c0058484>] (__srcu_notifier_call_chain+0x80/0xb4) from [<c00584e0>] (srcu_notifier_call)
[  456.948000] [<c00584e0>] (srcu_notifier_call_chain+0x28/0x30) from [<c0382ff0>] (cpufreq_notify_trans)
[  456.960000] [<c0382ff0>] (cpufreq_notify_transition+0x224/0x270) from [<c038ae28>] (nxp_cpufreq_chang)
[  456.972000] [<c038ae28>] (nxp_cpufreq_change_frequency+0x1c8/0x214) from [<c038b3bc>] (nxp_cpufreq_pr)
[  456.980000] [<c038b3bc>] (nxp_cpufreq_process+0xb0/0xf4) from [<c0051d20>] (kthread+0x94/0xa0)        
[  456.988000] [<c0051d20>] (kthread+0x94/0xa0) from [<c000f600>] (kernel_thread_exit+0x0/0x8)           
[  465.772000] BUG: spinlock lockup on CPU#1, swapper/1/0                                                
[  465.776000]  lock: ef160800, .magic: dead4ead, .owner: swapper/1/0, .owner_cpu: 1                     
[  465.784000] [<c0015904>] (unwind_backtrace+0x0/0x124) from [<c04d547c>] (dump_stack+0x20/0x24)        
[  465.792000] [<c04d547c>] (dump_stack+0x20/0x24) from [<c0239be8>] (spin_dump+0x80/0x94)               
[  465.800000] [<c0239be8>] (spin_dump+0x80/0x94) from [<c0239dc4>] (do_raw_spin_lock+0x130/0x154)       
[  465.808000] [<c0239dc4>] (do_raw_spin_lock+0x130/0x154) from [<c04dc558>] (_raw_spin_lock_irqsave+0x5)
[  465.820000] [<c04dc558>] (_raw_spin_lock_irqsave+0x5c/0x68) from [<c026a930>] (uart_write+0x60/0xf4)  
[  465.828000] [<c026a930>] (uart_write+0x60/0xf4) from [<c0378efc>] (hci_uart_tx_wakeup+0xa8/0x15c)     
[  465.836000] [<c0378efc>] (hci_uart_tx_wakeup+0xa8/0x15c) from [<c037901c>] (hci_uart_tty_wakeup+0x6c/)
[  465.848000] [<c037901c>] (hci_uart_tty_wakeup+0x6c/0x78) from [<c0250a78>] (tty_wakeup+0x48/0x68)     
[  465.856000] [<c0250a78>] (tty_wakeup+0x48/0x68) from [<c026b570>] (uart_write_wakeup+0x2c/0x30)       
[  465.864000] [<c026b570>] (uart_write_wakeup+0x2c/0x30) from [<c0271b28>] (pl011_int+0x33c/0x518)      
[  465.872000] [<c0271b28>] (pl011_int+0x33c/0x518) from [<c00a53bc>] (handle_irq_event_percpu+0xbc/0x28)
[  465.884000] [<c00a53bc>] (handle_irq_event_percpu+0xbc/0x280) from [<c00a55cc>] (handle_irq_event+0x4)
[  465.892000] [<c00a55cc>] (handle_irq_event+0x4c/0x6c) from [<c00a82cc>] (handle_level_irq+0xfc/0x118) 
[  465.904000] [<c00a82cc>] (handle_level_irq+0xfc/0x118) from [<c001e084>] (__vic_handler+0x19c/0x210)  
[  465.912000] [<c001e084>] (__vic_handler+0x19c/0x210) from [<c00a4cb4>] (generic_handle_irq+0x30/0x40) 
[  465.920000] [<c00a4cb4>] (generic_handle_irq+0x30/0x40) from [<c000f368>] (handle_IRQ+0x8c/0xc0)      
[  465.928000] [<c000f368>] (handle_IRQ+0x8c/0xc0) from [<c000858c>] (gic_handle_irq+0x4c/0x6c)          
[  465.936000] [<c000858c>] (gic_handle_irq+0x4c/0x6c) from [<c000e544>] (__irq_svc+0x44/0x78)           
[  465.948000] Exception stack(0xef0a9e88 to 0xef0a9ed0)                                                 
[  465.952000] 9e80:                   00000001 00000000 00000000 ef085280 ef0a8010 c074cc88             
[  465.960000] 9ea0: ef0a8000 00000082 c07c7300 413fc090 00000000 ef0a9f0c ef0a9ea0 ef0a9ed0             
[  465.968000] 9ec0: c0079f1c c0038420 60000113 ffffffff                                                 
[  465.972000] [<c000e544>] (__irq_svc+0x44/0x78) from [<c0038420>] (__do_softirq+0x74/0x248)            
[  465.980000] [<c0038420>] (__do_softirq+0x74/0x248) from [<c0038af0>] (irq_exit+0x64/0x78)             
[  465.988000] [<c0038af0>] (irq_exit+0x64/0x78) from [<c000f370>] (handle_IRQ+0x94/0xc0)                
[  465.996000] [<c000f370>] (handle_IRQ+0x94/0xc0) from [<c000858c>] (gic_handle_irq+0x4c/0x6c)          
[  466.004000] [<c000858c>] (gic_handle_irq+0x4c/0x6c) from [<c000e544>] (__irq_svc+0x44/0x78)           
[  466.016000] Exception stack(0xef0a9f70 to 0xef0a9fb8)                                                 
[  466.020000] 9f60:                                     00000001 00000004 00000000 ef085280             
[  466.028000] 9f80: ef0a8008 ef0a8000 10c0387d c079ddac 4000406a 413fc090 00000000 ef0a9fc4             
[  466.036000] 9fa0: ef0a9f88 ef0a9fb8 c0079f54 c000f730 20000013 ffffffff                               
[  466.044000] [<c000e544>] (__irq_svc+0x44/0x78) from [<c000f730>] (default_idle+0x38/0x40)             
[  466.052000] [<c000f730>] (default_idle+0x38/0x40) from [<c000fb18>] (cpu_idle+0xbc/0x108)             
[  466.060000] [<c000fb18>] (cpu_idle+0xbc/0x108) from [<c04d28cc>] (secondary_start_kernel+0x13c/0x164) 
[  466.068000] [<c04d28cc>] (secondary_start_kernel+0x13c/0x164) from [<40008168>] (0x40008168)          
[  466.076000] Backtrace for cpu 1 (current):                                                            
[  466.080000] [<c0015904>] (unwind_backtrace+0x0/0x124) from [<c04d547c>] (dump_stack+0x20/0x24)        
[  466.088000] [<c04d547c>] (dump_stack+0x20/0x24) from [<c0013b90>] (smp_send_all_cpu_backtrace+0x60/0x)
[  466.100000] [<c0013b90>] (smp_send_all_cpu_backtrace+0x60/0xc8) from [<c000f954>] (arch_trigger_all_c)
[  466.108000] [<c000f954>] (arch_trigger_all_cpu_backtrace+0x18/0x1c) from [<c0239dcc>] (do_raw_spin_lo)
[  466.120000] [<c0239dcc>] (do_raw_spin_lock+0x138/0x154) from [<c04dc558>] (_raw_spin_lock_irqsave+0x5)
[  466.132000] [<c04dc558>] (_raw_spin_lock_irqsave+0x5c/0x68) from [<c026a930>] (uart_write+0x60/0xf4)  
[  466.140000] [<c026a930>] (uart_write+0x60/0xf4) from [<c0378efc>] (hci_uart_tx_wakeup+0xa8/0x15c)     
[  466.148000] [<c0378efc>] (hci_uart_tx_wakeup+0xa8/0x15c) from [<c037901c>] (hci_uart_tty_wakeup+0x6c/)
[  466.160000] [<c037901c>] (hci_uart_tty_wakeup+0x6c/0x78) from [<c0250a78>] (tty_wakeup+0x48/0x68)     
[  466.168000] [<c0250a78>] (tty_wakeup+0x48/0x68) from [<c026b570>] (uart_write_wakeup+0x2c/0x30)       
[  466.176000] [<c026b570>] (uart_write_wakeup+0x2c/0x30) from [<c0271b28>] (pl011_int+0x33c/0x518)      
[  466.184000] [<c0271b28>] (pl011_int+0x33c/0x518) from [<c00a53bc>] (handle_irq_event_percpu+0xbc/0x28)
[  466.192000] [<c00a53bc>] (handle_irq_event_percpu+0xbc/0x280) from [<c00a55cc>] (handle_irq_event+0x4)
[  466.204000] [<c00a55cc>] (handle_irq_event+0x4c/0x6c) from [<c00a82cc>] (handle_level_irq+0xfc/0x118) 
[  466.212000] [<c00a82cc>] (handle_level_irq+0xfc/0x118) from [<c001e084>] (__vic_handler+0x19c/0x210)  
[  466.224000] [<c001e084>] (__vic_handler+0x19c/0x210) from [<c00a4cb4>] (generic_handle_irq+0x30/0x40) 
[  466.232000] [<c00a4cb4>] (generic_handle_irq+0x30/0x40) from [<c000f368>] (handle_IRQ+0x8c/0xc0)      
[  466.240000] [<c000f368>] (handle_IRQ+0x8c/0xc0) from [<c000858c>] (gic_handle_irq+0x4c/0x6c)          
[  466.248000] [<c000858c>] (gic_handle_irq+0x4c/0x6c) from [<c000e544>] (__irq_svc+0x44/0x78)           
[  466.256000] Exception stack(0xef0a9e88 to 0xef0a9ed0)                                                 
[  466.264000] 9e80:                   00000001 00000000 00000000 ef085280 ef0a8010 c074cc88             
[  466.272000] 9ea0: ef0a8000 00000082 c07c7300 413fc090 00000000 ef0a9f0c ef0a9ea0 ef0a9ed0             
[  466.280000] 9ec0: c0079f1c c0038420 60000113 ffffffff                                                 
[  466.284000] [<c000e544>] (__irq_svc+0x44/0x78) from [<c0038420>] (__do_softirq+0x74/0x248)            
[  466.292000] [<c0038420>] (__do_softirq+0x74/0x248) from [<c0038af0>] (irq_exit+0x64/0x78)             
[  466.300000] [<c0038af0>] (irq_exit+0x64/0x78) from [<c000f370>] (handle_IRQ+0x94/0xc0)                
[  466.308000] [<c000f370>] (handle_IRQ+0x94/0xc0) from [<c000858c>] (gic_handle_irq+0x4c/0x6c)          
[  466.316000] [<c000858c>] (gic_handle_irq+0x4c/0x6c) from [<c000e544>] (__irq_svc+0x44/0x78)           
[  466.324000] Exception stack(0xef0a9f70 to 0xef0a9fb8)                                                 
[  466.332000] 9f60:                                     00000001 00000004 00000000 ef085280             
[  466.340000] 9f80: ef0a8008 ef0a8000 10c0387d c079ddac 4000406a 413fc090 00000000 ef0a9fc4             
[  466.348000] 9fa0: ef0a9f88 ef0a9fb8 c0079f54 c000f730 20000013 ffffffff                               
[  466.352000] [<c000e544>] (__irq_svc+0x44/0x78) from [<c000f730>] (default_idle+0x38/0x40)             
[  466.360000] [<c000f730>] (default_idle+0x38/0x40) from [<c000fb18>] (cpu_idle+0xbc/0x108)             
[  466.368000] [<c000fb18>] (cpu_idle+0xbc/0x108) from [<c04d28cc>] (secondary_start_kernel+0x13c/0x164) 
[  466.380000] [<c04d28cc>] (secondary_start_kernel+0x13c/0x164) from [<40008168>] (0x40008168)          
[  466.388000]                                                                                           
[  466.388000] sending IPI to all other CPUs:                                                            
[  466.392000] IPI backtrace for cpu 0                                                                   
[  466.392000]                                                                                           
[  466.392000] Pid: 66, comm:       cpufreq-update                                                       
[  466.392000] CPU: 0    Tainted: G        W     (3.4.39-s5p4418 #9)                                     
[  466.392000] PC is at generic_exec_single+0x78/0x94                                                    
[  466.392000] LR is at gic_raise_softirq+0x3c/0x78                                                      
[  466.392000] pc : [<c0081980>]    lr : [<c001b744>]    psr: 20000013                                   
[  466.392000] sp : eeac9dd8  ip : 00000002  fp : eeac9e04                                               
[  466.392000] r10: 00e3f000  r9 : 00000001  r8 : c1574cc8                                               
[  466.392000] r7 : 00000001  r6 : c1574cc0  r5 : c1574cc0  r4 : eeac9e0c                                
[  466.392000] r3 : 00000001  r2 : 00000008  r1 : 00000004  r0 : 00000004                                
[  466.392000] Flags: nzCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment kernel                       
[  466.392000] Control: 10c5387d  Table: 6e25c04a  DAC: 00000015                                         
[  466.392000]                                                                                           
[  466.392000] PC: 0xc0081900:                                                                           
[  466.392000] 1900  e89da830 c05e5d72 e1a0c00d e92ddff8 e24cb004 e52de004 e8bd4000 e1a07000             
[  466.392000] 1920  e1a04001 e59f3068 e1a09002 e59f6064 e793a100 e086500a e2858008 e1a00008             
[  466.392000] 1940  eb116aed e5953004 e1a01000 e796600a e1a00008 e5854004 e5845000 e5843004             
[  466.392000] 1960  e5834000 eb116b59 e1550006 1a000001 e1a00007 ebfe4806 e3590000 089daff8             
[  466.392000] 1980  e1d431b0 e3130001 0a000000 eafffffb e89daff8 c074cc88 c0735cc0 e1a0c00d             
[  466.392000] 19a0  e92ddff0 e24cb004 e24dd01c e52de004 e8bd4000 e1a05000 e1a06001 e1a07002             
[  466.392000] 19c0  e3a01000 e3a02014 e24b0040 e1a08003 eb069f6a e3a00001 ebff760b e59f916c             
[  466.392000] 19e0  eb06e23b e3500000 e280301f e5992000 a1a03000 e1a032c3 e1a04000 e7923103             
[  466.392000]                                                                                           
[  466.392000] LR: 0xc001b6c4:                                                                           
[  466.392000] b6c4  ea000005 e59f102c e3a03000 e59f202c e1a00004 eb023437 e3a01003 e1a00004             
[  466.392000] b6e4  ebffcf2c e595101c e1a00004 eb0230a2 e3a00000 e89da830 c0752df8 c00a8624             
[  466.392000] b704  c00a8460 e1a0c00d e92ddbf0 e24cb004 e52de004 e8bd4000 e3a05000 e1a07000             
[  466.392000] b724  e59f6048 e1a04001 e59f8044 e3e00000 e2802001 e3a01004 e1a00007 eb0833ce             
[  466.392000] b744  e5963000 e1530000 c7983100 c3a02001 c1855312 cafffff5 f57ff04f e59f3014             
[  466.392000] b764  e1844805 e5933000 e5834f00 e89dabf0 c074c314 c079dd40 c074bcc4 e1a0c00d             
[  466.392000] b784  e92dd8f0 e24cb004 e52de004 e8bd4000 e3a04000 e1a05000 e59f704c e2806c02             
[  466.392000] b7a4  f57ff04f e5973018 e3530000 0a000000 e12fff33 e3843020 e2844001 e3540010             
[  466.392000]                                                                                           
[  466.392000] SP: 0xeeac9d58:                                                                           
[  466.392000] 9d58  00000001 00e3f000 eeac9d8c eeac9d70 c00085a4 c0013c04 c0081980 20000013             
[  466.392000] 9d78  ffffffff eeac9dc4 eeac9e04 eeac9d90 c000e544 c000854c 00000004 00000004             
[  466.392000] 9d98  00000008 00000001 eeac9e0c c1574cc0 c1574cc0 00000001 c1574cc8 00000001             
[  466.392000] 9db8  00e3f000 eeac9e04 00000002 eeac9dd8 c001b744 c0081980 20000013 ffffffff             
[  466.392000] 9dd8  00000001 00000000 00000001 c0014698 00000000 00000001 c04df824 ffffffff             
[  466.392000] 9df8  eeac9e4c eeac9e08 c0081b18 c0081914 eeac9e2c c1574cc0 c1574cc0 c0014698             
[  466.392000] 9e18  00000000 00000001 00000000 ffffffff 00000000 00000001 eeac9f60 00000000             
[  466.392000] 9e38  eeac9f60 ffffffff eeac9e5c eeac9e50 c00147d4 c00819a8 eeac9e84 eeac9e60             
[  466.392000]                                                                                           
[  466.392000] FP: 0xeeac9d84:                                                                           
[  466.392000] 9d84  eeac9d90 c000e544 c000854c 00000004 00000004 00000008 00000001 eeac9e0c             
[  466.392000] 9da4  c1574cc0 c1574cc0 00000001 c1574cc8 00000001 00e3f000 eeac9e04 00000002             
[  466.392000] 9dc4  eeac9dd8 c001b744 c0081980 20000013 ffffffff 00000001 00000000 00000001             
[  466.392000] 9de4  c0014698 00000000 00000001 c04df824 ffffffff eeac9e4c eeac9e08 c0081b18             
[  466.392000] 9e04  c0081914 eeac9e2c c1574cc0 c1574cc0 c0014698 00000000 00000001 00000000             
[  466.392000] 9e24  ffffffff 00000000 00000001 eeac9f60 00000000 eeac9f60 ffffffff eeac9e5c             
[  466.392000] 9e44  eeac9e50 c00147d4 c00819a8 eeac9e84 eeac9e60 c0057f10 c00147a8 c0d51f50             
[  466.392000] 9e64  c0d51f9c c0d51ff0 00000001 00000001 eeac9f60 eeac9ecc eeac9e88 c0058484             
[  466.392000]                                                                                           
[  466.392000] R4: 0xeeac9d8c:                                                                           
[  466.392000] 9d8c  c000854c 00000004 00000004 00000008 00000001 eeac9e0c c1574cc0 c1574cc0             
[  466.392000] 9dac  00000001 c1574cc8 00000001 00e3f000 eeac9e04 00000002 eeac9dd8 c001b744             
[  466.392000] 9dcc  c0081980 20000013 ffffffff 00000001 00000000 00000001 c0014698 00000000             
[  466.392000] 9dec  00000001 c04df824 ffffffff eeac9e4c eeac9e08 c0081b18 c0081914 eeac9e2c             
[  466.392000] 9e0c  c1574cc0 c1574cc0 c0014698 00000000 00000001 00000000 ffffffff 00000000             
[  466.392000] 9e2c  00000001 eeac9f60 00000000 eeac9f60 ffffffff eeac9e5c eeac9e50 c00147d4             
[  466.392000] 9e4c  c00819a8 eeac9e84 eeac9e60 c0057f10 c00147a8 c0d51f50 c0d51f9c c0d51ff0             
[  466.392000] 9e6c  00000001 00000001 eeac9f60 eeac9ecc eeac9e88 c0058484 c0057ecc 00000000             
[  466.392000]                                                                                           
[  466.392000] R5: 0xc1574c40:                                                                           
[  466.392000] 4c40  00000000 00000000 00000000 00000000 c005dee8 c156a7d8 00000000 00000000             
[  466.392000] 4c60  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4c80  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4ca0  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4cc0  eeac9e0c eeac9e0c 00a100a1 00000000 dead4ead ffffffff ffffffff c0cb8f34             
[  466.392000] 4ce0  c087dd20 00000000 c05f0bc8 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4d00  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4d20  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000]                                                                                           
[  466.392000] R6: 0xc1574c40:                                                                           
[  466.392000] 4c40  00000000 00000000 00000000 00000000 c005dee8 c156a7d8 00000000 00000000             
[  466.392000] 4c60  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4c80  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4ca0  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4cc0  eeac9e0c eeac9e0c 00a100a1 00000000 dead4ead ffffffff ffffffff c0cb8f34             
[  466.392000] 4ce0  c087dd20 00000000 c05f0bc8 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4d00  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4d20  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000]                                                                                           
[  466.392000] R8: 0xc1574c48:                                                                           
[  466.392000] 4c48  00000000 00000000 c005dee8 c156a7d8 00000000 00000000 00000000 00000000             
[  466.392000] 4c68  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4c88  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4ca8  00000000 00000000 00000000 00000000 00000000 00000000 eeac9e0c eeac9e0c             
[  466.392000] 4cc8  00a100a1 00000000 dead4ead ffffffff ffffffff c0cb8f34 c087dd20 00000000             
[  466.392000] 4ce8  c05f0bc8 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4d08  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 4d28  00000000 00000000 00000000 00000000 00000000 00000000 00000000 c1574d40             
[  466.392000] [<c0015904>] (unwind_backtrace+0x0/0x124) from [<c04d547c>] (dump_stack+0x20/0x24)        
[  466.392000] [<c04d547c>] (dump_stack+0x20/0x24) from [<c000fffc>] (show_regs+0x4c/0x58)               
[  466.392000] [<c000fffc>] (show_regs+0x4c/0x58) from [<c0013d64>] (handle_IPI+0x16c/0x1f0)             
[  466.392000] [<c0013d64>] (handle_IPI+0x16c/0x1f0) from [<c00085a4>] (gic_handle_irq+0x64/0x6c)        
[  466.392000] [<c00085a4>] (gic_handle_irq+0x64/0x6c) from [<c000e544>] (__irq_svc+0x44/0x78)           
[  466.392000] Exception stack(0xeeac9d90 to 0xeeac9dd8)                                                 
[  466.392000] 9d80:                                     00000004 00000004 00000008 00000001             
[  466.392000] 9da0: eeac9e0c c1574cc0 c1574cc0 00000001 c1574cc8 00000001 00e3f000 eeac9e04             
[  466.392000] 9dc0: 00000002 eeac9dd8 c001b744 c0081980 20000013 ffffffff                               
[  466.392000] [<c000e544>] (__irq_svc+0x44/0x78) from [<c0081980>] (generic_exec_single+0x78/0x94)      
[  466.392000] [<c0081980>] (generic_exec_single+0x78/0x94) from [<c0081b18>] (smp_call_function_single+)
[  466.392000] [<c0081b18>] (smp_call_function_single+0x17c/0x1d0) from [<c00147d4>] (twd_cpufreq_transi)
[  466.392000] [<c00147d4>] (twd_cpufreq_transition+0x38/0x44) from [<c0057f10>] (notifier_call_chain+0x)
[  466.392000] [<c0057f10>] (notifier_call_chain+0x50/0x78) from [<c0058484>] (__srcu_notifier_call_chai)
[  466.392000] [<c0058484>] (__srcu_notifier_call_chain+0x80/0xb4) from [<c00584e0>] (srcu_notifier_call)
[  466.392000] [<c00584e0>] (srcu_notifier_call_chain+0x28/0x30) from [<c0382ff0>] (cpufreq_notify_trans)
[  466.392000] [<c0382ff0>] (cpufreq_notify_transition+0x224/0x270) from [<c038ae28>] (nxp_cpufreq_chang)
[  466.392000] [<c038ae28>] (nxp_cpufreq_change_frequency+0x1c8/0x214) from [<c038b3bc>] (nxp_cpufreq_pr)
[  466.392000] [<c038b3bc>] (nxp_cpufreq_process+0xb0/0xf4) from [<c0051d20>] (kthread+0x94/0xa0)        
[  466.392000] [<c0051d20>] (kthread+0x94/0xa0) from [<c000f600>] (kernel_thread_exit+0x0/0x8)           
[  466.392000] IPI backtrace for cpu 3                                                                   
[  466.392000]                                                                                           
[  466.392000] Pid: 0, comm:            swapper/3                                                        
[  466.392000] CPU: 3    Tainted: G        W     (3.4.39-s5p4418 #9)                                     
[  466.392000] PC is at default_idle+0x38/0x40                                                           
[  466.392000] LR is at trace_hardirqs_on+0x14/0x18                                                      
[  466.392000] pc : [<c000f730>]    lr : [<c0079f98>]    psr: 60000013                                   
[  466.392000] sp : ef0e3fb8  ip : ef0e3fa8  fp : ef0e3fc4                                               
[  466.392000] r10: 00000000  r9 : 413fc090  r8 : 4000406a                                               
[  466.392000] r7 : c079ddac  r6 : 10c0387d  r5 : ef0e2000  r4 : ef0e2008                                
[  466.392000] r3 : 00000000  r2 : 00e4f000  r1 : 00000003  r0 : c000f72c                                
[  466.392000] Flags: nZCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment kernel                       
[  466.392000] Control: 10c5387d  Table: 6e7a004a  DAC: 00000015                                         
[  466.392000]                                                                                           
[  466.392000] PC: 0xc000f6b0:                                                                           
[  466.392000] f6b0  e59f300c e2833480 e12fff33 e7f001f2 c074bc6c c04dd05c e1a0c00d e92dd800             
[  466.392000] f6d0  e24cb004 e52de004 e8bd4000 f57ff05f e3a02001 e3a01000 e59f0004 eb01c9fc             
[  466.392000] f6f0  e89da800 c000f924 e1a0c00d e92dd800 e24cb004 e52de004 e8bd4000 e59f3020             
[  466.392000] f710  e5933058 e3530000 0a000001 e12fff33 ea000000 eb002ccd eb01aa15 f1080080             
[  466.392000] f730  e89da800 c079db08 e1a0c00d e92dd830 e24cb004 e52de004 e8bd4000 e1a0300d             
[  466.392000] f750  e1a00001 e3c31d7f e3c1103f e5d14051 e5d13052 e1944003 0a000002 e3a02074             
[  466.392000] f770  e2811e12 eb086661 e2940000 13a00001 e89da830 e1a0c00d e92dd870 e24cb004             
[  466.392000] f790  e24dd054 e52de004 e8bd4000 e1a05000 e1a06001 e24b0064 e3a01048 e1a04002             
[  466.392000]                                                                                           
[  466.392000] LR: 0xc0079f18:                                                                           
[  466.392000] 9f18  ebffff6c e3500000 0a00000d e5943300 e3530000 1a000005 e59432d4 e58472d8             
[  466.392000] 9f38  e2833001 e58432d4 e58432e0 ea000004 e1a01006 e1a00004 ebffff5e e3500000             
[  466.392000] 9f58  1afffff4 e3c5503f e3a02000 e595300c e5832314 e89da8f0 c076dbec c07a6eb0             
[  466.392000] 9f78  c0d384d4 c074bc44 c05e98bd e1a0c00d e92dd800 e24cb004 e1a0000e ebffff95             
[  466.392000] 9f98  e89da800 e1a0c00d e92dd870 e24cb004 e24dd02c e3a03000 e50b3020 e50b0038             
[  466.392000] 9fb8  e10f5000 f10c0080 ebfff494 e59f3088 f5d3f000 e1931f9f e2812801 e1830f92             
[  466.392000] 9fd8  e3300000 1afffffa e6ff2071 e1a04003 e7ef1851 e1510002 0a000003 e320f002             
[  466.392000] 9ff8  e1d420b0 e6ff2072 eafffff9 f57ff05f e24b0040 ebfff9b5 e1a06000 f57ff05f             
[  466.392000]                                                                                           
[  466.392000] SP: 0xef0e3f38:                                                                           
[  466.392000] 3f38  413fc090 00000000 ef0e3f6c ef0e3f50 c00085a4 c0013c04 c000f730 60000013             
[  466.392000] 3f58  ffffffff ef0e3fa4 ef0e3fc4 ef0e3f70 c000e544 c000854c c000f72c 00000003             
[  466.392000] 3f78  00e4f000 00000000 ef0e2008 ef0e2000 10c0387d c079ddac 4000406a 413fc090             
[  466.392000] 3f98  00000000 ef0e3fc4 ef0e3fa8 ef0e3fb8 c0079f98 c000f730 60000013 ffffffff             
[  466.392000] 3fb8  ef0e3fdc ef0e3fc8 c000fb18 c000f704 c0762828 00000003 ef0e3ff4 ef0e3fe0             
[  466.392000] 3fd8  c04d28cc c000fa68 6f08c06a 00000015 00000000 ef0e3ff8 40008168 c04d279c             
[  466.392000] 3ff8  ffffffff ffffffff 00000000 00000002 00000000 ef0bb180 c075a474 00000003             
[  466.392000] 4018  00000015 c1584700 ef0bb180 ef0ba940 ef0e4020 ee5fc000 c074cc88 00000000             
[  466.392000]                                                                                           
[  466.392000] IP: 0xef0e3f28:                                                                           
[  466.392000] 3f28  ef0e3f70 f0300100 ef0e3fa4 4000406a 413fc090 00000000 ef0e3f6c ef0e3f50             
[  466.392000] 3f48  c00085a4 c0013c04 c000f730 60000013 ffffffff ef0e3fa4 ef0e3fc4 ef0e3f70             
[  466.392000] 3f68  c000e544 c000854c c000f72c 00000003 00e4f000 00000000 ef0e2008 ef0e2000             
[  466.392000] 3f88  10c0387d c079ddac 4000406a 413fc090 00000000 ef0e3fc4 ef0e3fa8 ef0e3fb8             
[  466.392000] 3fa8  c0079f98 c000f730 60000013 ffffffff ef0e3fdc ef0e3fc8 c000fb18 c000f704             
[  466.392000] 3fc8  c0762828 00000003 ef0e3ff4 ef0e3fe0 c04d28cc c000fa68 6f08c06a 00000015             
[  466.392000] 3fe8  00000000 ef0e3ff8 40008168 c04d279c ffffffff ffffffff 00000000 00000002             
[  466.392000] 4008  00000000 ef0bb180 c075a474 00000003 00000015 c1584700 ef0bb180 ef0ba940             
[  466.392000]                                                                                           
[  466.392000] FP: 0xef0e3f44:                                                                           
[  466.392000] 3f44  ef0e3f50 c00085a4 c0013c04 c000f730 60000013 ffffffff ef0e3fa4 ef0e3fc4             
[  466.392000] 3f64  ef0e3f70 c000e544 c000854c c000f72c 00000003 00e4f000 00000000 ef0e2008             
[  466.392000] 3f84  ef0e2000 10c0387d c079ddac 4000406a 413fc090 00000000 ef0e3fc4 ef0e3fa8             
[  466.392000] 3fa4  ef0e3fb8 c0079f98 c000f730 60000013 ffffffff ef0e3fdc ef0e3fc8 c000fb18             
[  466.392000] 3fc4  c000f704 c0762828 00000003 ef0e3ff4 ef0e3fe0 c04d28cc c000fa68 6f08c06a             
[  466.392000] 3fe4  00000015 00000000 ef0e3ff8 40008168 c04d279c ffffffff ffffffff 00000000             
[  466.392000] 4004  00000002 00000000 ef0bb180 c075a474 00000003 00000015 c1584700 ef0bb180             
[  466.392000] 4024  ef0ba940 ef0e4020 ee5fc000 c074cc88 00000000 ef0e5f5c ef0e5f20 c04db530             
[  466.392000]                                                                                           
[  466.392000] R0: 0xc000f6ac:                                                                           
[  466.392000] f6ac  e1a00005 e59f300c e2833480 e12fff33 e7f001f2 c074bc6c c04dd05c e1a0c00d             
[  466.392000] f6cc  e92dd800 e24cb004 e52de004 e8bd4000 f57ff05f e3a02001 e3a01000 e59f0004             
[  466.392000] f6ec  eb01c9fc e89da800 c000f924 e1a0c00d e92dd800 e24cb004 e52de004 e8bd4000             
[  466.392000] f70c  e59f3020 e5933058 e3530000 0a000001 e12fff33 ea000000 eb002ccd eb01aa15             
[  466.392000] f72c  f1080080 e89da800 c079db08 e1a0c00d e92dd830 e24cb004 e52de004 e8bd4000             
[  466.392000] f74c  e1a0300d e1a00001 e3c31d7f e3c1103f e5d14051 e5d13052 e1944003 0a000002             
[  466.392000] f76c  e3a02074 e2811e12 eb086661 e2940000 13a00001 e89da830 e1a0c00d e92dd870             
[  466.392000] f78c  e24cb004 e24dd054 e52de004 e8bd4000 e1a05000 e1a06001 e24b0064 e3a01048             
[  466.392000]                                                                                           
[  466.392000] R4: 0xef0e1f88:                                                                           
[  466.392000] 1f88  00000000 00000000 00000000 00000000 c04edb00 c04e40e0 ef121780 ef0e1f00             
[  466.392000] 1fa8  00000000 0000007e 00000000 00000000 00000001 00000000 00000000 ef0e1fc4             
[  466.392000] 1fc8  ef0e1fc4 00000000 00000000 dead4ead ffffffff ffffffff c0d2f9d5 00000000             
[  466.392000] 1fe8  00000000 c05fe4e4 646f6e04 00000065 ffffffff ffffffff 00000002 00000003             
[  466.392000] 2008  00000000 ef0ba940 c075a474 00000003 00000015 c1584700 ef0ba940 ee198000             
[  466.392000] 2028  ef0e2028 ee5fc000 c074cc88 ee5fc000 ef0e3fa4 ef0e3f68 c04db530 00000000             
[  466.392000] 2048  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 2068  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000]                                                                                           
[  466.392000] R5: 0xef0e1f80:                                                                           
[  466.392000] 1f80  f00002f0 00018124 00000000 00000000 00000000 00000000 c04edb00 c04e40e0             
[  466.392000] 1fa0  ef121780 ef0e1f00 00000000 0000007e 00000000 00000000 00000001 00000000             
[  466.392000] 1fc0  00000000 ef0e1fc4 ef0e1fc4 00000000 00000000 dead4ead ffffffff ffffffff             
[  466.392000] 1fe0  c0d2f9d5 00000000 00000000 c05fe4e4 646f6e04 00000065 ffffffff ffffffff             
[  466.392000] 2000  00000002 00000003 00000000 ef0ba940 c075a474 00000003 00000015 c1584700             
[  466.392000] 2020  ef0ba940 ee198000 ef0e2028 ee5fc000 c074cc88 ee5fc000 ef0e3fa4 ef0e3f68             
[  466.392000] 2040  c04db530 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] 2060  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000]                                                                                           
[  466.392000] R7: 0xc079dd2c:                                                                           
[  466.392000] dd2c  00000000 00000000 00000000 00000000 00000000 00000000 00000001 00000002             
[  466.392000] dd4c  00000003 413fc090 00000000 00000000 00000000 00000000 00000000 00000000             
[  466.392000] dd6c  00000000 00000000 00000000 00000000 00000000 c075de00 c0752434 00000000             
[  466.392000] dd8c  00000000 00000000 00000000 ef5ff000 00000000 c001b708 c078c558 00000000             
[  466.392000] ddac  40004000 00000000 00000001 0000000c f0300600 0bebc200 c079e108 c07384c4             
[  466.392000] ddcc  0000011d 00000000 c06abea8 00000000 00000000 00000000 00000000 00000000             
[  466.392000] ddec  ffffffff 00000000 0000000a 00000001 0000000f ffffffff 00000001 0000000a             
[  466.392000] de0c  00000002 0000000f ffffffff 00000002 0000000a 00000004 0000000f ffffffff             
[  466.392000] [<c0015904>] (unwind_backtrace+0x0/0x124) from [<c04d547c>] (dump_stack+0x20/0x24)        
[  466.392000] [<c04d547c>] (dump_stack+0x20/0x24) from [<c000fffc>] (show_regs+0x4c/0x58)               
[  466.392000] [<c000fffc>] (show_regs+0x4c/0x58) from [<c0013d64>] (handle_IPI+0x16c/0x1f0)             
[  466.392000] [<c0013d64>] (handle_IPI+0x16c/0x1f0) from [<c00085a4>] (gic_handle_irq+0x64/0x6c)        
[  466.392000] [<c00085a4>] (gic_handle_irq+0x64/0x6c) from [<c000e544>] (__irq_svc+0x44/0x78)           
[  466.392000] Exception stack(0xef0e3f70 to 0xef0e3fb8)                                                 
[  466.392000] 3f60:                                     c000f72c 00000003 00e4f000 00000000             
[  466.392000] 3f80: ef0e2008 ef0e2000 10c0387d c079ddac 4000406a 413fc090 00000000 ef0e3fc4             
[  466.392000] 3fa0: ef0e3fa8 ef0e3fb8 c0079f98 c000f730 60000013 ffffffff                               
[  466.392000] [<c000e544>] (__irq_svc+0x44/0x78) from [<c000f730>] (default_idle+0x38/0x40)             
[  466.392000] [<c000f730>] (default_idle+0x38/0x40) from [<c000fb18>] (cpu_idle+0xbc/0x108)             
[  466.392000] [<c000fb18>] (cpu_idle+0xbc/0x108) from [<c04d28cc>] (secondary_start_kernel+0x13c/0x164) 
[  466.392000] [<c04d28cc>] (secondary_start_kernel+0x13c/0x164) from [<40008168>] (0x40008168)          
[  466.392000] IPI backtrace for cpu 2                                                                   
[  468.016000]                                                                                           
[  468.016000] Pid: 723, comm:      brcm_patchram_p                                                      
[  468.020000] CPU: 2    Tainted: G        W     (3.4.39-s5p4418 #9)                                     
[  468.028000] PC is at 0xb6ef28a8                                                                       
[  468.032000] LR is at 0xb6ef33e4                                                                       
[  468.032000] pc : [<b6ef28a8>]    lr : [<b6ef33e4>]    psr: 60000010                                   
[  468.032000] sp : bed33d1c  ip : bed33d30  fp : 00000000                                               
[  468.044000] r10: 00000001  r9 : 00000000  r8 : bed33db4                                               
[  468.048000] r7 : 000000a2  r6 : 000120f4  r5 : 00000000  r4 : 00000000                                
[  468.056000] r3 : 00000000  r2 : 00000000  r1 : bed33d70  r0 : ffffffea                                
[  468.064000] Flags: nZCv  IRQs on  FIQs on  Mode USER_32  ISA ARM  Segment user                        
[  468.072000] Control: 10c5387d  Table: 6e25c04a  DAC: 00000015                                         
[  468.076000] [<c0015904>] (unwind_backtrace+0x0/0x124) from [<c04d547c>] (dump_stack+0x20/0x24)        
[  468.084000] [<c04d547c>] (dump_stack+0x20/0x24) from [<c000fffc>] (show_regs+0x4c/0x58)               
[  468.092000] [<c000fffc>] (show_regs+0x4c/0x58) from [<c0013d64>] (handle_IPI+0x16c/0x1f0)             
[  468.100000] [<c0013d64>] (handle_IPI+0x16c/0x1f0) from [<c00085a4>] (gic_handle_irq+0x64/0x6c)        
[  468.108000] [<c00085a4>] (gic_handle_irq+0x64/0x6c) from [<c000e720>] (__irq_usr+0x40/0x60)           
[  468.116000] Exception stack(0xee615fb0 to 0xee615ff8)                                                 
[  468.124000] 5fa0:                                     ffffffea bed33d70 00000000 00000000             
[  468.132000] 5fc0: 00000000 00000000 000120f4 000000a2 bed33db4 00000000 00000001 00000000             
[  468.140000] 5fe0: bed33d30 bed33d1c b6ef33e4 b6ef28a8 60000010 ffffffff                               

And here is our fix. FriendlyArm (Jensen) can you merge this fix into the tree with credits to Atlants Embedded and eers 4.0?

Thanks!

eers-atlantsembedded-bt-rfcomm.txt

@zimbob10k
Copy link
Author

I'll update this patch to also contain, these few lines which I had missed.

`diff -urN a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c
--- a/net/bluetooth/l2cap_core.c 2016-09-02 07:57:19.772521000 -0700
+++ b/net/bluetooth/l2cap_core.c 2016-09-05 11:10:43.833976609 -0700
@@ -289,15 +289,52 @@
return chan;
}

-void l2cap_chan_destroy(struct l2cap_chan *chan)
+static void l2cap_chan_destroy(struct l2cap_chan *chan)
{

  • BT_DBG("chan %p", chan);

write_lock(&chan_list_lock);
list_del(&chan->global_l);
write_unlock(&chan_list_lock);

  • l2cap_chan_put(chan);
  • //l2cap_chan_put(chan);
  • kfree(chan);
    +}

+void l2cap_chan_hold(struct l2cap_chan *c)
+{

  • BT_DBG("chan %p orig refcnt %d", c, atomic_read(&c->refcnt));
  • atomic_inc(&c->refcnt);
    }

+void l2cap_chan_put(struct l2cap_chan *c)
+{

  • BT_DBG("chan %p orig refcnt %d", c, atomic_read(&c->refcnt));
  • if (atomic_dec_and_test(&c->refcnt))
  •   l2cap_chan_destroy(c);
    
    +}
    +
  • /* Kill socket (only if zapped and orphan)
  • * Must be called on unlocked socket.
  • */
    +static void l2cap_sock_kill(struct sock *sk)
    +{
  • if (!sock_flag(sk, SOCK_ZAPPED) || sk->sk_socket)
  •   return;
    
  • BT_DBG("sk %p state %s", sk, state_to_string(sk->sk_state));
  • /* Kill poor orphan */
  • l2cap_chan_destroy(l2cap_pi(sk)->chan);
  • l2cap_chan_put(l2cap_pi(sk)->chan);
  • sock_set_flag(sk, SOCK_DEAD);
  • sock_put(sk);
    +}

void __l2cap_chan_add(struct l2cap_conn *conn, struct l2cap_chan *chan)
{
BT_DBG("conn %p, psm 0x%2.2x, dcid 0x%4.4x", conn,
@@ -1048,7 +1085,13 @@
struct l2cap_conn *conn = container_of(work, struct l2cap_conn,
security_timer.work);

  • l2cap_conn_del(conn->hcon, ETIMEDOUT);
    +// l2cap_conn_del(conn->hcon, ETIMEDOUT);
  • BT_DBG("conn %p", conn);
  • if (test_and_clear_bit(HCI_CONN_LE_SMP_PEND, &conn->hcon->flags)) {
  •   smp_chan_destroy(conn);
    
  •   l2cap_conn_del(conn->hcon, ETIMEDOUT);
    
  • }
    }

static struct l2cap_conn *l2cap_conn_add(struct hci_conn *hcon, u8 status)atus)
diff -urN a/net/bluetooth/l2cap_sock.c b/net/bluetooth/l2cap_sock.c
--- a/net/bluetooth/l2cap_sock.c 2016-09-02 07:57:19.772521000 -0700
+++ b/net/bluetooth/l2cap_sock.c 2013-04-05 10:08:54.000000000 -0700
@@ -795,7 +795,8 @@

/* Kill poor orphan */

  • l2cap_chan_destroy(l2cap_pi(sk)->chan);
  • //l2cap_chan_destroy(l2cap_pi(sk)->chan);
  • l2cap_chan_put(l2cap_pi(sk)->chan);
    sock_set_flag(sk, SOCK_DEAD);
    sock_put(sk);
    }
    `

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant