[bug] [X10, 3.2.1] Phone resets after unplugging USB-C OTG adapter.
It is a duplicate bug, see here
But I'll leave it, cause it has kernel logs.
I used Samsung's S10 included usb-c otg adapter. When unplgging it (doesn't matter if I connected anything through it to the phone) the phone UI freezes and the phone resets after 1-2 seconds.
[ 113.492113] usbpd usbpd0: Type-C Sink connected
[ 113.578905] CPU0: update max cpu_capacity 1024
[ 113.655892] msm-dwc3 a800000.ssusb: DWC3 exited from low power mode
[ 113.658097] xhci-hcd xhci-hcd.0.auto: xHCI Host Controller
[ 113.664585] xhci-hcd xhci-hcd.0.auto: new USB bus registered, assigned bus number 1
[ 113.665573] xhci-hcd xhci-hcd.0.auto: hcc params 0x0230fe65 hci version 0x110 quirks 0x02010010
[ 113.665601] xhci-hcd xhci-hcd.0.auto: irq 424, io mem 0x0a800000
[ 113.665734] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
[ 113.665737] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[ 113.665739] usb usb1: Product: xHCI Host Controller
[ 113.665741] usb usb1: Manufacturer: Linux 4.9.194 xhci-hcd
[ 113.665743] usb usb1: SerialNumber: xhci-hcd.0.auto
[ 113.668094] type=1131 audit(1586443397.014:1550): pid=1 uid=0 auid=4294967295 ses=4294967295 subj=u:r:kernel:s0 msg='unit=dbus-org.nemomobile.provisioning comm="systemd" exe="/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
[ 113.668416] hub 1-0:1.0: USB hub found
[ 113.668443] hub 1-0:1.0: 1 port detected
[ 113.668668] xhci-hcd xhci-hcd.0.auto: xHCI Host Controller
[ 113.668679] xhci-hcd xhci-hcd.0.auto: new USB bus registered, assigned bus number 2
[ 113.668753] usb usb2: We don't know the algorithms for LPM for this host, disabling LPM.
[ 113.668893] usb usb2: New USB device found, idVendor=1d6b, idProduct=0003
[ 113.668896] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[ 113.668899] usb usb2: Product: xHCI Host Controller
[ 113.668902] usb usb2: Manufacturer: Linux 4.9.194 xhci-hcd
[ 113.668904] usb usb2: SerialNumber: xhci-hcd.0.auto
[ 113.669691] hub 2-0:1.0: USB hub found
[ 113.669713] hub 2-0:1.0: 1 port detected
[ 113.674260] type=1400 audit(1586443436.661:1551): avc: denied { write } for pid=72 comm="kdevtmpfs" name="usb" dev="devtmpfs" ino=33782 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=dir permissive=1
[ 113.678365] type=1400 audit(1586443436.661:1551): avc: denied { write } for pid=72 comm="kdevtmpfs" name="usb" dev="devtmpfs" ino=33782 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=dir permissive=1
[ 113.679158] type=1400 audit(1586443436.661:1552): avc: denied { add_name } for pid=72 comm="kdevtmpfs" name="001" scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=dir permissive=1
[ 113.684070] type=1400 audit(1586443436.661:1552): avc: denied { add_name } for pid=72 comm="kdevtmpfs" name="001" scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=dir permissive=1
[ 113.684085] type=1400 audit(1586443436.662:1553): avc: denied { create } for pid=72 comm="kdevtmpfs" name="001" scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=chr_file permissive=1
[ 113.684240] type=1400 audit(1586443436.662:1553): avc: denied { create } for pid=72 comm="kdevtmpfs" name="001" scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=chr_file permissive=1
[ 113.684246] type=1400 audit(1586443436.663:1554): avc: denied { setattr } for pid=72 comm="kdevtmpfs" name="001" dev="devtmpfs" ino=80241 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=chr_file permissive=1
[ 113.736390] type=1400 audit(1586443436.663:1554): avc: denied { setattr } for pid=72 comm="kdevtmpfs" name="001" dev="devtmpfs" ino=80241 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=chr_file permissive=1
[ 113.736409] type=1400 audit(1586443436.730:1555): avc: denied { getattr } for pid=7833 comm="systemd-udevd" path="/dev/bus/usb/001/001" dev="devtmpfs" ino=80241 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=chr_file permissive=1
[ 114.773575] msm-dwc3 a800000.ssusb: DWC3 in low power mode
[ 115.931659] droid-hal-init: processing action (ril.ecclist=*) from (/usr/libexec/droid-hybris/system/etc/init/ecclist.rc:6)
[ 115.939171] droid-hal-init: processing action (ril.ecclist=*) from (/usr/libexec/droid-hybris/system/etc/init/ecclist.rc:6)
[ 115.988747] droid-hal-init: processing action (ril.ecclist=*) from (/usr/libexec/droid-hybris/system/etc/init/ecclist.rc:6)
Last msgs it shows when unplugging
[ 141.157033] usbpd usbpd0: USB Type-C disconnect
[ 141.164041] msm-dwc3 a800000.ssusb: DWC3 exited from low power mode
[ 141.164199] xhci-hcd xhci-hcd.0.auto: remove, state 4
[ 141.164232] usb usb2: USB disconnect, device number 1
[ 141.165615] xhci-hcd xhci-hcd.0.auto: USB bus 2 deregistered
[ 141.165943] type=1400 audit(1586443436.730:1555): avc: denied { getattr } for pid=7833 comm="systemd-udevd" path="/dev/bus/usb/001/001" dev="devtmpfs" ino=80241 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=chr_file permissive=1
[ 141.166024] type=1400 audit(1586443465.159:1557): avc: denied { remove_name } for pid=72 comm="kdevtmpfs" name="001" dev="devtmpfs" ino=80243 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=dir permissive=1
[ 141.166628] xhci-hcd xhci-hcd.0.auto: remove, state 4
[ 141.166657] usb usb1: USB disconnect, device number 1
journalctl -fal
Apr 09 18:27:11 Sailfish kernel: usbpd usbpd0: USB Type-C disconnect
Apr 09 18:27:11 Sailfish kernel: msm-dwc3 a800000.ssusb: DWC3 exited from low power mode
Apr 09 18:27:11 Sailfish kernel: xhci-hcd xhci-hcd.0.auto: remove, state 4
Apr 09 18:27:11 Sailfish kernel: usb usb2: USB disconnect, device number 1
Apr 09 18:27:11 Sailfish unknown: type=1320 audit(1586446020.662:1544):
Apr 09 18:27:11 Sailfish unknown: type=1400 audit(1586446031.387:1545): avc: denied { remove_name } for pid=72 comm="kdevtmpfs" name="001" dev="devtmpfs" ino=45571 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=dir permissive=1
Apr 09 18:27:11 Sailfish kernel: xhci-hcd xhci-hcd.0.auto: USB bus 2 deregistered
Apr 09 18:27:11 Sailfish unknown: type=1400 audit(1586446031.387:1545): avc: denied { remove_name } for pid=72 comm="kdevtmpfs" name="001" dev="devtmpfs" ino=45571 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=dir permissive=1
Apr 09 18:27:11 Sailfish unknown: type=1400 audit(1586446031.387:1546): avc: denied { unlink } for pid=72 comm="kdevtmpfs" name="001" dev="devtmpfs" ino=45571 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=chr_file permissive=1
Apr 09 18:27:11 Sailfish kernel: xhci-hcd xhci-hcd.0.auto: remove, state 4
Apr 09 18:27:11 Sailfish kernel: usb usb1: USB disconnect, device number 1
Apr 09 18:27:11 Sailfish unknown: type=1400 audit(1586446031.387:1546): avc: denied { unlink } for pid=72 comm="kdevtmpfs" name="001" dev="devtmpfs" ino=45571 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=chr_file permissive=1
Apr 09 18:27:11 Sailfish unknown: type=1400 audit(1586446031.387:1547): avc: denied { rmdir } for pid=72 comm="kdevtmpfs" name="002" dev="devtmpfs" ino=45570 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=dir permissive=1
Apr 09 18:27:11 Sailfish kernel: xhci-hcd xhci-hcd.0.auto: USB bus 1 deregistered
Apr 09 18:27:11 Sailfish kernel: Unhandled fault: synchronous external abort (0x96000010) at 0xffffff8008efb0b4
Apr 09 18:27:11 Sailfish kernel: ------------[ cut here ]------------
Apr 09 18:27:11 Sailfish kernel: Kernel BUG at ffffff971499c030 [verbose debug info unavailable]
Apr 09 18:27:11 Sailfish kernel: Internal error: Oops - BUG: 96000010 [#1] PREEMPT SMP
Apr 09 18:27:11 Sailfish kernel: Modules linked in:
Apr 09 18:27:11 Sailfish kernel: CPU: 1 PID: 781 Comm: kworker/1:3 Tainted: G W 4.9.194 #1
Apr 09 18:27:11 Sailfish kernel: Hardware name: Sony Mobile Communications. kirin(sdm630) (DT)
Apr 09 18:27:11 Sailfish kernel: Workqueue: events dwc3_otg_sm_work
Apr 09 18:27:11 Sailfish kernel: task: ffffffcdb52eee00 task.stack: ffffffcdb752c000
Apr 09 18:27:11 Sailfish kernel: PC is at qusb_phy_set_suspend+0x140/0x1c4
Apr 09 18:27:11 Sailfish kernel: LR is at qusb_phy_set_suspend+0x130/0x1c4
Apr 09 18:27:11 Sailfish kernel: pc : [<ffffff971499c030>] lr : [<ffffff971499c020>] pstate: 80400145
Apr 09 18:27:11 Sailfish kernel: sp : ffffffcdb752fb20
Apr 09 18:27:11 Sailfish kernel: x29: ffffffcdb752fb20 x28: ffffff9716576000
Apr 09 18:27:11 Sailfish kernel: x27: ffffff9714860968 x26: 0000000000000000
Apr 09 18:27:11 Sailfish kernel: x25: ffffff9713f16f70 x24: ffffffcdb752fc88
Apr 09 18:27:11 Sailfish kernel: x23: ffffff9715b6b000 x22: ffffffcdb5e86818
Apr 09 18:27:11 Sailfish kernel: x21: ffffffcdb64936b0 x20: 0000000000000000
Apr 09 18:27:11 Sailfish kernel: x19: ffffffcdb6493418 x18: 0000000000000000
Apr 09 18:27:11 Sailfish kernel: x17: 0000000000000000 x16: ffffff97140ced4c
Apr 09 18:27:11 Sailfish kernel: x15: 0000000000000000 x14: 00000000e87f03d9
Apr 09 18:27:11 Sailfish kernel: x13: 00000000e4fd9a40 x12: 0000000000000028
Apr 09 18:27:11 Sailfish kernel: x11: 0101010101010101 x10: 0000000000000000
Apr 09 18:27:11 Sailfish kernel: x9 : ffffffcdbac05c00 x8 : 0000000000000040
Apr 09 18:27:11 Sailfish kernel: x7 : ffffffcdba963f60 x6 : 0000000000000000
Apr 09 18:27:11 Sailfish kernel: x5 : ffffffcdba963d98 x4 : ffffffcdb927b600
Apr 09 18:27:11 Sailfish kernel: x3 : 0000000000000000 x2 : ffffff971499bef0
Apr 09 18:27:11 Sailfish kernel: x1 : ffffff8008efb0bc x0 : ffffff8008efb0b4
Apr 09 18:27:11 Sailfish kernel:
PC: 0xffffff971499bff0:
Apr 09 18:27:11 Sailfish kernel: bff0 9102e042 52800180 b9000040 d5033e9f f9406660 52800081 9102e000 b9000001
Apr 09 18:27:11 Sailfish kernel: c010 17ffffed 910a6275 aa1503e0 942c2198 f9406660 9102f001 b9000034 9102d000
Apr 09 18:27:11 Sailfish kernel: c030 b9400001 32000021 b9000001 d5033e9f 52800001 aa1303e0 97fffbc8 f9407260
Apr 09 18:27:11 Sailfish kernel: c050 b4000040 b9000014 3945a660 34000240 aa1503e0 942c20ef 52800020 390a5260
Apr 09 18:27:11 Sailfish kernel:
LR: 0xffffff971499bfe0:
Apr 09 18:27:11 Sailfish kernel: bfe0 a94153f3 f94013f5 a8c47bfd d65f03c0 9102e042 52800180 b9000040 d5033e9f
Apr 09 18:27:11 Sailfish kernel: c000 f9406660 52800081 9102e000 b9000001 17ffffed 910a6275 aa1503e0 942c2198
Apr 09 18:27:11 Sailfish kernel: c020 f9406660 9102f001 b9000034 9102d000 b9400001 32000021 b9000001 d5033e9f
Apr 09 18:27:11 Sailfish kernel: c040 52800001 aa1303e0 97fffbc8 f9407260 b4000040 b9000014 3945a660 34000240
Apr 09 18:27:11 Sailfish kernel:
SP: 0xffffffcdb752fae0:
Apr 09 18:27:11 Sailfish kernel: fae0 1499c020 ffffff97 b752fb20 ffffffcd 1499c030 ffffff97 80400145 00000000
Apr 09 18:27:11 Sailfish kernel: fb00 b752fb20 ffffffcd 1499c020 ffffff97 ffffffff ffffffff 00040900 00000000
Apr 09 18:27:11 Sailfish kernel: fb20 b752fb60 ffffffcd 149b1708 ffffff97 b5fb9020 ffffffcd b5e86df8 ffffffcd
Apr 09 18:27:11 Sailfish kernel: fb40 00000000 00000000 b5e86df8 ffffffcd 00000140 00000000 00000001 00000000
Apr 09 18:27:11 Sailfish kernel: Process kworker/1:3 (pid: 781, stack limit = 0xffffffcdb752c000)
Apr 09 18:27:11 Sailfish kernel: Call trace:
Apr 09 18:27:11 Sailfish kernel: Exception stack(0xffffffcdb752f930 to 0xffffffcdb752fa60)
Apr 09 18:27:11 Sailfish kernel: f920: ffffffcdb6493418 0000007fffffffff
Apr 09 18:27:11 Sailfish kernel: f940: 0000000082ea7000 ffffff971499c030 0000000080400145 ffffff9716579000
Apr 09 18:27:11 Sailfish kernel: f960: 0000000000000024 0000000000000007 ffffff9700000000 ffffff8008efb0b4
Apr 09 18:27:11 Sailfish kernel: f980: ffffff9713f16f70 0000000000000000 ffffffcdb7523a02 0000000000040900
Apr 09 18:27:11 Sailfish kernel: f9a0: ffffffcdb752fb60 ffffff97149a0bf8 00000000000000ff ffffff9715b93528
Apr 09 18:27:11 Sailfish kernel: f9c0: ffffffcdb5fb9020 0000000000000001 0000000000000001 ffffff9715b8fd20
Apr 09 18:27:11 Sailfish kernel: f9e0: ffffffcdb752fb60 0000000000040900 ffffff8008efb0b4 ffffff8008efb0bc
Apr 09 18:27:11 Sailfish kernel: fa00: ffffff971499bef0 0000000000000000 ffffffcdb927b600 ffffffcdba963d98
Apr 09 18:27:11 Sailfish kernel: fa20: 0000000000000000 ffffffcdba963f60 0000000000000040 ffffffcdbac05c00
Apr 09 18:27:11 Sailfish kernel: fa40: 0000000000000000 0101010101010101 0000000000000028 00000000e4fd9a40
Apr 09 18:27:11 Sailfish kernel: [<ffffff971499c030>] qusb_phy_set_suspend+0x140/0x1c4
Apr 09 18:27:11 Sailfish kernel: [<ffffff97149b1708>] dwc3_msm_suspend+0x224/0x6b8
Apr 09 18:27:11 Sailfish kernel: [<ffffff97149b1be8>] dwc3_msm_runtime_suspend+0x4c/0x58
Apr 09 18:27:11 Sailfish kernel: [<ffffff97148609a4>] pm_generic_runtime_suspend+0x3c/0x58
Apr 09 18:27:11 Sailfish kernel: [<ffffff9714863038>] rpm_callback+0xe4/0x12c
Apr 09 18:27:11 Sailfish kernel: [<ffffff9714863194>] rpm_suspend+0x114/0x650
Apr 09 18:27:11 Sailfish kernel: [<ffffff9714864d4c>] __pm_runtime_suspend+0x68/0xa0
Apr 09 18:27:11 Sailfish kernel: [<ffffff97149af310>] dwc3_otg_start_host+0x2d0/0x4f4
Apr 09 18:27:11 Sailfish kernel: [<ffffff97149b43a8>] dwc3_otg_sm_work+0x1d4/0x4b0
Apr 09 18:27:11 Sailfish kernel: [<ffffff9713edabfc>] process_one_work+0x154/0x450
Apr 09 18:27:11 Sailfish kernel: [<ffffff9713edaf54>] worker_thread+0x5c/0x474
Apr 09 18:27:11 Sailfish kernel: [<ffffff9713ee2234>] kthread+0xe8/0xfc
Apr 09 18:27:11 Sailfish kernel: [<ffffff9713e83de0>] ret_from_fork+0x10/0x30
Apr 09 18:27:11 Sailfish kernel: Code: f9406660 9102f001 b9000034 9102d000 (b9400001)
Apr 09 18:27:11 Sailfish kernel: ---[ end trace dd6b9304febcc8ae ]---
Apr 09 18:27:11 Sailfish kernel: Bad mode in Error handler detected on CPU1, code 0xbf000000 -- SError
Apr 09 18:27:11 Sailfish kernel: Internal error: Oops - bad mode: 0 [#2] PREEMPT SMP
Apr 09 18:27:11 Sailfish kernel: Modules linked in:
Apr 09 18:27:11 Sailfish kernel: CPU: 1 PID: 2248 Comm: mce Tainted: G D W 4.9.194 #1
Apr 09 18:27:11 Sailfish kernel: Hardware name: Sony Mobile Communications. kirin(sdm630) (DT)
Apr 09 18:27:11 Sailfish kernel: task: ffffffcdb65a1b80 task.stack: ffffffcdb1554000
Apr 09 18:27:11 Sailfish kernel: PC is at 0xf4689c06
Apr 09 18:27:11 Sailfish kernel: LR is at 0xf471fdb9
Apr 09 18:27:11 Sailfish kernel: pc : [<00000000f4689c06>] lr : [<00000000f471fdb9>] pstate: 600e0030
Apr 09 18:27:11 Sailfish kernel: sp : 00000000ffc15ad8
Apr 09 18:27:11 Sailfish kernel: x12: 00000000000000a8
Apr 09 18:27:11 Sailfish kernel: x11: 0000000000000000 x10: 00000000000071b1
Apr 09 18:27:11 Sailfish kernel: x9 : 0000000000000013 x8 : 0000000000000001
Apr 09 18:27:11 Sailfish kernel: x7 : 00000000000000a8 x6 : 0000000000000013
Apr 09 18:27:11 Sailfish kernel: x5 : 00000000000071b1 x4 : 000000000000006c
Apr 09 18:27:11 Sailfish kernel: x3 : 0000000000000000 x2 : 00000000000071b1
Apr 09 18:27:11 Sailfish kernel: x1 : 0000000000000013 x0 : 0000000000000001
Apr 09 18:27:11 Sailfish kernel: Process mce (pid: 2248, stack limit = 0xffffffcdb1554000)
Apr 09 18:27:11 Sailfish kernel: ---[ end trace dd6b9304febcc8af ]---
Apr 09 18:27:11 Sailfish audit[72]: AVC avc: denied { remove_name } for pid=72 comm="kdevtmpfs" name="001" dev="devtmpfs" ino=45571 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=dir permissive=1
Apr 09 18:27:11 Sailfish audit[72]: AVC avc: denied { unlink } for pid=72 comm="kdevtmpfs" name="001" dev="devtmpfs" ino=45571 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=chr_file permissive=1
Apr 09 18:27:11 Sailfish audit[72]: AVC avc: denied { rmdir } for pid=72 comm="kdevtmpfs" name="002" dev="devtmpfs" ino=45570 scontext=u:r:kernel:s0 tcontext=u:object_r:usb_device:s0 tclass=dir permissive=1
post also
coderus ( 2020-04-09 18:11:03 +0200 )editjournalctl -fal
last logshttps://together.jolla.com/question/217634/bugxperia-10-crash-bug-with-usb-otg/
Leon ( 2020-04-09 18:41:49 +0200 )edit