Query: Regarding crash in n_tty_receive_buf_common during boot
Hi ,
We have seen lot of crashes in 4.9 during boot in n_tty_receive_buf_common, when tty->disc_data becomes NULL, Below is the call stack for same
29.710969] PC is at n_tty_receive_buf_common+0x68/0xa3c
[ 29.716425] LR is at n_tty_receive_buf_common+0x58/0xa3c
[ 29.721882] pc : [<ffffff80085a7450>] lr : [<ffffff80085a7440>] pstate: 80c00145 [ 29.721885] sp : ffffffc0a2b83c30
[ 29.721889] x29: ffffffc0a2b83c30 x28: ffffffc093c00080
[ 29.723875] x27: ffffff8009b7c0e8 x26: ffffff8009145000
[ 29.729218] x25: ffffff8009cdd748 x24: ffffffc0ee040028
[ 29.729225] x23: ffffffc093c7f280 x22: 0000000000000000
[ 29.729231] x21: ffffffc0e3a5cf62 x20: 0000000000000032
[ 29.729238] x19: 0000000000000000 x18: 0000000000000000
[ 29.729245] x17: 0000000000000000 x16: 0000000000000000
[ 29.729252] x15: 0000000000000000 x14: ffffffc0fb3de310
[ 29.729259] x13: ffffffc0fb3de308 x12: 0000000000000000
[ 29.729265] x11: ffffffc0f641aa80 x10: 0000000000000b10
[ 29.729272] x9 : ffffffc0a2b83ce0 x8 : ffffffc0a2b91cf0
[ 29.729279] x7 : 7aa17304d29fd900 x6 : ffffff8009bef778
[ 29.729285] x5 : ffffff80085a7e24 x4 : 0000000000000001
[ 29.729292] x3 : 0000000000000032 x2 : 0000000000000000
[ 29.729581] x1 : 0000000000000000 x0 : 0000000000002260
[ 29.732927]
[ 29.732927] PC: 0xffffff80085a7410:
[ 29.738025] 7410 9104e381 aa0103f6 aa0203f3 2a0303f4 b9009ba4 f90033a1 d503201f aa1603e0 [ 29.740517] 7430 b9009fbf f941af96 d0005cfa 942acb7f 91174340 f90047a0 d2844c00 8b160000 [ 29.743892] 7450 c8dffc03 f94002c2 52820000 b941eb81 4b020000 0b030000 361800e1 528aaac1 [ 29.749003] 7470 11000800 72aaaaa1 9b217c01 d360fc21 4b807c20 51000400 52800001 6b1f001f [ 29.753967]
[ 29.753967] LR: 0xffffff80085a7400:
[ 29.759068] 7400 a90573fb aa0003fc aa0103f5 aa1e03e0 9104e381 aa0103f6 aa0203f3 2a0303f4 [ 29.760110] 7420 b9009ba4 f90033a1 d503201f aa1603e0 b9009fbf f941af96 d0005cfa 942acb7f [ 29.766051] 7440 91174340 f90047a0 d2844c00 8b160000 c8dffc03 f94002c2 52820000 b941eb81 [ 29.773012] 7460 4b020000 0b030000 361800e1 528aaac1 11000800 72aaaaa1 9b217c01 d360fc21 [ 29.779088]
[ 29.779088] SP: 0xffffffc0a2b83bf0:
[ 29.779092] 3bf0 085a7440 ffffff80 a2b83c30 ffffffc0 085a7450 ffffff80 80c00145 00000000 [ 29.779113] 3c10 a2b83c30 ffffffc0 085a7440 ffffff80 ffffffff ffffffff 09059d28 ffffff80 [ 29.779134] 3c30 a2b83cd0 ffffffc0 085a7e60 ffffff80 93c00080 ffffffc0 e3a5ce80 ffffffc0 [ 29.779155] 3c50 ee040008 ffffffc0 ee040000 ffffffc0 93c7f280 ffffffc0 ee040028 ffffffc0 [ 29.779177] Process kworker/u16:10 (pid: 1216, stack limit = 0xffffffc0a2b80000) [ 29.779181] Call trace:
[ 29.779186] Exception stack(0xffffffc0a2b83a40 to 0xffffffc0a2b83b70)
[ 29.779191] 3a40: 0000000000000000 0000008000000000 ffffffc0a2b83c30 ffffff80085a7450 [ 29.779195] 3a60: 0000000080c00145 ffffffc0a2b83ba0 ffffffc0a2b91180 ffffffc0a2b91180 [ 29.787281] 3a80: ffffff8009cdd6d0 ffffff80080f6ff8 ffffffc0a2b83aa0 ffffff8008088e88 [ 29.787285] 3aa0: ffffffc0a2b83ab0 ffffff8008155758 ffffffc0a2b83ae0 ffffff8008183760 [ 29.787289] 3ac0: ffffffc0a2b91180 ffffffc0f66781b0 ffffffc0f41be520 ffffffc0f41be540 [ 29.787293] 3ae0: ffffffc0a2b83b10 ffffff800818cd50 ffffffc0f41be480 7aa17304d29fd900 [ 29.795323] 3b00: 0000000000002260 0000000000000000 0000000000000000 0000000000000032 [ 29.795327] 3b20: 0000000000000001 ffffff80085a7e24 ffffff8009bef778 7aa17304d29fd900 [ 29.803361] 3b40: ffffffc0a2b91cf0 ffffffc0a2b83ce0 0000000000000b10 ffffffc0f641aa80 [ 29.803364] 3b60: 0000000000000000 ffffffc0fb3de308
[ 29.808376] [<ffffff80085a7450>] n_tty_receive_buf_common+0x68/0xa3c
[ 29.814893] [<ffffff80085a7e60>] n_tty_receive_buf2+0x3c/0x48
[ 29.820791] [<ffffff80085ab1f8>] flush_to_ldisc+0xe4/0x124
[ 29.820798] [<ffffff80080c7f78>] process_one_work+0x184/0x480
[ 29.826696] [<ffffff80080c83b4>] worker_thread+0x140/0x4b4
[ 29.826701] [<ffffff80080cf2cc>] kthread+0xf4/0x108
I have seen some earlier patch which is fixing the same
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=71472fa9c52b1da27663c275d416d8654b905f05
but it is reverted finally in below commit:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=71472fa9c52b1da27663c275d416d8654b905f05.
Do we have any fix available for above bug, please revert me for any further information.
Regards
Gaurav
-- Qualcomm India Private Limited, on behalf of Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project.
Quoted 86 lines · Gaurav
Hi ,
We have seen lot of crashes in 4.9 during boot inn_tty_receive_buf_common, whentty->disc_data
becomes NULL, Below is the call stack for same
29.710969] PC is atn_tty_receive_buf_common+0x68/0xa3c
[ 29.716425] LR is atn_tty_receive_buf_common+0x58/0xa3c
[ 29.721882] pc : [<ffffff80085a7450>] lr : [<ffffff80085a7440>] pstate:80c00145
[ 29.721885] sp :ffffffc0a2b83c30
[ 29.721889] x29:ffffffc0a2b83c30x28:ffffffc093c00080
[ 29.723875] x27:ffffff8009b7c0e8x26:ffffff8009145000
[ 29.729218] x25:ffffff8009cdd748x24:ffffffc0ee040028
[ 29.729225] x23:ffffffc093c7f280x22: 0000000000000000
[ 29.729231] x21:ffffffc0e3a5cf62x20: 0000000000000032
[ 29.729238] x19: 0000000000000000 x18: 0000000000000000
[ 29.729245] x17: 0000000000000000 x16: 0000000000000000
[ 29.729252] x15: 0000000000000000 x14:ffffffc0fb3de310
[ 29.729259] x13:ffffffc0fb3de308x12: 0000000000000000
[ 29.729265] x11:ffffffc0f641aa80x10:0000000000000b10
[ 29.729272] x9 :ffffffc0a2b83ce0x8 :ffffffc0a2b91cf0
[ 29.729279] x7 :7aa17304d29fd900x6 :ffffff8009bef778
[ 29.729285] x5 :ffffff80085a7e24x4 : 0000000000000001
[ 29.729292] x3 : 0000000000000032 x2 : 0000000000000000
[ 29.729581] x1 : 0000000000000000 x0 : 0000000000002260
[ 29.732927]
[ 29.732927] PC:0xffffff80085a7410:
[ 29.738025] 74109104e381aa0103f6aa0203f32a0303f4b9009ba4f90033a1d503201faa1603e0
[ 29.740517] 7430b9009fbff941af96d0005cfa942acb7f91174340f90047a0d2844c008b160000
[ 29.743892] 7450c8dffc03f94002c252820000b941eb814b0200000b030000361800e1528aaac1
[ 29.749003] 7470 1100080072aaaaa19b217c01d360fc214b807c2051000400 528000016b1f001f
[ 29.753967]
[ 29.753967] LR:0xffffff80085a7400:
[ 29.759068] 7400a90573fbaa0003fcaa0103f5aa1e03e09104e381aa0103f6aa0203f32a0303f4
[ 29.760110] 7420b9009ba4f90033a1d503201faa1603e0b9009fbff941af96d0005cfa942acb7f
[ 29.766051] 7440 91174340f90047a0d2844c008b160000c8dffc03f94002c252820000b941eb81
[ 29.773012] 74604b0200000b030000361800e1528aaac11100080072aaaaa19b217c01d360fc21
[ 29.779088]
[ 29.779088] SP:0xffffffc0a2b83bf0:
[ 29.779092] 3bf0085a7440ffffff80a2b83c30ffffffc0085a7450ffffff8080c0014500000000
[ 29.779113] 3c10a2b83c30ffffffc0085a7440ffffff80ffffffff ffffffff09059d28ffffff80
[ 29.779134] 3c30a2b83cd0ffffffc0085a7e60ffffff8093c00080ffffffc0e3a5ce80ffffffc0
[ 29.779155] 3c50ee040008ffffffc0ee040000ffffffc093c7f280ffffffc0ee040028ffffffc0
[ 29.779177] Process kworker/u16:10 (pid: 1216, stack limit =0xffffffc0a2b80000)
[ 29.779181] Call trace:
[ 29.779186] Exception stack(0xffffffc0a2b83a40 to0xffffffc0a2b83b70) [ 29.779191] 3a40: 0000000000000000 0000008000000000ffffffc0a2b83c30ffffff80085a7450
[ 29.779195] 3a60:0000000080c00145ffffffc0a2b83ba0ffffffc0a2b91180ffffffc0a2b91180
[ 29.787281] 3a80:ffffff8009cdd6d0ffffff80080f6ff8ffffffc0a2b83aa0ffffff8008088e88
[ 29.787285] 3aa0:ffffffc0a2b83ab0ffffff8008155758ffffffc0a2b83ae0ffffff8008183760
[ 29.787289] 3ac0:ffffffc0a2b91180ffffffc0f66781b0ffffffc0f41be520ffffffc0f41be540
[ 29.787293] 3ae0:ffffffc0a2b83b10ffffff800818cd50ffffffc0f41be4807aa17304d29fd900
[ 29.795323] 3b00: 0000000000002260 0000000000000000 0000000000000000 0000000000000032
[ 29.795327] 3b20: 0000000000000001ffffff80085a7e24ffffff8009bef7787aa17304d29fd900
[ 29.803361] 3b40:ffffffc0a2b91cf0ffffffc0a2b83ce00000000000000b10ffffffc0f641aa80
[ 29.803364] 3b60: 0000000000000000ffffffc0fb3de308
[ 29.808376] [<ffffff80085a7450>]n_tty_receive_buf_common+0x68/0xa3c[ 29.814893] [<ffffff80085a7e60>]n_tty_receive_buf2+0x3c/0x48[ 29.820791] [<ffffff80085ab1f8>]flush_to_ldisc+0xe4/0x124
[ 29.820798] [<ffffff80080c7f78>]process_one_work+0x184/0x480[ 29.826696] [<ffffff80080c83b4>]worker_thread+0x140/0x4b4
[ 29.826701] [<ffffff80080cf2cc>]kthread+0xf4/0x108
I have seen some earlier patch which is fixing the same
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=71472fa9c52b1da27663c275d416d8654b905f05
Quoted 4 lines
but it is reverted finally in below commit:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=71472fa9c52b1da27663c275d416d8654b905f05.
Do we have any fix available for above bug, please revert me for any further information.
Nope, no new information, see the archives for details :)
But have you tried 4.14? It might be better in this area...
good luck!
greg k-h