This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM5728: Linux ti2019.06-rt hangs with enabled TI_PRUSS option

Part Number: AM5728
Other Parts Discussed in Thread: TLK105

Hi, 

I have a custom am5728 board and want to upgrade our current TI-Kernel v4.9.77 to TI-Kernel ti2019.06-rt (v4.19.94) and with the kernel option CONFIG_TI_PRUSS=y the newer kernel suddenly hangs during device probing.

With CONFIG_TI_PRUSS=n it does boot successfully to login prompt.

Are there any hints about what the cause could be?

I can provide more information if requested.

Sincerely,

Michael

  • Hi MIchael,

    Could you please attach the failure log?

    Regards

    Karthik

  • Hi Karthik,

    yes, of course. Bootlog is attached.

    Starting kernel ...
    
    [    0.000000] Booting Linux on physical CPU 0x0
    [    0.000000] Linux version 4.19.94-rt39-00001-g394b6a2f02fd (ptxdist@ptxdist) (gcc version 7.3.1 20180201 (OSELAS.Toolchain-2018.02.0 7-20180201)) #8 SMP PREEMPT RT 2020-02-27T14:25:12+00:00
    [    0.000000] CPU: ARMv7 Processor [412fc0f2] revision 2 (ARMv7), cr=30c5387d
    [    0.000000] CPU: div instructions available: patching division code
    [    0.000000] CPU: PIPT / VIPT nonaliasing data cache, PIPT instruction cache
    [    0.000000] OF: fdt: Machine model: TQ TQMa5728 MBa57xx
    [    0.000000] Memory policy: Data cache writealloc
    [    0.000000] efi: Getting EFI parameters from FDT:
    [    0.000000] efi: UEFI not found.
    [    0.000000] Reserved memory: created CMA memory pool at 0x0000000095800000, size 56 MiB
    [    0.000000] OF: reserved mem: initialized node ipu2_cma@95800000, compatible id shared-dma-pool
    [    0.000000] Reserved memory: created CMA memory pool at 0x0000000099000000, size 64 MiB
    [    0.000000] OF: reserved mem: initialized node dsp1_cma@99000000, compatible id shared-dma-pool
    [    0.000000] Reserved memory: created CMA memory pool at 0x000000009d000000, size 32 MiB
    [    0.000000] OF: reserved mem: initialized node ipu1_cma@9d000000, compatible id shared-dma-pool
    [    0.000000] Reserved memory: created CMA memory pool at 0x000000009f000000, size 8 MiB
    [    0.000000] OF: reserved mem: initialized node dsp2_cma@9f000000, compatible id shared-dma-pool
    [    0.000000] cma: Reserved 24 MiB at 0x00000000fe400000
    [    0.000000] OMAP4: Map 0x00000000ffd00000 to (ptrval) for dram barrier
    [    0.000000] Hit pending asynchronous external abort (FSR=0x00001211) during first unmask, this is most likely caused by a firmware/bootloader bug.
    [    0.000000] On node 0 totalpages: 523520
    [    0.000000]   DMA zone: 1728 pages used for memmap
    [    0.000000]   DMA zone: 0 pages reserved
    [    0.000000]   DMA zone: 196608 pages, LIFO batch:63
    [    0.000000]   HighMem zone: 326912 pages, LIFO batch:63
    [    0.000000] DRA752 ES2.0
    [    0.000000] random: get_random_bytes called from start_kernel+0xac/0x484 with crng_init=0
    [    0.000000] percpu: Embedded 15 pages/cpu s32608 r8192 d20640 u61440
    [    0.000000] pcpu-alloc: s32608 r8192 d20640 u61440 alloc=15*4096
    [    0.000000] pcpu-alloc: [0] 0 [0] 1
    [    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 521792
    [    0.000000] Kernel command line: console=tty0 console=ttyO2,115200n8 earlyprintk loglevel=9 dyndbg="file drivers/soc/ti/* +pfl; file drivers/remoteproc/* +pfl" root=/dev/nfs nfsroot=172.168.135.107:/tftpboot/rootfs/tqma57xx,v3,nolock rw ip=172.168.135.170:172.168.135.107::255.255.255.0::eth0::::
    [    0.000000] Dentry cache hash table entries: 131072 (order: 8, 1048576 bytes)
    [    0.000000] Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
    [    0.000000] Memory: 1868008K/2094080K available (10240K kernel code, 402K rwdata, 2948K rodata, 2048K init, 279K bss, 37656K reserved, 188416K cma-reserved, 1283072K highmem)
    [    0.000000] Virtual kernel memory layout:
    [    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    [    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
    [    0.000000]     vmalloc : 0xf0800000 - 0xff800000   ( 240 MB)
    [    0.000000]     lowmem  : 0xc0000000 - 0xf0000000   ( 768 MB)
    [    0.000000]     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
    [    0.000000]     modules : 0xbf000000 - 0xbfe00000   (  14 MB)
    [    0.000000]       .text : 0x(ptrval) - 0x(ptrval)   (12256 kB)
    [    0.000000]       .init : 0x(ptrval) - 0x(ptrval)   (2048 kB)
    [    0.000000]       .data : 0x(ptrval) - 0x(ptrval)   ( 403 kB)
    [    0.000000]        .bss : 0x(ptrval) - 0x(ptrval)   ( 280 kB)
    [    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
    [    0.000000] rcu: Preemptible hierarchical RCU implementation.
    [    0.000000] rcu:     RCU priority boosting: priority 1 delay 500 ms.
    [    0.000000]  No expedited grace period (rcu_normal_after_boot).
    [    0.000000]  Tasks RCU enabled.
    [    0.000000] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
    [    0.000000] GIC: Using split EOI/Deactivate mode
    [    0.000000] OMAP clockevent source: timer1 at 32786 Hz
    [    0.000000] arch_timer: cp15 timer(s) running at 6.14MHz (phys).
    [    0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0x16af5adb9, max_idle_ns: 440795202250 ns
    [    0.000005] sched_clock: 56 bits at 6MHz, resolution 162ns, wraps every 4398046511023ns
    [    0.000011] Switching to timer-based delay loop, resolution 162ns
    [    0.000306] clocksource: 32k_counter: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 58327039986419 ns
    [    0.000310] OMAP clocksource: 32k_counter at 32768 Hz
    [    0.000797] Console: colour dummy device 80x30
    [    0.001593] console [tty0] enabled
    [    0.001607] WARNING: Your 'console=ttyO2' has been replaced by 'ttyS2'
    [    0.001609] This ensures that you still see kernel messages. Please
    [    0.001611] update your kernel commandline.
    [    0.001634] Calibrating delay loop (skipped), value calculated using timer frequency.. 12.29 BogoMIPS (lpj=61475)
    [    0.001642] pid_max: default: 32768 minimum: 301
    [    0.001777] Mount-cache hash table entries: 2048 (order: 1, 8192 bytes)
    [    0.001787] Mountpoint-cache hash table entries: 2048 (order: 1, 8192 bytes)
    [    0.002479] CPU: Testing write buffer coherency: ok
    [    0.002512] CPU0: Spectre v2: using ICIALLU workaround
    [    0.002752] /cpus/cpu@0 missing clock-frequency property
    [    0.002889] /cpus/cpu@1 missing clock-frequency property
    [    0.002909] CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
    [    0.059911] Setting up static identity map for 0x80200000 - 0x80200060
    [    0.099940] rcu: Hierarchical SRCU implementation.
    [    0.163875] EFI services will not be available.
    [    0.180085] smp: Bringing up secondary CPUs ...
    [    0.320503] CPU1: thread -1, cpu 1, socket 0, mpidr 80000001
    [    0.320509] CPU1: Spectre v2: using ICIALLU workaround
    [    0.320636] smp: Brought up 1 node, 2 CPUs
    [    0.320678] SMP: Total of 2 processors activated (24.59 BogoMIPS).
    [    0.320696] CPU: All CPU(s) started in HYP mode.
    [    0.320711] CPU: Virtualization extensions available.
    [    0.321324] devtmpfs: initialized
    [    0.350585] VFP support v0.3: implementor 41 architecture 4 part 30 variant f rev 0
    [    0.350916] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
    [    0.350950] futex hash table entries: 512 (order: 3, 32768 bytes)
    [    0.354306] pinctrl core: initialized pinctrl subsystem
    [    0.354915] DMI not present or invalid.
    [    0.355263] NET: Registered protocol family 16
    [    0.356670] DMA: preallocated 256 KiB pool for atomic coherent allocations
    [    0.357608] omap_hwmod: l3_main_2 using broken dt data from ocp
    [    0.563800] gpio gpiochip0: (gpio-0-31): added GPIO chardev (254:0)
    [    0.563911] gpiochip_setup_dev: registered GPIOs 0 to 31 on device: gpiochip0 (gpio-0-31)
    [    0.564100] OMAP GPIO hardware version 0.1
    [    0.564884] gpio gpiochip1: (gpio-32-63): added GPIO chardev (254:1)
    [    0.564980] gpiochip_setup_dev: registered GPIOs 32 to 63 on device: gpiochip1 (gpio-32-63)
    [    0.565781] gpio gpiochip2: (gpio-64-95): added GPIO chardev (254:2)
    [    0.565879] gpiochip_setup_dev: registered GPIOs 64 to 95 on device: gpiochip2 (gpio-64-95)
    [    0.566682] gpio gpiochip3: (gpio-96-127): added GPIO chardev (254:3)
    [    0.566776] gpiochip_setup_dev: registered GPIOs 96 to 127 on device: gpiochip3 (gpio-96-127)
    [    0.567601] gpio gpiochip4: (gpio-128-159): added GPIO chardev (254:4)
    [    0.567706] gpiochip_setup_dev: registered GPIOs 128 to 159 on device: gpiochip4 (gpio-128-159)
    [    0.568519] gpio gpiochip5: (gpio-160-191): added GPIO chardev (254:5)
    [    0.568619] gpiochip_setup_dev: registered GPIOs 160 to 191 on device: gpiochip5 (gpio-160-191)
    [    0.591025] hw-breakpoint: found 5 (+1 reserved) breakpoint and 4 watchpoint registers.
    [    0.591055] hw-breakpoint: maximum watchpoint size is 8 bytes.
    [    0.592195] OMAP DMA hardware revision 0.0
    [    0.643317] edma 43300000.edma: memcpy is disabled
    [    0.647573] edma 43300000.edma: TI EDMA DMA engine driver
    [    0.656491] omap-dma-engine 4a056000.dma-controller: OMAP DMA engine driver (LinkedList1/2/3 supported)
    [    0.657083] of_get_named_gpiod_flags: can't parse 'gpio' property of node '/fixedregulator-vdd_5v[0]'
    [    0.657373] of_get_named_gpiod_flags: can't parse 'gpio' property of node '/fixedregulator-vdd_3v3[0]'
    [    0.657658] of_get_named_gpiod_flags: can't parse 'gpio' property of node '/fixedregulator-vtt[0]'
    [    0.657954] of_get_named_gpiod_flags: can't parse 'gpio' property of node '/fixedregulator-vcc_5v[0]'
    [    0.658244] of_get_named_gpiod_flags: can't parse 'gpio' property of node '/fixedregulator-vcc_3v3[0]'
    [    0.661547] omap-iommu 40d01000.mmu: 40d01000.mmu registered
    [    0.661910] omap-iommu 40d02000.mmu: 40d02000.mmu registered
    [    0.662339] omap-iommu 58882000.mmu: 58882000.mmu registered
    [    0.662755] omap-iommu 55082000.mmu: 55082000.mmu registered
    [    0.663342] omap-iommu 41501000.mmu: 41501000.mmu registered
    [    0.663676] omap-iommu 41502000.mmu: 41502000.mmu registered
    [    0.663976] iommu: Adding device 58820000.ipu to group 1
    [    0.664064] iommu: Adding device 55020000.ipu to group 2
    [    0.664194] iommu: Adding device 40800000.dsp to group 0
    [    0.664422] iommu: Adding device 41000000.dsp to group 3
    [    0.665699] SCSI subsystem initialized
    [    0.680858] libata version 3.00 loaded.
    [    0.681997] palmas 0-0058: Irq flag is 0x00000004
    [    0.722570] palmas 0-0058: Muxing GPIO 2b, PWM 0, LED 0
    [    0.724225] SMPS12: supplied by regulator-dummy
    [    0.725851] SMPS3: supplied by VDD5V
    [    0.727379] SMPS45: supplied by regulator-dummy
    [    0.729137] SMPS6: supplied by VDD5V
    [    0.730758] SMPS7: supplied by VDD5V
    [    0.732564] SMPS8: supplied by VDD5V
    [    0.733799] SMPS9: supplied by VDD5V
    [    0.734734] LDO1: supplied by VDD5V
    [    0.751511] random: fast init done
    [    0.751627] LDO2: supplied by VDD5V
    [    0.771498] LDO3: supplied by VDD5V
    [    0.791511] LDO4: supplied by VDD5V
    [    0.811538] LDO5: supplied by regulator-dummy
    [    0.812232] LDO6: supplied by regulator-dummy
    [    0.812916] LDO7: supplied by regulator-dummy
    [    0.813616] LDO8: supplied by regulator-dummy
    [    0.814291] LDO9: supplied by VDD5V
    [    0.831841] LDOLN: supplied by VDD5V
    [    0.851573] LDOUSB: supplied by VDD5V
    [    0.873662] gpiochip_find_base: found new base at 504
    [    0.873842] gpio gpiochip6: (48070000.i2c:tps659038@58:tps659038_gpio): added GPIO chardev (254:6)
    [    0.873947] gpiochip_setup_dev: registered GPIOs 504 to 511 on device: gpiochip6 (48070000.i2c:tps659038@58:tps659038_gpio)
    [    0.874716] omap_i2c 48070000.i2c: bus 0 rev0.12 at 400 kHz
    [    0.875583] pca953x 3-0021: GPIO lookup for consumer reset
    [    0.875605] pca953x 3-0021: using device tree for GPIO lookup
    [    0.875635] of_get_named_gpiod_flags: can't parse 'reset-gpios' property of node '/ocp/i2c@4807a000/pca9555@21[0]'
    [    0.875670] of_get_named_gpiod_flags: can't parse 'reset-gpio' property of node '/ocp/i2c@4807a000/pca9555@21[0]'
    [    0.875697] pca953x 3-0021: using lookup tables for GPIO lookup
    [    0.875717] pca953x 3-0021: No GPIO consumer reset found
    [    0.875807] pca953x 3-0021: Linked as a consumer to regulator.5
    [    0.911538] gpiochip_find_base: found new base at 488
    [    0.911695] gpio gpiochip7: (pca9555): added GPIO chardev (254:7)
    [    0.911790] gpiochip_setup_dev: registered GPIOs 488 to 503 on device: gpiochip7 (pca9555)
    [    0.912075] of_get_named_gpiod_flags: parsed 'irq-gpio' property of node '/ocp/i2c@4807a000/stmpe811@41[0]' - status (0)
    [    0.912336] stmpe-i2c 3-0041: stmpe811 detected, chip id: 0x811
    [    0.951893] omap_i2c 4807a000.i2c: bus 3 rev0.12 at 400 kHz
    [    0.952179] pps_core: LinuxPPS API ver. 1 registered
    [    0.952198] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
    [    0.952235] PTP clock support registered
    [    0.952277] EDAC MC: Ver: 3.0.0
    [    0.971459] omap-mailbox: probe of 4883c000.mailbox failed with error -22
    [    0.971541] omap-mailbox: probe of 4883e000.mailbox failed with error -22
    [    0.971813] omap-mailbox 48840000.mailbox: omap mailbox rev 0x400
    [    0.972101] omap-mailbox 48842000.mailbox: omap mailbox rev 0x400
    [    0.973536] clocksource: Switched to clocksource arch_sys_counter
    [    0.983719] NET: Registered protocol family 2
    [    0.984468] tcp_listen_portaddr_hash hash table entries: 512 (order: 2, 16384 bytes)
    [    0.984523] TCP established hash table entries: 8192 (order: 3, 32768 bytes)
    [    0.984608] TCP bind hash table entries: 8192 (order: 5, 229376 bytes)
    [    0.984862] TCP: Hash tables configured (established 8192 bind 8192)
    [    0.984971] UDP hash table entries: 512 (order: 3, 32768 bytes)
    [    0.985035] UDP-Lite hash table entries: 512 (order: 3, 32768 bytes)
    [    0.985243] NET: Registered protocol family 1
    [    1.005776] RPC: Registered named UNIX socket transport module.
    [    1.005798] RPC: Registered udp transport module.
    [    1.005815] RPC: Registered tcp transport module.
    [    1.005831] RPC: Registered tcp NFSv4.1 backchannel transport module.
    [    1.005853] PCI: CLS 0 bytes, default 64
    [    1.007072] hw perfevents: no interrupt-affinity property for /pmu, guessing.
    [    1.007327] hw perfevents: enabled with armv7_cortex_a15 PMU driver, 7 counters available
    [    1.008652] Initialise system trusted keyrings
    [    1.008813] workingset: timestamp_bits=14 max_order=19 bucket_order=5
    [    1.015734] squashfs: version 4.0 (2009/01/31) Phillip Lougher
    [    1.016352] NFS: Registering the id_resolver key type
    [    1.016387] Key type id_resolver registered
    [    1.016404] Key type id_legacy registered
    [    1.016455] ntfs: driver 2.1.32 [Flags: R/O].
    [    1.018120] Key type asymmetric registered
    [    1.018144] Asymmetric key parser 'x509' registered
    [    1.018220] bounce: pool size: 64 pages
    [    1.018264] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 247)
    [    1.018287] io scheduler noop registered
    [    1.018304] io scheduler deadline registered
    [    1.018506] io scheduler cfq registered (default)
    [    1.018526] io scheduler mq-deadline registered
    [    1.018543] io scheduler kyber registered
    [    1.023071] phy phy-4a084000.phy.0: Linked as a consumer to regulator.23
    [    1.023603] phy phy-4a085000.phy.1: Linked as a consumer to regulator.23
    [    1.026489] pinctrl-single 4a003400.pinmux: 282 pins, size 1128
    [    1.030714] dra7-pcie 51000000.pcie: Linked as a consumer to phy-4a094000.pciephy.3
    [    1.030903] dra7-pcie 51000000.pcie: GPIO lookup for consumer (null)
    [    1.030925] dra7-pcie 51000000.pcie: using device tree for GPIO lookup
    [    1.030958] of_get_named_gpiod_flags: can't parse 'gpios' property of node '/ocp/axi@0/pcie@51000000[0]'
    [    1.030992] of_get_named_gpiod_flags: can't parse 'gpio' property of node '/ocp/axi@0/pcie@51000000[0]'
    [    1.031019] dra7-pcie 51000000.pcie: using lookup tables for GPIO lookup
    [    1.031039] dra7-pcie 51000000.pcie: No GPIO consumer (null) found
    [    1.031260] dra7-pcie 51000000.pcie: host bridge /ocp/axi@0/pcie@51000000 ranges:
    [    1.031314] dra7-pcie 51000000.pcie:    IO 0x20003000..0x20012fff -> 0x00000000
    [    1.031354] dra7-pcie 51000000.pcie:   MEM 0x20013000..0x2fffffff -> 0x20013000
    [    2.031658] dra7-pcie 51000000.pcie: Phy link never came up
    [    2.031832] dra7-pcie 51000000.pcie: PCI host bridge to bus 0000:00
    [    2.031860] pci_bus 0000:00: root bus resource [bus 00-ff]
    [    2.031880] pci_bus 0000:00: root bus resource [io  0x0000-0xffff]
    [    2.031901] pci_bus 0000:00: root bus resource [mem 0x20013000-0x2fffffff]
    [    2.031947] pci 0000:00:00.0: [104c:8888] type 01 class 0x060400
    [    2.031992] pci 0000:00:00.0: reg 0x10: [mem 0x00000000-0x000fffff 64bit]
    [    2.032073] pci 0000:00:00.0: supports D1
    [    2.032092] pci 0000:00:00.0: PME# supported from D0 D1 D3hot
    [    2.038076] PCI: bus0: Fast back to back transfers disabled
    [    2.043720] PCI: bus1: Fast back to back transfers enabled
    [    2.043778] pci 0000:00:00.0: BAR 0: assigned [mem 0x20100000-0x201fffff 64bit]
    [    2.043811] pci 0000:00:00.0: PCI bridge to [bus 01-ff]
    [    2.044306] pcieport 0000:00:00.0: Signaling PME with IRQ 184
    [    2.044576] pcieport 0000:00:00.0: AER enabled with IRQ 184
    [    2.044971] dra7-pcie 51800000.pcie: Linked as a consumer to phy-4a095000.pciephy.4
    [    2.045104] dra7-pcie 51800000.pcie: GPIO lookup for consumer (null)
    [    2.045125] dra7-pcie 51800000.pcie: using device tree for GPIO lookup
    [    2.045156] of_get_named_gpiod_flags: can't parse 'gpios' property of node '/ocp/axi@1/pcie@51800000[0]'
    [    2.045189] of_get_named_gpiod_flags: can't parse 'gpio' property of node '/ocp/axi@1/pcie@51800000[0]'
    [    2.045215] dra7-pcie 51800000.pcie: using lookup tables for GPIO lookup
    [    2.045235] dra7-pcie 51800000.pcie: No GPIO consumer (null) found
    [    2.045361] dra7-pcie 51800000.pcie: host bridge /ocp/axi@1/pcie@51800000 ranges:
    [    2.045414] dra7-pcie 51800000.pcie:    IO 0x30003000..0x30012fff -> 0x00000000
    [    2.045453] dra7-pcie 51800000.pcie:   MEM 0x30013000..0x3fffffff -> 0x30013000
    [    3.045738] dra7-pcie 51800000.pcie: Phy link never came up
    [    3.045901] dra7-pcie 51800000.pcie: PCI host bridge to bus 0001:00
    [    3.045928] pci_bus 0001:00: root bus resource [bus 00-ff]
    [    3.045950] pci_bus 0001:00: root bus resource [io  0x10000-0x1ffff] (bus address [0x0000-0xffff])
    [    3.045975] pci_bus 0001:00: root bus resource [mem 0x30013000-0x3fffffff]
    [    3.046018] pci 0001:00:00.0: [104c:8888] type 01 class 0x060400
    [    3.046058] pci 0001:00:00.0: reg 0x10: [mem 0x00000000-0x000fffff 64bit]
    [    3.046129] pci 0001:00:00.0: supports D1
    [    3.046148] pci 0001:00:00.0: PME# supported from D0 D1 D3hot
    [    3.052003] PCI: bus0: Fast back to back transfers disabled
    [    3.057664] PCI: bus1: Fast back to back transfers enabled
    [    3.057716] pci 0001:00:00.0: BAR 0: assigned [mem 0x30100000-0x301fffff 64bit]
    [    3.057748] pci 0001:00:00.0: PCI bridge to [bus 01-ff]
    [    3.058219] pcieport 0001:00:00.0: Signaling PME with IRQ 186
    [    3.058488] pcieport 0001:00:00.0: AER enabled with IRQ 186
    [    3.065031] pruss_probe:429: pruss 4b200000.pruss: memory    dram0: pa 0x000000004b200000 size 0x2000 va (ptrval)
    [    3.065091] pruss_probe:429: pruss 4b200000.pruss: memory    dram1: pa 0x000000004b202000 size 0x2000 va (ptrval)
    [    3.065146] pruss_probe:429: pruss 4b200000.pruss: memory shrdram2: pa 0x000000004b210000 size 0x8000 va (ptrval)
    [    3.065174] pruss_probe:435: pruss 4b200000.pruss: creating PRU cores and other child platform devices
    [    3.067531] pruss_probe:429: pruss 4b280000.pruss: memory    dram0: pa 0x000000004b280000 size 0x2000 va (ptrval)
    [    3.067588] pruss_probe:429: pruss 4b280000.pruss: memory    dram1: pa 0x000000004b282000 size 0x2000 va (ptrval)
    [    3.067642] pruss_probe:429: pruss 4b280000.pruss: memory shrdram2: pa 0x000000004b290000 size 0x8000 va (ptrval)
    [    3.067669] pruss_probe:435: pruss 4b280000.pruss: creating PRU cores and other child platform devices
    [    3.071075] VDD3V3: supplied by smps9
    [    3.071347] vtt_fixed: supplied by VDD3V3
    [    3.128247] Serial: 8250/16550 driver, 10 ports, IRQ sharing disabled
    [    3.131483] 48020000.serial: ttyS2 at MMIO 0x48020000 (irq = 47, base_baud = 3000000) is a 8250
    [    4.852065] console [ttyS2] enabled
    [    4.856502] 4ae2b000.serial: ttyS9 at MMIO 0x4ae2b000 (irq = 48, base_baud = 3000000) is a 8250
    [    4.867698] omap_rng 48090000.rng: Random Number Generator ver. 20
    [    4.868285] random: crng init done
    [    4.895969] brd: module loaded
    [    4.906998] loop: module loaded
    [    4.910579] at24 0-0057: GPIO lookup for consumer wp
    [    4.915582] at24 0-0057: using device tree for GPIO lookup
    [    4.921117] of_get_named_gpiod_flags: can't parse 'wp-gpios' property of node '/ocp/i2c@48070000/se97@57[0]'
    [    4.931019] of_get_named_gpiod_flags: can't parse 'wp-gpio' property of node '/ocp/i2c@48070000/se97@57[0]'
    [    4.940827] at24 0-0057: using lookup tables for GPIO lookup
    [    4.946528] at24 0-0057: No GPIO consumer wp found
    [    4.951664] at24 0-0057: 256 byte spd EEPROM, read-only, 0 bytes/write
    [    4.958381] at24 0-0054: GPIO lookup for consumer wp
    [    4.963379] at24 0-0054: using device tree for GPIO lookup
    [    4.968922] of_get_named_gpiod_flags: can't parse 'wp-gpios' property of node '/ocp/i2c@48070000/24c64@54[0]'
    [    4.978909] of_get_named_gpiod_flags: can't parse 'wp-gpio' property of node '/ocp/i2c@48070000/24c64@54[0]'
    [    4.988801] at24 0-0054: using lookup tables for GPIO lookup
    [    4.994500] at24 0-0054: No GPIO consumer wp found
    [    4.999635] at24 0-0054: 8192 byte 24c64 EEPROM, writable, 32 bytes/write
    [    5.007569] ahci 4a140000.sata: controller can't do 64bit DMA, forcing 32bit
    [    5.014685] ahci 4a140000.sata: SSS flag set, parallel bus scan disabled
    [    5.021448] ahci 4a140000.sata: AHCI 0001.0300 32 slots 1 ports 3 Gbps 0x1 impl platform mode
    [    5.030031] ahci 4a140000.sata: flags: ncq sntf stag pm led clo only pmp pio slum part ccc apst
    [    5.039878] scsi host0: ahci
    [    5.043080] ata1: SATA max UDMA/133 mmio [mem 0x4a140000-0x4a1410ff] port 0x100 irq 93
    [    5.056486] m25p80 spi0.0: unrecognized JEDEC id bytes: 00, 00, 00
    [    5.062723] m25p80: probe of spi0.0 failed with error -2
    [    5.068686] mdio_bus fixed-0: GPIO lookup for consumer reset
    [    5.074388] mdio_bus fixed-0: using lookup tables for GPIO lookup
    [    5.080521] mdio_bus fixed-0: No GPIO consumer reset found
    [    5.086064] libphy: Fixed MDIO Bus: probed
    [    5.091254] CAN device driver interface
    [    5.096128] c_can_platform 4ae3c000.can: c_can_platform device registered (regs=825a6530, irq=100)
    [    5.105817] c_can_platform 48480000.can: c_can_platform device registered (regs=d4e311ac, irq=101)
    [    5.115515] e1000e: Intel(R) PRO/1000 Network Driver - 3.2.6-k
    [    5.121385] e1000e: Copyright(c) 1999 - 2015 Intel Corporation.
    [    5.127406] igb: Intel(R) Gigabit Ethernet Network Driver - version 5.4.0-k
    [    5.134411] igb: Copyright (c) 2007-2014 Intel Corporation.
    [    5.140147] ns83820.c: National Semiconductor DP83820 10/100/1000 driver.
    [    5.147706] mdio_bus 4b2b2400.mdio: GPIO lookup for consumer reset
    [    5.153929] mdio_bus 4b2b2400.mdio: using device tree for GPIO lookup
    [    5.160429] mdio_bus 4b2b2400.mdio: No GPIO consumer reset found
    [    5.166475] mdio_bus 4b2b2400.mdio: mii_bus 4b2b2400.mdio couldn't get reset GPIO
    [    5.175526] mdio_bus 48485000.mdio: GPIO lookup for consumer reset
    [    5.181751] mdio_bus 48485000.mdio: using device tree for GPIO lookup
    [    5.188246] of_get_named_gpiod_flags: can't parse 'reset-gpios' property of node '/ocp/ethernet@48484000/mdio@48485000[0]'
    [    5.199368] of_get_named_gpiod_flags: can't parse 'reset-gpio' property of node '/ocp/ethernet@48484000/mdio@48485000[0]'
    [    5.210394] mdio_bus 48485000.mdio: using lookup tables for GPIO lookup
    [    5.217053] mdio_bus 48485000.mdio: No GPIO consumer reset found
    [    5.273583] davinci_mdio 48485000.mdio: davinci mdio revision 1.6, bus freq 1000000
    [    5.281292] libphy: 48485000.mdio: probed
    [    5.297665] of_get_named_gpiod_flags: can't parse 'reset-gpios' property of node '/ocp/ethernet@48484000/mdio@48485000/ethernet-phy@2[0]'
    [    5.312355] of_get_named_gpiod_flags: can't parse 'reset-gpios' property of node '/ocp/ethernet@48484000/mdio@48485000/ethernet-phy@3[0]'
    [    5.324940] davinci_mdio 48485000.mdio: phy[2]: device 48485000.mdio:02, driver TI DP83867
    [    5.333258] davinci_mdio 48485000.mdio: phy[3]: device 48485000.mdio:03, driver TI DP83867
    [    5.342342] cpsw 48484000.ethernet: Detected MACID = 44:ea:d8:13:a4:d6
    [    5.348992] cpsw 48484000.ethernet: initialized cpsw ale version 1.4
    [    5.355390] cpsw 48484000.ethernet: ALE Table size 1024
    [    5.360679] cpsw 48484000.ethernet: cpts: overflow check period 500 (jiffies)
    [    5.368835] cpsw 48484000.ethernet: cpsw: Detected MACID = 94:e3:6d:3a:1b:a3
    [    5.375079] ata1: SATA link down (SStatus 0 SControl 300)
    [    5.383190] prueth pruss2_eth: couldn't get mii-rt syscon regmap
    [    5.390155] mousedev: PS/2 mouse device common for all mice
    [    5.396165] stmpe-ts stmpe-ts: DMA mask not set
    [    5.402976] input: stmpe-ts as /devices/platform/44000000.ocp/4807a000.i2c/i2c-3/3-0041/stmpe-ts/input/input0
    [    5.413494] i2c /dev entries driver
    [    5.422605] sdhci: Secure Digital Host Controller Interface driver
    [    5.428836] sdhci: Copyright(c) Pierre Ossman
    [    5.434035] sdhci-pltfm: SDHCI platform and OF driver helper
    [    5.440090] sdhci-omap 4809c000.mmc: GPIO lookup for consumer cd
    [    5.446145] sdhci-omap 4809c000.mmc: using device tree for GPIO lookup
    [    5.452737] of_get_named_gpiod_flags: parsed 'cd-gpios' property of node '/ocp/mmc@4809c000[0]' - status (0)
    [    5.462662] gpio gpiochip3: Persistence not supported for GPIO 27
    [    5.468804] omap_gpio 4805d000.gpio: Could not set line 27 debounce to 200000 microseconds (-22)
    [    5.477647] sdhci-omap 4809c000.mmc: Got CD GPIO
    [    5.482298] sdhci-omap 4809c000.mmc: GPIO lookup for consumer wp
    [    5.488344] sdhci-omap 4809c000.mmc: using device tree for GPIO lookup
    [    5.494933] of_get_named_gpiod_flags: parsed 'wp-gpios' property of node '/ocp/mmc@4809c000[0]' - status (0)
    [    5.504829] gpio gpiochip3: Persistence not supported for GPIO 28
    [    5.510963] sdhci-omap 4809c000.mmc: Got WP GPIO
    [    5.515788] sdhci-omap 4809c000.mmc: Linked as a consumer to regulator.28
    [    5.522671] sdhci-omap 4809c000.mmc: 4809c000.mmc supply vqmmc not found, using dummy regulator
    [    5.531494] sdhci-omap 4809c000.mmc: Linked as a consumer to regulator.0
    [    5.538311] sdhci-omap 4809c000.mmc: Dropping the link to regulator.0
    [    5.544898] sdhci-omap 4809c000.mmc: Linked as a consumer to regulator.2
    [    5.551743] sdhci-omap 4809c000.mmc: no pinctrl state for sdr104 mode
    [    5.558229] sdhci-omap 4809c000.mmc: no pinctrl state for ddr50 mode
    [    5.564633] sdhci-omap 4809c000.mmc: no pinctrl state for sdr50 mode
    [    5.571025] sdhci-omap 4809c000.mmc: no pinctrl state for sdr25 mode
    [    5.577419] sdhci-omap 4809c000.mmc: no pinctrl state for sdr12 mode
    [    5.583820] sdhci-omap 4809c000.mmc: no pinctrl state for ddr_1_8v mode
    [    5.590475] sdhci-omap 4809c000.mmc: no pinctrl state for ddr_3_3v mode
    [    5.597132] sdhci-omap 4809c000.mmc: no pinctrl state for hs200_1_8v mode
    [    5.630035] mmc0: SDHCI controller on 4809c000.mmc [4809c000.mmc] using ADMA
    [    5.637517] sdhci-omap 480b4000.mmc: GPIO lookup for consumer cd
    [    5.643596] sdhci-omap 480b4000.mmc: using device tree for GPIO lookup
    [    5.650191] of_get_named_gpiod_flags: can't parse 'cd-gpios' property of node '/ocp/mmc@480b4000[0]'
    [    5.659414] of_get_named_gpiod_flags: can't parse 'cd-gpio' property of node '/ocp/mmc@480b4000[0]'
    [    5.668535] sdhci-omap 480b4000.mmc: using lookup tables for GPIO lookup
    [    5.675298] sdhci-omap 480b4000.mmc: No GPIO consumer cd found
    [    5.681192] sdhci-omap 480b4000.mmc: GPIO lookup for consumer wp
    [    5.687264] sdhci-omap 480b4000.mmc: using device tree for GPIO lookup
    [    5.693857] of_get_named_gpiod_flags: can't parse 'wp-gpios' property of node '/ocp/mmc@480b4000[0]'
    [    5.703075] of_get_named_gpiod_flags: can't parse 'wp-gpio' property of node '/ocp/mmc@480b4000[0]'
    [    5.712201] sdhci-omap 480b4000.mmc: using lookup tables for GPIO lookup
    [    5.718965] sdhci-omap 480b4000.mmc: No GPIO consumer wp found
    [    5.725205] sdhci-omap 480b4000.mmc: Linked as a consumer to regulator.14
    [    5.732415] sdhci-omap 480b4000.mmc: Dropping the link to regulator.14
    [    5.739091] sdhci-omap 480b4000.mmc: Linked as a consumer to regulator.2
    [    5.746081] sdhci-omap 480b4000.mmc: Linked as a consumer to regulator.14
    [    5.761155] mmc0: new high speed SDHC card at address 0007
    [    5.777494] mmcblk0: mmc0:0007 SD4GB 3.71 GiB
    [    5.781987] mmc1: SDHCI controller on 480b4000.mmc [480b4000.mmc] using ADMA
    [    5.789598] of_get_named_gpiod_flags: parsed 'gpios' property of node '/leds-iio/led-out0[0]' - status (0)
    [    5.799963] no flags found for gpios
    [    5.803959] of_get_named_gpiod_flags: parsed 'gpios' property of node '/leds-iio/led-out1[0]' - status (0)
    [    5.813846] no flags found for gpios
    [    5.822184] pru_rproc_probe:1221: pru-rproc 4b234000.pru: memory     iram: pa 0x000000004b234000 size 0x3000 va 967e3e54
    [    5.833189]  mmcblk0: p1 p2 p3
    [    5.836557] pru_rproc_probe:1221: pru-rproc 4b234000.pru: memory  control: pa 0x000000004b222000 size 0x400 va 508133c7
    [    5.848233] pru_rproc_probe:1221: pru-rproc 4b234000.pru: memory    debug: pa 0x000000004b222400 size 0x100 va e08f0592
    [    5.859210] remoteproc remoteproc0: 4b234000.pru is available
    [    5.865101] pru-rproc 4b234000.pru: PRU rproc node pru@4b234000 probed successfully
    [    5.872938] pru_rproc_probe:1221: pru-rproc 4b238000.pru: memory     iram: pa 0x000000004b238000 size 0x3000 va 1e7005b5
    [    5.883897] pru_rproc_probe:1221: pru-rproc 4b238000.pru: memory  control: pa 0x000000004b224000 size 0x400 va c42e1001
    [    5.894766] pru_rproc_probe:1221: pru-rproc 4b238000.pru: memory    debug: pa 0x000000004b224400 size 0x100 va 60372188
    [    5.905724] remoteproc remoteproc1: 4b238000.pru is available
    [    5.911614] pru-rproc 4b238000.pru: PRU rproc node pru@4b238000 probed successfully
    [    5.919463] pru_rproc_probe:1221: pru-rproc 4b2b4000.pru: memory     iram: pa 0x000000004b2b4000 size 0x3000 va 020951a5
    [    5.931525] pru_rproc_probe:1221: pru-rproc 4b2b4000.pru: memory  control: pa 0x000000004b2a2000 size 0x400 va 71edec6e
    [    5.942413] pru_rproc_probe:1221: pru-rproc 4b2b4000.pru: memory    debug: pa 0x000000004b2a2400 size 0x100 va 27d04d44
    [    5.953404] remoteproc remoteproc2: 4b2b4000.pru is available
    [    5.959275] pru-rproc 4b2b4000.pru: PRU rproc node pru@4b2b4000 probed successfully
    [    5.967019] ti-iodelay 4844a000.padconf: Set reg 0x190 Delay(a: 274 g: 0), Elements(C=0 F=8)0x29008
    [    5.973703] pru_rproc_probe:1221: pru-rproc 4b2b8000.pru: memory     iram: pa 0x000000004b2b8000 size 0x3000 va 5e359c1e
    [    5.973728] pru_rproc_probe:1221: pru-rproc 4b2b8000.pru: memory  control: pa 0x000000004b2a4000 size 0x400 va 2f2079cd
    [    5.973750] pru_rproc_probe:1221: pru-rproc 4b2b8000.pru: memory    debug: pa 0x000000004b2a4400 size 0x100 va 08ecdb32
    [    5.973877] remoteproc remoteproc3: 4b2b8000.pru is available
    [    5.973955] pru-rproc 4b2b8000.pru: PRU rproc node pru@4b2b8000 probed successfully
    [    5.974983] NET: Registered protocol family 10
    [    5.986234] Segment Routing with IPv6
    [    5.986301] sit: IPv6, IPv4 and MPLS over IPv4 tunneling driver
    [    5.986887] NET: Registered protocol family 17
    [    5.986903] can: controller area network core (rev 20170425 abi 9)
    [    5.986986] NET: Registered protocol family 29
    [    5.987009] can: raw protocol (rev 20170425)
    [    5.987014] can: broadcast manager protocol (rev 20170425 t)
    [    5.987027] can: netlink gateway (rev 20170425) max_hops=1
    [    5.987395] Key type dns_resolver registered
    [    5.987579] Registering SWP/SWPB emulation handler
    [    5.987585] omap_voltage_late_init: Voltage driver support not added
    [    5.987589] Power Management for TI OMAP4+ devices.
    [    5.988414] Loading compiled-in X.509 certificates
    [    6.028370] dmm 4e000000.dmm: workaround for errata i878 in use
    [    6.030960] dmm 4e000000.dmm: initialized all PAT entries
    [    6.031959] gpio gpiochip8: (gpio-192-223): added GPIO chardev (254:8)
    [    6.032056] gpiochip_setup_dev: registered GPIOs 192 to 223 on device: gpiochip8 (gpio-192-223)
    [    6.032770] gpio gpiochip9: (gpio-224-255): added GPIO chardev (254:9)
    [    6.032862] gpiochip_setup_dev: registered GPIOs 224 to 255 on device: gpiochip9 (gpio-224-255)
    [    6.033255] of_get_named_gpiod_flags: parsed 'gpio' property of node '/fixedregulator-vcc_1v5[0]' - status (0)
    [    6.033753] VCC1V5: supplied by VCC5V
    [    6.034280] of_get_named_gpiod_flags: parsed 'gpio' property of node '/fixedregulator-vcc_1v1[0]' - status (0)
    [    6.034703] VCC1V1: supplied by VCC5V
    [    6.036044] pca953x 3-0020: GPIO lookup for consumer reset
    [    6.036051] pca953x 3-0020: using device tree for GPIO lookup
    [    6.036068] of_get_named_gpiod_flags: can't parse 'reset-gpios' property of node '/ocp/i2c@4807a000/pca9555@20[0]'
    [    6.036082] of_get_named_gpiod_flags: can't parse 'reset-gpio' property of node '/ocp/i2c@4807a000/pca9555@20[0]'
    [    6.036089] pca953x 3-0020: using lookup tables for GPIO lookup
    [    6.036095] pca953x 3-0020: No GPIO consumer reset found
    [    6.036179] pca953x 3-0020: Linked as a consumer to regulator.5
    [    6.036708] gpiochip_find_base: found new base at 472
    [    6.036863] gpio gpiochip10: (pca9555): added GPIO chardev (254:10)
    [    6.036955] gpiochip_setup_dev: registered GPIOs 472 to 487 on device: gpiochip10 (pca9555)
    [    6.230635] ti-iodelay 4844a000.padconf: Set reg 0x194 Delay(a: 162 g: 0), Elements(C=0 F=4)0x29004
    [    6.239746] ti-iodelay 4844a000.padconf: Set reg 0x1a8 Delay(a: 401 g: 0), Elements(C=0 F=12)0x2900c
    [    6.248941] ti-iodelay 4844a000.padconf: Set reg 0x1ac Delay(a: 73 g: 0), Elements(C=0 F=2)0x29002
    [    6.257962] ti-iodelay 4844a000.padconf: Set reg 0x1b4 Delay(a: 465 g: 0), Elements(C=1 F=0)0x29020
    [    6.267072] ti-iodelay 4844a000.padconf: Set reg 0x1b8 Delay(a: 115 g: 0), Elements(C=0 F=3)0x29003
    [    6.276180] ti-iodelay 4844a000.padconf: Set reg 0x1c0 Delay(a: 633 g: 0), Elements(C=1 F=5)0x29025
    [    6.285287] ti-iodelay 4844a000.padconf: Set reg 0x1c4 Delay(a: 47 g: 0), Elements(C=0 F=1)0x29001
    [    6.294307] ti-iodelay 4844a000.padconf: Set reg 0x1d0 Delay(a: 935 g: 280), Elements(C=2 F=5)0x29045
    [    6.303591] ti-iodelay 4844a000.padconf: Set reg 0x1d8 Delay(a: 621 g: 0), Elements(C=1 F=4)0x29024
    [    6.312695] ti-iodelay 4844a000.padconf: Set reg 0x1dc Delay(a: 0 g: 0), Elements(C=0 F=0)0x29000
    [    6.321629] ti-iodelay 4844a000.padconf: Set reg 0x1e4 Delay(a: 183 g: 0), Elements(C=0 F=5)0x29005
    [    6.330739] ti-iodelay 4844a000.padconf: Set reg 0x1e8 Delay(a: 0 g: 0), Elements(C=0 F=0)0x29000
    [    6.339673] ti-iodelay 4844a000.padconf: Set reg 0x1f0 Delay(a: 467 g: 0), Elements(C=1 F=0)0x29020
    [    6.348782] ti-iodelay 4844a000.padconf: Set reg 0x1f4 Delay(a: 0 g: 0), Elements(C=0 F=0)0x29000
    [    6.357714] ti-iodelay 4844a000.padconf: Set reg 0x1fc Delay(a: 262 g: 0), Elements(C=0 F=7)0x29007
    [    6.366822] ti-iodelay 4844a000.padconf: Set reg 0x200 Delay(a: 46 g: 0), Elements(C=0 F=1)0x29001
    [    6.375843] ti-iodelay 4844a000.padconf: Set reg 0x364 Delay(a: 684 g: 0), Elements(C=1 F=6)0x29026
    [    6.384951] ti-iodelay 4844a000.padconf: Set reg 0x368 Delay(a: 76 g: 0), Elements(C=0 F=2)0x29002
    

  • Additionally I just found out that sometimes after the hang, some messages from mmc1 pop up.

    [ 6.384951] ti-iodelay 4844a000.padconf: Set reg 0x368 Delay(a: 76 g: 0), Elements(C=0 F=2)0x29002
    [ 16.473557] mmc1: Timeout waiting for hardware cmd interrupt.
    [ 16.479344] mmc1: sdhci: ============ SDHCI REGISTER DUMP ===========
    [ 16.485826] mmc1: sdhci: Sys addr: 0x00000000 | Version: 0x00003302
    [ 16.492306] mmc1: sdhci: Blk size: 0x00000200 | Blk cnt: 0x00000001
    [ 16.498784] mmc1: sdhci: Argument: 0x00010000 | Trn mode: 0x00000013
    [ 16.505267] mmc1: sdhci: Present: 0x01f00000 | Host ctl: 0x00000010
    [ 16.511743] mmc1: sdhci: Power: 0x0000000b | Blk gap: 0x00000000
    [ 16.518223] mmc1: sdhci: Wake-up: 0x00000000 | Clock: 0x00007807
    [ 16.524702] mmc1: sdhci: Timeout: 0x00000004 | Int stat: 0x00000001
    [ 16.531180] mmc1: sdhci: Int enab: 0x027f000b | Sig enab: 0x027f000b
    [ 16.537660] mmc1: sdhci: ACmd stat: 0x00000000 | Slot int: 0x00000001
    [ 16.544140] mmc1: sdhci: Caps: 0x24e90080 | Caps_1: 0x00000f77
    [ 16.550619] mmc1: sdhci: Cmd: 0x00000d1a | Max curr: 0x00000000
    [ 16.557098] mmc1: sdhci: Resp[0]: 0x00000900 | Resp[1]: 0xffffffef
    [ 16.563576] mmc1: sdhci: Resp[2]: 0x8f5903ff | Resp[3]: 0xd00f0032
    [ 16.570052] mmc1: sdhci: Host ctl2: 0x0000000b
    [ 16.574523] mmc1: sdhci: ADMA Err: 0x00000000 | ADMA Ptr: 0xfe458210
    [ 16.580999] mmc1: sdhci: ============================================
    [ 26.713556] mmc1: Timeout waiting for hardware cmd interrupt.
    [ 26.719339] mmc1: sdhci: ============ SDHCI REGISTER DUMP ===========
    [ 26.725817] mmc1: sdhci: Sys addr: 0x00000000 | Version: 0x00003302
    [ 26.732295] mmc1: sdhci: Blk size: 0x00000200 | Blk cnt: 0x00000000
    [ 26.738773] mmc1: sdhci: Argument: 0x00010000 | Trn mode: 0x00000013
    [ 26.745252] mmc1: sdhci: Present: 0x01f00000 | Host ctl: 0x00000010
    [ 26.751731] mmc1: sdhci: Power: 0x0000000b | Blk gap: 0x00000000
    [ 26.758212] mmc1: sdhci: Wake-up: 0x00000000 | Clock: 0x00007807
    [ 26.764693] mmc1: sdhci: Timeout: 0x00000004 | Int stat: 0x00000001
    [ 26.771172] mmc1: sdhci: Int enab: 0x027f000b | Sig enab: 0x027f000b
    [ 26.777650] mmc1: sdhci: ACmd stat: 0x00000000 | Slot int: 0x00000001
    [ 26.784128] mmc1: sdhci: Caps: 0x24e90080 | Caps_1: 0x00000f77
    [ 26.790607] mmc1: sdhci: Cmd: 0x00000d1a | Max curr: 0x00000000
    [ 26.797086] mmc1: sdhci: Resp[0]: 0x00000900 | Resp[1]: 0x00000000
    [ 26.803564] mmc1: sdhci: Resp[2]: 0x00000000 | Resp[3]: 0x00000000
    [ 26.810042] mmc1: sdhci: Host ctl2: 0x0000000b
    [ 26.814514] mmc1: sdhci: ADMA Err: 0x00000000 | ADMA Ptr: 0x00000000
    [ 26.820989] mmc1: sdhci: ============================================
    [ 27.343533] rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:
    [ 27.343545] rcu: 0-...!: (1 GPs behind) idle=59e/1/0x40000000 softirq=0/0 fqs=0
    [ 27.343547] rcu: (detected by 1, t=2131 jiffies, g=-1067, q=1)
    [ 27.343558] Sending NMI from CPU 1 to CPUs 0:
    [ 37.343466] rcu: rcu_preempt kthread starved for 2131 jiffies! g-1067 f0x0 RCU_GP_WAIT_FQS(5) ->state=0x0 ->cpu=0
    [ 37.343469] rcu: RCU grace-period kthread stack dump:
    [ 37.343472] rcu_preempt R running task 0 11 2 0x00000000
    [ 37.343481] Backtrace:
    [ 37.343495] [<c0a6a088>] (__schedule) from [<c0a6a87c>] (schedule+0x68/0x134)
    [ 37.343503] r10:00000005 r9:c1206100 r8:eed54740 r7:ee8bdecc r6:c1208488 r5:ee89d280
    [ 37.343506] r4:ffffe000
    [ 37.343515] [<c0a6a814>] (schedule) from [<c0a6d47c>] (schedule_timeout+0x1b0/0x2d4)
    [ 37.343519] r5:eed54740 r4:ffff8d2d
    [ 37.343534] [<c0a6d2cc>] (schedule_timeout) from [<c02aa5c0>] (rcu_gp_kthread+0x62c/0xb20)
    [ 37.343541] r9:c121cbda r8:c121cbcc r7:c121cbd8 r6:c1206100 r5:00000001 r4:c121ca00
    [ 37.343553] [<c02a9f94>] (rcu_gp_kthread) from [<c025037c>] (kthread+0x160/0x168)
    [ 37.343556] r7:ee8bc000
    [ 37.343564] [<c025021c>] (kthread) from [<c02010e0>] (ret_from_fork+0x14/0x34)
    [ 37.343569] Exception stack(0xee8bdfb0 to 0xee8bdff8)
    [ 37.343574] dfa0: 00000000 00000000 00000000 00000000
    [ 37.343579] dfc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
    [ 37.343584] dfe0: 00000000 00000000 00000000 00000000 00000013 00000000
    [ 37.343591] r10:00000000 r9:00000000 r8:00000000 r7:00000000 r6:00000000 r5:c025021c
    [ 37.343594] r4:ee878240
    

  • *** UPDATE ***

    I was able to determine the reason for the kernel freeze, but I still don't know the root cause for it.

    Apparently there is a NULL pointer dereference in a child device of pruss2_mdio

    / ocp {

    pruss_soc_bus2: pruss-soc-bus@4b2a6004 {

    pruss2: pruss@4b280000 {

    pruss2_mdio: mdio@4b2b2400 {

    compatible = "ti,davinci_mdio";
    reg = <0x4b2b2400 0x90>;
    #address-cells = <1>;
    #size-cells = <0>;
    clocks = <&dpll_gmac_h13x2_ck>;
    clock-names = "fck";
    bus_freq = <1000000>;
    status = "okay";

    reset-gpios = <&expander1 6 GPIO_ACTIVE_LOW>,
    <&expander1 7 GPIO_ACTIVE_LOW>;
    reset-delay-us = <2>;
    dp83822_0: ethernet-phy@0 {
    reg = <0>;
    };

    dp83822_1: ethernet-phy@1 {
    reg = <1>;
    };

    };

    };

    };

    };

    The failure occurs in kernel/base/core.c, device_reorder_to_tail():

    [ 18.541401] device_reorder_to_tail:133
    [ 18.541406] device_reorder_to_tail:140 dev->of_node->name=display
    [ 18.541410] device_reorder_to_tail:142 dev->of_node->full_name=display
    [ 18.541416] devices_kset_move_last:1405: devices_kset: Moving display to end of list
    [ 18.541421] device_reorder_to_tail:156
    [ 18.541427] device_pm_move_last:190: PM: Moving platform:display to end of list
    [ 18.541431] device_reorder_to_tail:161
    [ 18.541435] device_for_each_child:2331
    [ 18.541441] device_reorder_to_tail:164
    [ 18.541445] device_reorder_to_tail:165 dev=41b93a8c
    [ 18.541450] device_reorder_to_tail:166 dev->links=637eab83
    [ 18.541454] device_reorder_to_tail:167 &dev->links.consumers=785e9172
    [ 18.541459] device_reorder_to_tail:168 (&dev->links.consumers)->next=785e9172
    [ 18.541463] device_reorder_to_tail:169 list_first_entry=06f5ab22
    [ 18.541466] device_reorder_to_tail:183
    [ 18.541475] deferred_probe_work_func:109: platform display: Retrying from deferred list
    [ 18.541787] driver_probe_device:650: bus: 'platform': driver_probe_device: matched device display with driver panel-simple
    [ 18.541801] really_probe:471: bus: 'platform': really_probe: probing driver panel-simple with device display
    [ 18.541818] pinctrl_bind_pins:34: panel-simple display: no pinctrl handle
    [ 18.541983] really_probe:558: platform display: Driver panel-simple requests probe deferral
    [ 18.541991] driver_deferred_probe_add:123: platform display: Added to deferred list
    [ 18.542139] device_reorder_to_tail:133
    [ 18.542145] device_reorder_to_tail:140 dev->of_node->name=mdio
    [ 18.542149] device_reorder_to_tail:142 dev->of_node->full_name=mdio@4b2b2400
    [ 18.542156] devices_kset_move_last:1405: devices_kset: Moving 4b2b2400.mdio to end of list
    [ 18.542161] device_reorder_to_tail:156
    [ 18.542167] device_pm_move_last:190: PM: Moving platform:4b2b2400.mdio to end of list
    [ 18.542171] device_reorder_to_tail:161
    [ 18.542175] device_for_each_child:2331
    [ 18.542180] device_for_each_child:2335

    [ 18.542183] device_reorder_to_tail:133
    [ 18.542187] device_reorder_to_tail:156
    [ 18.542191] device_reorder_to_tail:161
    [ 18.542194] device_reorder_to_tail:164
    [ 18.542199] device_reorder_to_tail:165 dev=7f09bcba
    [ 18.542203] device_reorder_to_tail:166 dev->links=4d4df84e
    [ 18.542207] device_reorder_to_tail:167 &dev->links.consumers=2204f6ef
    [ 18.542212] device_reorder_to_tail:168 (&dev->links.consumers)->next= (null)
    [ 18.542216] device_reorder_to_tail:169 list_first_entry=1aa4b651
    [ 18.542225] Unable to handle kernel NULL pointer dereference at virtual address 00000008
    [ 18.542230] pgd = adf4f580
    [ 18.542234] [00000008] *pgd=80000080004003, *pmd=00000000
    [ 18.542246] Internal error: Oops: 206 [#1] PREEMPT SMP ARM
    [ 18.542250] Modules linked in:
    [ 18.542260] CPU: 0 PID: 107 Comm: kworker/0:2 Not tainted 4.19.94-rt39-00001-gfddbcaf282c9-dirty #9
    [ 18.542263] Hardware name: Generic DRA74X (Flattened Device Tree)
    [ 18.542274] Workqueue: events deferred_probe_work_func
    [ 18.542286] PC is at device_reorder_to_tail+0x1dc/0x210
    [ 18.542296] LR is at vprintk_emit+0xf0/0x174
    [ 18.542300] pc : [<c06f5cb4>] lr : [<c0294168>] psr: a0000013
    [ 18.542303] sp : edb3fe50 ip : edb3fda8 fp : edb3fe64
    [ 18.542307] r10: ede5f410 r9 : c1267490 r8 : c0c713cc
    [ 18.542311] r7 : 00000000 r6 : c06f5ad8 r5 : ede6c10c r4 : fffffffc
    [ 18.542314] r3 : 00000000 r2 : 00000000 r1 : 00000000 r0 : 00000034
    [ 18.542319] Flags: NzCv IRQs on FIQs on Mode SVC_32 ISA ARM Segment user
    [ 18.542323] Control: 30c5387d Table: 80003000 DAC: fffffffd
    [ 18.542328] Process kworker/0:2 (pid: 107, stack limit = 0x89b88bfb)
    [ 18.542333] Stack: (0xedb3fe50 to 0xedb40000)
    [ 18.542338] fe40: ede6c090 c0e3406c edb3fe9c edb3fe68
    [ 18.542344] fe60: c06f5a9c c06f5ae4 edb3fe8c edef3240 ed9abc44 c120bc88 edb3fe94 ede5f410
    [ 18.542350] fe80: ede5f410 c12416c0 c1267478 c0e4f89c edb3feb4 edb3fea0 c06f5c08 c06f5a14
    [ 18.542356] fea0: 00000001 ede5f410 edb3fed4 edb3feb8 c06f4a34 c06f5ae4 c1241948 c1241948
    [ 18.542362] fec0: c1241980 c1267478 edb3ff04 edb3fed8 c06f795c c06f4a10 edb3ff04 c124199c
    [ 18.542367] fee0: edb11300 eed453c0 eed48800 00000000 c12419a0 00000000 edb3ff3c edb3ff08
    [ 18.542373] ff00: c0249b54 c06f78f0 edb3ff24 edb3ff18 c024bc70 eed453c0 edb11314 eed453e4
    [ 18.542378] ff20: c1207d00 00000008 eed453c0 edb11300 edb3ff74 edb3ff40 c024b8fc c02499a4
    [ 18.542383] ff40: edb3ff74 edb3e000 c02501e0 edb11400 edb10900 00000000 edb3e000 edb11300
    [ 18.542389] ff60: edb11428 ee4b7e70 edb3ffac edb3ff78 c025088c c024b6b8 c023d63c c024b6ac
    [ 18.542394] ff80: 00000000 edb10900 c025075c 00000000 00000000 00000000 00000000 00000000
    [ 18.542399] ffa0: 00000000 edb3ffb0 c02010e0 c0250768 00000000 00000000 00000000 00000000
    [ 18.542404] ffc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
    [ 18.542409] ffe0: 00000000 00000000 00000000 00000000 00000013 00000000 00000000 00000000
    [ 18.542411] Backtrace:
    [ 18.542424] [<c06f5ad8>] (device_reorder_to_tail) from [<c06f5a9c>] (device_for_each_child.part.0+0x94/0xd0)
    [ 18.542429] r5:c0e3406c r4:ede6c090
    [ 18.542439] [<c06f5a08>] (device_for_each_child.part.0) from [<c06f5c08>] (device_reorder_to_tail+0x130/0x210)
    [ 18.542445] r8:c0e4f89c r7:c1267478 r6:c12416c0 r5:ede5f410 r4:ede5f410
    [ 18.542455] [<c06f5ad8>] (device_reorder_to_tail) from [<c06f4a34>] (device_pm_move_to_tail+0x30/0x4c)
    [ 18.542460] r5:ede5f410 r4:00000001
    [ 18.542468] [<c06f4a04>] (device_pm_move_to_tail) from [<c06f795c>] (deferred_probe_work_func+0x78/0xd0)
    [ 18.542473] r7:c1267478 r6:c1241980 r5:c1241948 r4:c1241948
    [ 18.542481] [<c06f78e4>] (deferred_probe_work_func) from [<c0249b54>] (process_one_work+0x1bc/0x3bc)
    [ 18.542487] r10:00000000 r9:c12419a0 r8:00000000 r7:eed48800 r6:eed453c0 r5:edb11300
    [ 18.542490] r4:c124199c
    [ 18.542497] [<c0249998>] (process_one_work) from [<c024b8fc>] (worker_thread+0x250/0x510)
    [ 18.542504] r10:edb11300 r9:eed453c0 r8:00000008 r7:c1207d00 r6:eed453e4 r5:edb11314
    [ 18.542506] r4:eed453c0
    [ 18.542515] [<c024b6ac>] (worker_thread) from [<c025088c>] (kthread+0x130/0x160)
    [ 18.542521] r10:ee4b7e70 r9:edb11428 r8:edb11300 r7:edb3e000 r6:00000000 r5:edb10900
    [ 18.542524] r4:edb11400
    [ 18.542532] [<c025075c>] (kthread) from [<c02010e0>] (ret_from_fork+0x14/0x34)
    [ 18.542535] Exception stack(0xedb3ffb0 to 0xedb3fff8)
    [ 18.542540] ffa0: 00000000 00000000 00000000 00000000
    [ 18.542545] ffc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
    [ 18.542550] ffe0: 00000000 00000000 00000000 00000000 00000013 00000000
    [ 18.542556] r10:00000000 r9:00000000 r8:00000000 r7:00000000 r6:00000000 r5:c025075c
    [ 18.542559] r4:edb10900
    [ 18.542566] Code: e2843004 e1550003 0a000005 e3a01000 (e594000c)
    [ 18.542572] ---[ end trace 0000000000000002 ]---

  • Hi Michael,

    Appreciate you providing additional information during your debug.  Did you trim your ethernet-phy child nodes for brevity, or is what you have posted here the entire set of properties?

    Taking a look at am57xx-idk-common.dtsi, I see we have additional properties in the ethernet-phy child.  So far I've not determined if these are required or optional, but will be testing on my end with these removed.  Can you try adding these on your end and report if it makes a difference?

    &pruss2_mdio {
    	status = "okay";
    	pruss2_eth0_phy: ethernet-phy@0 {
    		reg = <0>;
    		interrupt-parent = <&gpio3>;
    		interrupts = <30 IRQ_TYPE_EDGE_FALLING>;
    	};
    
    	pruss2_eth1_phy: ethernet-phy@1 {
    		reg = <1>;
    		interrupt-parent = <&gpio3>;
    		interrupts = <31 IRQ_TYPE_EDGE_FALLING>;
    	};
    };

    Regards,
    Mike

  • Hello Mike,

    because the last call to device_reorder_to_tail() prior to the kernel oops was for the device pruss2_mdio, I posted just that node in its final form (after including dra7.dtsi in our baseboard dts, we set status to "okay" and add reset-gpios, reset-delay-us and the two ethernet-phys). I copied the trees from our ti-kernel v4.9.77 setup.

    Thanks for your suggestion. I added interrupt-parent and interrupts but still experience the NULL pointer as previous.

    But what helped was the following:

    Cherry-picking the commit https://git.ti.com/cgit/ti-linux-kernel/ti-linux-kernel/commit/?h=ti-rt-linux-4.9.y&id=df96050b97326d66f800b74535c6a03175dbae23&context=3&ignorews=0&dt=0 onto ti2019.06-rt.
    Why was it left out?

    Now the NULL pointer exception and freeze disappears, allowing to boot to login prompt. Alright, this would formerly close this issue, but I am still unable to use PRU for my needs (ethernet).

    I found additional changes from v4.9.77. 

    1) The platform driver drivers/remoteproc/pruss.c is completely missing in v4.19.94. This forces me to adapt to drivers/remoteproc/pru_rproc.c. Why?

    2) As I have ethernet phys on the PRU, I intend to use the prueth driver in drivers/net/ethernet/ti/prueth.c. This one does not even have the same commit history between the two kernel versions. I am forced to adapt to the v4.19's prueth.c (add references "mii-rt" and "iep", rename reference "pruss" to "prus"). Why?
        This is where it now hangs. 

    [ 6.008892] davinci_mdio 4b2b2400.mdio: GPIO lookup for consumer reset
    [ 6.015469] davinci_mdio 4b2b2400.mdio: using device tree for GPIO lookup
    [ 6.022325] davinci_mdio 4b2b2400.mdio: No GPIO consumer reset found
    [ 6.030818] mdio_bus 48485000.mdio: GPIO lookup for consumer reset
    [ 6.037050] mdio_bus 48485000.mdio: using device tree for GPIO lookup
    [ 6.043547] of_get_named_gpiod_flags: can't parse 'reset-gpios' property of node '/ocp/ethernet@48484000/mdio@48485000[0]'
    [ 6.054671] of_get_named_gpiod_flags: can't parse 'reset-gpio' property of node '/ocp/ethernet@48484000/mdio@48485000[0]'
    [ 6.065704] mdio_bus 48485000.mdio: using lookup tables for GPIO lookup
    [ 6.072364] mdio_bus 48485000.mdio: No GPIO consumer reset found
    [ 6.135010] davinci_mdio 48485000.mdio: davinci mdio revision 1.6, bus freq 1000000
    [ 6.142726] libphy: 48485000.mdio: probed
    [ 6.159417] of_get_named_gpiod_flags: can't parse 'reset-gpios' property of node '/ocp/ethernet@48484000/mdio@48485000/ethernet-phy@2[0]'
    [ 6.174069] of_get_named_gpiod_flags: can't parse 'reset-gpios' property of node '/ocp/ethernet@48484000/mdio@48485000/ethernet-phy@3[0]'
    [ 6.186763] davinci_mdio 48485000.mdio: phy[2]: device 48485000.mdio:02, driver TI DP83867
    [ 6.195087] davinci_mdio 48485000.mdio: phy[3]: device 48485000.mdio:03, driver TI DP83867
    [ 6.204676] cpsw 48484000.ethernet: Detected MACID = 44:ea:d8:13:a4:d6
    [ 6.211359] cpsw 48484000.ethernet: initialized cpsw ale version 1.4
    [ 6.217761] cpsw 48484000.ethernet: ALE Table size 1024
    [ 6.223063] cpsw 48484000.ethernet: cpts: overflow check period 500 (jiffies)
    [ 6.231986] cpsw 48484000.ethernet: cpsw: Detected MACID = 94:e3:6d:3a:1b:a3
    [ 6.236535] ata1: SATA link down (SStatus 0 SControl 300)
    [ 6.247993] __pru_rproc_get:311
    [ 6.251163] ------------[ cut here ]------------
    [ 6.255825] WARNING: CPU: 1 PID: 1 at lib/kobject.c:610 kobject_get+0x58/0x5c
    [ 6.263065] kobject: 'ñ{=5ÙQÕByLq®é;(Ÿßå´ßVd£ÚZ ×šƒïãÀ,wý¬Eá%PÃïΤ^~—SÏÚ©pfÀÍÖ}/÷ˉPñPÇ[¡•·û„Æ]³aРÇAs/J¤Ö2‹¦²ß°ã}Zo{ú2¹}Uÿ0‡õBríÙ¹—åF!ÛhÙ
    [ 6.263065] _h`è¥-׏I°¡YZD„šÎ
    ˜3cÇÿ¥eÅé8&[ã8Æ!Qòø<Èšë>CÈÆÕ8Î7h Õ¨à³Vë$5\/ÞºO¾äÆìm'J3u‡kˆø¦{ø‹æÙoz†²zF#×½wîÛû' (f4e97c10): is not initialized, yet kobject_get() is being called.
    [ 6.296208] Modules linked in:
    [ 6.299294] CPU: 1 PID: 1 Comm: swapper/0 Not tainted 4.19.94-rt39-00003-g72a50a5c7c89-dirty #10
    [ 6.299298] Hardware name: Generic DRA74X (Flattened Device Tree)
    [ 6.299301] Backtrace:
    [ 6.299315] [<c020d828>] (dump_backtrace) from [<c020db58>] (show_stack+0x18/0x1c)
    [ 6.299322] r7:00000009 r6:60000013 r5:00000000 r4:c125da68
    [ 6.299333] [<c020db40>] (show_stack) from [<c0a6834c>] (dump_stack+0x98/0xac)
    [ 6.299342] [<c0a682b4>] (dump_stack) from [<c023056c>] (__warn+0xdc/0xf8)
    [ 6.299348] r7:00000009 r6:c0ea2208 r5:c0a6d3d8 r4:ee4a1c54
    [ 6.299355] [<c0230490>] (__warn) from [<c0230160>] (warn_slowpath_fmt+0x50/0x74)
    [ 6.299362] r9:ee6edc60 r8:eeda1474 r7:ee75b980 r6:ee6edc40 r5:ee4a1c54 r4:c0ea21b8
    [ 6.299369] [<c0230114>] (warn_slowpath_fmt) from [<c0a6d3d8>] (kobject_get+0x58/0x5c)
    [ 6.299372] r3:f18ca000 r2:c0ea21b8
    [ 6.299377] r6:ee6edc40 r5:00000001 r4:ee6edc68
    [ 6.299387] [<c0a6d380>] (kobject_get) from [<c06f23e0>] (get_device+0x1c/0x28)
    [ 6.299390] r4:00000000
    [ 6.299402] [<c06f23c4>] (get_device) from [<c08e6464>] (pru_rproc_get+0x130/0x678)
    [ 6.299413] [<c08e6334>] (pru_rproc_get) from [<c082a508>] (prueth_probe+0x114/0xb50)
    [ 6.299419] r10:eeda1474 r9:ee712810 r8:00000000 r7:eeda17cc r6:eeda1634 r5:00000001
    [ 6.299422] r4:ed8c3f40
    [ 6.299431] [<c082a3f4>] (prueth_probe) from [<c06fac44>] (platform_drv_probe+0x50/0xa4)
    [ 6.299438] r10:c1267738 r9:c124cdf8 r8:00000000 r7:c12af91c r6:c124cdf8 r5:ee712810
    [ 6.299440] r4:00000000
    [ 6.299448] [<c06fabf4>] (platform_drv_probe) from [<c06f8590>] (really_probe+0x254/0x410)
    [ 6.299453] r7:c12af91c r6:00000000 r5:c12af918 r4:ee712810
    [ 6.299459] [<c06f833c>] (really_probe) from [<c06f8954>] (driver_probe_device+0x80/0x1dc)
    [ 6.299465] r10:00000007 r9:c104b840 r8:c1267660 r7:00000000 r6:c124cdf8 r5:c124cdf8
    [ 6.299468] r4:ee712810
    [ 6.299475] [<c06f88d4>] (driver_probe_device) from [<c06f8bf0>] (__driver_attach+0x140/0x15c)
    [ 6.299481] r9:c104b840 r8:c1267660 r7:00000000 r6:c124cdf8 r5:ee712844 r4:ee712810
    [ 6.299489] [<c06f8ab0>] (__driver_attach) from [<c06f6168>] (bus_for_each_dev+0x80/0xc8)
    [ 6.299494] r7:00000000 r6:c06f8ab0 r5:c124cdf8 r4:00000000
    [ 6.299502] [<c06f60e8>] (bus_for_each_dev) from [<c06f7d90>] (driver_attach+0x24/0x2c)
    [ 6.299506] r6:c1241cc8 r5:edaf0580 r4:c124cdf8
    [ 6.299512] [<c06f7d6c>] (driver_attach) from [<c06f769c>] (bus_add_driver+0x1c0/0x264)
    [ 6.299519] [<c06f74dc>] (bus_add_driver) from [<c06f96bc>] (driver_register+0x84/0x124)
    [ 6.299524] r8:c104b860 r7:ffffe000 r6:00000000 r5:c102dbd4 r4:c124cdf8
    [ 6.299532] [<c06f9638>] (driver_register) from [<c06faba0>] (__platform_driver_register+0x48/0x54)
    [ 6.299535] r5:c102dbd4 r4:c1241cc8
    [ 6.299547] [<c06fab58>] (__platform_driver_register) from [<c102dbf0>] (prueth_driver_init+0x1c/0x20)
    [ 6.299550] r5:c102dbd4 r4:c1270800
    [ 6.299559] [<c102dbd4>] (prueth_driver_init) from [<c0202364>] (do_one_initcall+0x60/0x1b0)
    [ 6.299569] [<c0202304>] (do_one_initcall) from [<c1001094>] (kernel_init_freeable+0x230/0x2d4)
    [ 6.299575] r8:c104b860 r7:c1270800 r6:c1270800 r5:c1061058 r4:c0ef1018
    [ 6.299585] [<c1000e64>] (kernel_init_freeable) from [<c0a7d43c>] (kernel_init+0x10/0x118)
    [ 6.299591] r10:00000000 r9:00000000 r8:00000000 r7:00000000 r6:00000000 r5:c0a7d42c
    [ 6.299594] r4:00000000
    [ 6.299602] [<c0a7d42c>] (kernel_init) from [<c02010e0>] (ret_from_fork+0x14/0x34)
    [ 6.299605] Exception stack(0xee4a1fb0 to 0xee4a1ff8)
    [ 6.299610] 1fa0: 00000000 00000000 00000000 00000000
    [ 6.299616] 1fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
    [ 6.299621] 1fe0: 00000000 00000000 00000000 00000000 00000013 00000000
    [ 6.299624] r5:c0a7d42c r4:00000000
    [ 6.299628] ---[ end trace 0000000000000001 ]---
    [ 6.647235] ------------[ cut here ]------------
    [ 6.651893] WARNING: CPU: 1 PID: 1 at lib/refcount.c:153 refcount_inc_checked+0x54/0x58
    [ 6.659951] refcount_t: increment on 0; use-after-free.
    [ 6.665212] Modules linked in:
    [ 6.668296] CPU: 1 PID: 1 Comm: swapper/0 Tainted: G W 4.19.94-rt39-00003-g72a50a5c7c89-dirty #10
    [ 6.668299] Hardware name: Generic DRA74X (Flattened Device Tree)
    [ 6.668301] Backtrace:
    [ 6.668312] [<c020d828>] (dump_backtrace) from [<c020db58>] (show_stack+0x18/0x1c)
    [ 6.668319] r7:00000009 r6:60000013 r5:00000000 r4:c125da68
    [ 6.668327] [<c020db40>] (show_stack) from [<c0a6834c>] (dump_stack+0x98/0xac)
    [ 6.668335] [<c0a682b4>] (dump_stack) from [<c023056c>] (__warn+0xdc/0xf8)
    [ 6.668341] r7:00000009 r6:c0e2283c r5:c0568bb8 r4:ee4a1c44
    [ 6.668347] [<c0230490>] (__warn) from [<c0230160>] (warn_slowpath_fmt+0x50/0x74)
    [ 6.668353] r9:ee6edc60 r8:eeda1474 r7:ee75b980 r6:ee6edc40 r5:ee4a1c44 r4:c0e22878
    [ 6.668361] [<c0230114>] (warn_slowpath_fmt) from [<c0568bb8>] (refcount_inc_checked+0x54/0x58)
    [ 6.668365] r3:c125f9e9 r2:c0e22878
    [ 6.668369] r6:ee6edc40 r5:00000001 r4:ee6edc68
    [ 6.668377] [<c0568b64>] (refcount_inc_checked) from [<c0a6d3ac>] (kobject_get+0x2c/0x5c)
    [ 6.668385] [<c0a6d380>] (kobject_get) from [<c06f23e0>] (get_device+0x1c/0x28)
    [ 6.668388] r4:00000000
    [ 6.668397] [<c06f23c4>] (get_device) from [<c08e6464>] (pru_rproc_get+0x130/0x678)
    [ 6.668407] [<c08e6334>] (pru_rproc_get) from [<c082a508>] (prueth_probe+0x114/0xb50)
    [ 6.668413] r10:eeda1474 r9:ee712810 r8:00000000 r7:eeda17cc r6:eeda1634 r5:00000001
    [ 6.668416] r4:ed8c3f40
    [ 6.668424] [<c082a3f4>] (prueth_probe) from [<c06fac44>] (platform_drv_probe+0x50/0xa4)
    [ 6.668430] r10:c1267738 r9:c124cdf8 r8:00000000 r7:c12af91c r6:c124cdf8 r5:ee712810
    [ 6.668433] r4:00000000
    [ 6.668439] [<c06fabf4>] (platform_drv_probe) from [<c06f8590>] (really_probe+0x254/0x410)
    [ 6.668444] r7:c12af91c r6:00000000 r5:c12af918 r4:ee712810
    [ 6.668451] [<c06f833c>] (really_probe) from [<c06f8954>] (driver_probe_device+0x80/0x1dc)
    [ 6.668457] r10:00000007 r9:c104b840 r8:c1267660 r7:00000000 r6:c124cdf8 r5:c124cdf8
    [ 6.668459] r4:ee712810
    [ 6.668466] [<c06f88d4>] (driver_probe_device) from [<c06f8bf0>] (__driver_attach+0x140/0x15c)
    [ 6.668472] r9:c104b840 r8:c1267660 r7:00000000 r6:c124cdf8 r5:ee712844 r4:ee712810
    [ 6.668480] [<c06f8ab0>] (__driver_attach) from [<c06f6168>] (bus_for_each_dev+0x80/0xc8)
    [ 6.668485] r7:00000000 r6:c06f8ab0 r5:c124cdf8 r4:00000000
    [ 6.668493] [<c06f60e8>] (bus_for_each_dev) from [<c06f7d90>] (driver_attach+0x24/0x2c)
    [ 6.668497] r6:c1241cc8 r5:edaf0580 r4:c124cdf8
    [ 6.668503] [<c06f7d6c>] (driver_attach) from [<c06f769c>] (bus_add_driver+0x1c0/0x264)
    [ 6.668509] [<c06f74dc>] (bus_add_driver) from [<c06f96bc>] (driver_register+0x84/0x124)
    [ 6.668515] r8:c104b860 r7:ffffe000 r6:00000000 r5:c102dbd4 r4:c124cdf8
    [ 6.668522] [<c06f9638>] (driver_register) from [<c06faba0>] (__platform_driver_register+0x48/0x54)
    [ 6.668526] r5:c102dbd4 r4:c1241cc8
    [ 6.668535] [<c06fab58>] (__platform_driver_register) from [<c102dbf0>] (prueth_driver_init+0x1c/0x20)
    [ 6.668539] r5:c102dbd4 r4:c1270800
    [ 6.668547] [<c102dbd4>] (prueth_driver_init) from [<c0202364>] (do_one_initcall+0x60/0x1b0)
    [ 6.668555] [<c0202304>] (do_one_initcall) from [<c1001094>] (kernel_init_freeable+0x230/0x2d4)
    [ 6.668561] r8:c104b860 r7:c1270800 r6:c1270800 r5:c1061058 r4:c0ef1018
    [ 6.668571] [<c1000e64>] (kernel_init_freeable) from [<c0a7d43c>] (kernel_init+0x10/0x118)
    [ 6.668577] r10:00000000 r9:00000000 r8:00000000 r7:00000000 r6:00000000 r5:c0a7d42c
    [ 6.668580] r4:00000000
    [ 6.668588] [<c0a7d42c>] (kernel_init) from [<c02010e0>] (ret_from_fork+0x14/0x34)
    [ 6.668591] Exception stack(0xee4a1fb0 to 0xee4a1ff8)
    [ 6.668596] 1fa0: 00000000 00000000 00000000 00000000
    [ 6.668601] 1fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
    [ 6.668606] 1fe0: 00000000 00000000 00000000 00000000 00000013 00000000
    [ 6.668610] r5:c0a7d42c r4:00000000
    [ 6.668612] ---[ end trace 0000000000000002 ]---
    [ 7.026617] __pru_rproc_get:315
    [ 7.029788] Unable to handle kernel NULL pointer dereference at virtual address 00000190
    [ 7.029792] pgd = 31be67a0
    [ 7.029795] [00000190] *pgd=80000080004003, *pmd=00000000
    [ 7.029806] Internal error: Oops: 206 [#1] PREEMPT SMP ARM
    [ 7.029808] Modules linked in:
    [ 7.029816] CPU: 1 PID: 1 Comm: swapper/0 Tainted: G W 4.19.94-rt39-00003-g72a50a5c7c89-dirty #10
    [ 7.029819] Hardware name: Generic DRA74X (Flattened Device Tree)
    [ 7.029826] PC is at do_raw_spin_lock+0xc/0x128
    [ 7.029833] LR is at _raw_spin_lock_irqsave+0x30/0x3c
    [ 7.029837] pc : [<c0285580>] lr : [<c0a82338>] psr: 60000093
    [ 7.029840] sp : ee4a1be8 ip : ee4a1c00 fp : ee4a1bfc
    [ 7.029843] r10: 0000018c r9 : ee6edc60 r8 : 00000002
    [ 7.029846] r7 : 00000000 r6 : 00000000 r5 : 00000000 r4 : 60000013
    [ 7.029849] r3 : ee4a0000 r2 : 00000001 r1 : 11111111 r0 : 0000018c
    [ 7.029854] Flags: nZCv IRQs off FIQs on Mode SVC_32 ISA ARM Segment user
    [ 7.029858] Control: 30c5387d Table: 80003000 DAC: 55555555
    [ 7.029862] Process swapper/0 (pid: 1, stack limit = 0x5766465a)
    [ 7.029866] Stack: (0xee4a1be8 to 0xee4a2000)
    [ 7.029872] 1be0: 60000013 00000000 ee4a1c14 ee4a1c00 c0a82338 c0285580
    [ 7.029878] 1c00: 0000018c 00000000 ee4a1c8c ee4a1c18 c0a8060c c0a82314 00000251 00000000
    [ 7.029884] 1c20: ee4a1c20 11111111 11111111 ee4a1c2c 11111111 11111111 00000000 11111111
    [ 7.029890] 1c40: 11111100 11111111 00000000 11111111 11111111 11111111 11111111 11111111
    [ 7.029895] 1c60: c0295070 c120bc88 c0568bb8 0000018c 00000002 ee6edc40 00000000 eeda1474
    [ 7.029900] 1c80: ee4a1ca4 ee4a1c90 c0a80a00 c0a805b8 00000000 00000001 ee4a1cb4 ee4a1ca8
    [ 7.029906] 1ca0: c0a827ec c0a809b4 ee4a1d14 ee4a1cb8 c08e6490 c0a827e4 ee4a1cec ee4a1cc8
    [ 7.029911] 1cc0: c0a6d544 c0568c80 eed8f99c eeda1634 edaff000 00000001 eeda1634 eeda17cc
    [ 7.029916] 1ce0: ee4a1cfc c120bc88 c08d36b0 ed8c3f40 00000001 eeda1634 eeda17cc 00000000
    [ 7.029922] 1d00: ee712810 eeda1474 ee4a1d6c ee4a1d18 c082a508 c08e6340 c0e3a768 00000001
    [ 7.029927] 1d20: c124cdf8 c1267738 ee4a1d5c ee4a1d38 00000000 c03e0918 00000000 c120bc88
    [ 7.029932] 1d40: ee712818 00000000 ee712810 c124cdf8 c12af91c 00000000 c124cdf8 c1267738
    [ 7.029937] 1d60: ee4a1d8c ee4a1d70 c06fac44 c082a400 ee712810 c12af918 00000000 c12af91c
    [ 7.029943] 1d80: ee4a1dcc ee4a1d90 c06f8590 c06fac00 ee4a1dac ee4a1da0 c0a82778 00000000
    [ 7.029948] 1da0: ee4a1dcc ee712810 c124cdf8 c124cdf8 00000000 c1267660 c104b840 00000007
    [ 7.029953] 1dc0: ee4a1e04 ee4a1dd0 c06f8954 c06f8348 ee4a1df4 ee4a1de0 c0a80a00 c0a805b8
    [ 7.029959] 1de0: ee712810 ee712844 c124cdf8 00000000 c1267660 c104b840 ee4a1e24 ee4a1e08
    [ 7.029964] 1e00: c06f8bf0 c06f88e0 00000000 c124cdf8 c06f8ab0 00000000 ee4a1e54 ee4a1e28
    [ 7.029969] 1e20: c06f6168 c06f8abc ee6000e8 ee6000a4 ee6fede4 c120bc88 c0a82778 c124cdf8
    [ 7.029975] 1e40: edaf0580 c1241cc8 ee4a1e64 ee4a1e58 c06f7d90 c06f60f4 ee4a1e94 ee4a1e68
    [ 7.029980] 1e60: c06f769c c06f7d78 c0e7427c ffffe000 ee4a1e94 c124cdf8 c102dbd4 00000000
    [ 7.029985] 1e80: ffffe000 c104b860 ee4a1eac ee4a1e98 c06f96bc c06f74e8 c1241cc8 c102dbd4
    [ 7.029990] 1ea0: ee4a1ec4 ee4a1eb0 c06faba0 c06f9644 c1270800 c102dbd4 ee4a1ed4 ee4a1ec8
    [ 7.029996] 1ec0: c102dbf0 c06fab64 ee4a1f4c ee4a1ed8 c0202364 c102dbe0 c121f0cc c0deca58
    [ 7.030001] 1ee0: c0deca38 c0deca00 c0dfb994 c0deca14 00000000 00000006 00000006 00000000
    [ 7.030006] 1f00: c0e75464 c12608e0 c10004f0 c0ef1018 c121f0c8 eed60a3c eed60a3f c120bc88
    [ 7.030012] 1f20: c02837a8 c120bc88 c1270800 c0ef1018 c1061058 c1270800 c1270800 c104b860
    [ 7.030017] 1f40: ee4a1f94 ee4a1f50 c1001094 c0202310 00000006 00000006 00000000 c10004f0
    [ 7.030022] 1f60: c10004f0 000000fe c0a82778 00000000 c0a7d42c 00000000 00000000 00000000
    [ 7.030027] 1f80: 00000000 00000000 ee4a1fac ee4a1f98 c0a7d43c c1000e70 00000000 c0a7d42c
    [ 7.030033] 1fa0: 00000000 ee4a1fb0 c02010e0 c0a7d438 00000000 00000000 00000000 00000000
    [ 7.030037] 1fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
    [ 7.030042] 1fe0: 00000000 00000000 00000000 00000000 00000013 00000000 00000000 00000000
    [ 7.030044] Backtrace:
    [ 7.030054] [<c0285574>] (do_raw_spin_lock) from [<c0a82338>] (_raw_spin_lock_irqsave+0x30/0x3c)
    [ 7.030058] r5:00000000 r4:60000013
    [ 7.030066] [<c0a82308>] (_raw_spin_lock_irqsave) from [<c0a8060c>] (rt_mutex_slowlock.constprop.0+0x60/0xdc)
    [ 7.030070] r5:00000000 r4:0000018c
    [ 7.030078] [<c0a805ac>] (rt_mutex_slowlock.constprop.0) from [<c0a80a00>] (__rt_mutex_lock_state+0x58/0x84)
    [ 7.030084] r8:eeda1474 r7:00000000 r6:ee6edc40 r5:00000002 r4:0000018c
    [ 7.030091] [<c0a809a8>] (__rt_mutex_lock_state) from [<c0a827ec>] (_mutex_lock+0x14/0x1c)
    [ 7.030094] r5:00000001 r4:00000000
    [ 7.030104] [<c0a827d8>] (_mutex_lock) from [<c08e6490>] (pru_rproc_get+0x15c/0x678)
    [ 7.030113] [<c08e6334>] (pru_rproc_get) from [<c082a508>] (prueth_probe+0x114/0xb50)
    [ 7.030119] r10:eeda1474 r9:ee712810 r8:00000000 r7:eeda17cc r6:eeda1634 r5:00000001
    [ 7.030122] r4:ed8c3f40
    [ 7.030130] [<c082a3f4>] (prueth_probe) from [<c06fac44>] (platform_drv_probe+0x50/0xa4)
    [ 7.030136] r10:c1267738 r9:c124cdf8 r8:00000000 r7:c12af91c r6:c124cdf8 r5:ee712810
    [ 7.030139] r4:00000000
    [ 7.030146] [<c06fabf4>] (platform_drv_probe) from [<c06f8590>] (really_probe+0x254/0x410)
    [ 7.030151] r7:c12af91c r6:00000000 r5:c12af918 r4:ee712810
    [ 7.030157] [<c06f833c>] (really_probe) from [<c06f8954>] (driver_probe_device+0x80/0x1dc)
    [ 7.030163] r10:00000007 r9:c104b840 r8:c1267660 r7:00000000 r6:c124cdf8 r5:c124cdf8
    [ 7.030165] r4:ee712810
    [ 7.030172] [<c06f88d4>] (driver_probe_device) from [<c06f8bf0>] (__driver_attach+0x140/0x15c)
    [ 7.030178] r9:c104b840 r8:c1267660 r7:00000000 r6:c124cdf8 r5:ee712844 r4:ee712810
    [ 7.030187] [<c06f8ab0>] (__driver_attach) from [<c06f6168>] (bus_for_each_dev+0x80/0xc8)
    [ 7.030191] r7:00000000 r6:c06f8ab0 r5:c124cdf8 r4:00000000
    [ 7.030199] [<c06f60e8>] (bus_for_each_dev) from [<c06f7d90>] (driver_attach+0x24/0x2c)
    [ 7.030203] r6:c1241cc8 r5:edaf0580 r4:c124cdf8
    [ 7.030209] [<c06f7d6c>] (driver_attach) from [<c06f769c>] (bus_add_driver+0x1c0/0x264)
    [ 7.030215] [<c06f74dc>] (bus_add_driver) from [<c06f96bc>] (driver_register+0x84/0x124)
    [ 7.030221] r8:c104b860 r7:ffffe000 r6:00000000 r5:c102dbd4 r4:c124cdf8
    [ 7.030228] [<c06f9638>] (driver_register) from [<c06faba0>] (__platform_driver_register+0x48/0x54)
    [ 7.030231] r5:c102dbd4 r4:c1241cc8
    [ 7.030240] [<c06fab58>] (__platform_driver_register) from [<c102dbf0>] (prueth_driver_init+0x1c/0x20)
    [ 7.030243] r5:c102dbd4 r4:c1270800
    [ 7.030252] [<c102dbd4>] (prueth_driver_init) from [<c0202364>] (do_one_initcall+0x60/0x1b0)
    [ 7.030261] [<c0202304>] (do_one_initcall) from [<c1001094>] (kernel_init_freeable+0x230/0x2d4)
    [ 7.030266] r8:c104b860 r7:c1270800 r6:c1270800 r5:c1061058 r4:c0ef1018
    [ 7.030276] [<c1000e64>] (kernel_init_freeable) from [<c0a7d43c>] (kernel_init+0x10/0x118)
    [ 7.030282] r10:00000000 r9:00000000 r8:00000000 r7:00000000 r6:00000000 r5:c0a7d42c
    [ 7.030284] r4:00000000
    [ 7.030292] [<c0a7d42c>] (kernel_init) from [<c02010e0>] (ret_from_fork+0x14/0x34)
    [ 7.030295] Exception stack(0xee4a1fb0 to 0xee4a1ff8)
    [ 7.030300] 1fa0: 00000000 00000000 00000000 00000000
    [ 7.030305] 1fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
    [ 7.030310] 1fe0: 00000000 00000000 00000000 00000000 00000013 00000000
    [ 7.030314] r5:c0a7d42c r4:00000000
    [ 7.030321] Code: e89da800 e1a0c00d e92dd830 e24cb004 (e5902004)
    [ 7.719718] ---[ end trace 0000000000000003 ]---

    Seems like this section in drivers/remoteproc/pru_rproc.c, __pru_rproc_get() causes this:

    [...]
    
    /* TODO: replace the crude string based check to make sure it is PRU */
    
            if (!strstr(dev_name(&pdev->dev), "pru") &&
                !strstr(dev_name(&pdev->dev), "rtu")) {
                    put_device(&pdev->dev);
                    return ERR_PTR(-ENODEV);
            }
    
            rproc = platform_get_drvdata(pdev);
            put_device(&pdev->dev);
            if (!rproc)
                    return ERR_PTR(-EPROBE_DEFER);
    
            get_device(&rproc->dev);
    
            return rproc;
    }
    

    I guess put_device() belongs in the error path right before return ERR_PTR(-EPROBE_DEFER).

    I doubt that TI would release a kernel this buggy, so I suspect my adaptions to be faulty.
    Do you have the am57xx-idk running with PRU Ethernet ports and TI-Kernel v4.19.y so I can doublecheck my settings?

  • Hi Michael,

    Sorry to hear you're having a touch time with this.

    Where are you pulling your kernel sources from?  You may want to pull from git.ti.com/processor-sdk/processor-sdk-linux.git, and checkout branch processor-sdk-linux-4.19.y because this will have all mainline code, plus patches TI is carrying (and you should not need to cherry-pick anything).

    The reason for this is our PRU code is not yet upstreamed, and had to change to due to the flip-flopping between remoteproc and rpmsg frameworks.

    I do have a setup next to me running the kernel from our latest SDK, and indeed setup to test pru_eth (been working on HSR/ PTP which uses the pru_eth firmware as well).  Let me know if there is something you need tested.

    Regards,
    Mike

  • Hi Mike,

    thanks for your prompt response.

    We wanted a longterm TI kernel with realtime patches. Thus I fetched ti2019.06-rt from git://git.ti.com/ti-linux-kernel/ti-linux-kernel.git

    Is there a difference to the processor-sdk-linux-rt-4.19.y?

    - Michael

  • Hi Michael,

    Sorry, I missed the point you're on the RT kernel.  No problem, you can checkout the processor-sdk-linux-rt-4.19.y branch.

    The  kernel provided with in the processor-sdk-linux repo will have patches we are carrying for this release which includes all the PRU-related support.

    The  ti-linux-kernel forms the core of mailline linux that our SDKs for each product line are built upon.

    Regards,
    Mike

  • Hi Mike,

    I just realized the property "prus" of node pruss2_eth expects references to subnodes pru2_0/pru2_1 (compatible = "ti,am5728-pru"), instead of previously node pruss2 (compatible = "ti,am5728-pruss").

    Now I am down to 

    prueth_netdev_init:1638: prueth pruss2_eth: couldn't connect to phy ethernet-phy@0

    and some weird NULL pointer dereference during udev detection.
    The former is probably board-related.

    What PHYs are there on your am57xx-idk?

  • Michael,

    The IDK has TLK105 PHYs connected to the PRU ports.

    What does mdio report in your kernel logs?  On the IDK, this is what I see:

    [    9.480578] libphy: 4b2b2400.mdio: probed                                                                                                                           
        
    [    9.542341] davinci_mdio 4b2b2400.mdio: phy[0]: device 4b2b2400.mdio:00, driver TI TLK10X 10/100 Mbps PHY                                                           
    [    9.583730] davinci_mdio 4b2b2400.mdio: phy[1]: device 4b2b2400.mdio:01, driver TI TLK10X 10/100 Mbps PHY 

    We want to see something similar on your end.  A common issue here is the bootstrapped address does not match the dts entry.

    Regards,
    Mike

  • Hi Mike,

    PRUs are working now.

    [    5.596434] davinci_mdio 4b2b2400.mdio: phy[0]: device 4b2b2400.mdio:00, driver TI DP83822
    [    5.604754] davinci_mdio 4b2b2400.mdio: phy[1]: device 4b2b2400.mdio:01, driver TI DP83822

    I had to remove the reset-gpio definitions from device tree and thus the cherry-picked commit I mentioned earlier was not needed.

    So as I understand, the ethernet PHYs on the PRU ports cannot be hardware-reset by the driver anymore, right?

    Can any problems arise from that in the future?

    Regards,

    Michael

  • Hello, I finally solved this. 

    Obviously the case occured already on mainline kernel and has been solved already in this commit:
    https://git.ti.com/cgit/ti-linux-kernel/ti-linux-kernel/commit/drivers/net/phy/mdio_bus.c?h=ti-rt-linux-4.19.y&id=3e4cd0677715b4ba2aee3a76f25f144c0f90b3d2

    Unfortunately, by adding support for more than one GPIO, the solution was dropped:

    https://git.ti.com/cgit/ti-linux-kernel/ti-linux-kernel/commit/drivers/net/phy/mdio_bus.c?h=ti-rt-linux-4.19.y&id=2d3751de97a0253f8e2131f49f4566e1dbfa0e64

    Once we add "device_del(&bus->dev);" again, the NULL pointer exception disappears.

    --- a/drivers/net/phy/mdio_bus.c
    +++ b/drivers/net/phy/mdio_bus.c
    @@ -392,6 +392,7 @@ int __mdiobus_register(struct mii_bus *bus, struct module *owner)
                    if (IS_ERR(gpiod)) {
                            dev_err(&bus->dev, "mii_bus %s couldn't get reset GPIO\n",
                                    bus->id);
    +                       device_del(&bus->dev);
                            return PTR_ERR(gpiod);
                    } else  if (gpiod) {
                            bus->reset_gpiod[i] = gpiod;

  • Michael,

    Thank you for posting your solution.

    Regards,
    Mike