Hi,
I'm using imx8mp with 2GB RAM (UHD + camera + AI algorithm)
And I can't clear weston crash below,
Mar 28 04:38:38 imx8mp-lpddr4-evk kernel: alloc_contig_range: [6e400, 703a4) PFNs busy
Mar 28 04:38:38 imx8mp-lpddr4-evk kernel: alloc_contig_range: [72400, 743a4) PFNs busy
Mar 28 04:38:38 imx8mp-lpddr4-evk kernel: alloc_contig_range: [72400, 744a4) PFNs busy
Mar 28 04:38:38 imx8mp-lpddr4-evk kernel: alloc_contig_range: [72400, 745a4) PFNs busy
Mar 28 04:38:38 imx8mp-lpddr4-evk kernel: alloc_contig_range: [72400, 746a4) PFNs busy
Mar 28 04:38:38 imx8mp-lpddr4-evk kernel: alloc_contig_range: [72800, 747a4) PFNs busy
Mar 28 04:38:38 imx8mp-lpddr4-evk kernel: alloc_contig_range: [72800, 748a4) PFNs busy
Mar 28 04:38:38 imx8mp-lpddr4-evk kernel: alloc_contig_range: [72800, 749a4) PFNs busy
Mar 28 04:38:38 imx8mp-lpddr4-evk kernel: alloc_contig_range: [72800, 74aa4) PFNs busy
Mar 28 04:38:38 imx8mp-lpddr4-evk kernel: alloc_contig_range: [72800, 74ba4) PFNs busy
Mar 28 04:38:38 imx8mp-lpddr4-evk weston[474]: g2d_alloc: alloc memory fail with size 33177600!
Mar 28 04:38:39 imx8mp-lpddr4-evk kernel: audit: type=1701 audit(1616906318.984:4): auid=0 uid=0 gid=0 ses=2 pid=474 comm="weston" exe="/usr/bin/weston" sig=11 res=1
Mar 28 04:38:38 imx8mp-lpddr4-evk audit[474]: ANOM_ABEND auid=0 uid=0 gid=0 ses=2 pid=474 comm="weston" exe="/usr/bin/weston" sig=11 res=1
Mar 28 04:38:39 imx8mp-lpddr4-evk systemd-logind[351]: Session c1 logged out. Waiting for processes to exit.
Mar 28 04:38:39 imx8mp-lpddr4-evk ergoai_test[496]: Error reading events from display: Broken pipe
Mar 28 04:38:39 imx8mp-lpddr4-evk systemd[1]: weston.service: Main process exited, code=killed, status=11/SEGV
Mar 28 04:38:39 imx8mp-lpddr4-evk systemd[1]: weston.service: Failed with result 'signal'.
Mar 28 04:38:39 imx8mp-lpddr4-evk systemd[1]: session-c1.scope: Succeeded.
Here is my memory info
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Booting Linux on physical CPU 0x0000000000 [0x410fd034]
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Linux version 5.10.72+ergoai-0.2.1+g366d92006 (oe-user@oe-host) (aarch64-poky-linux-gcc (GCC) 10.2.0, GNU ld (GNU Binutils) 2.36.1.20210209) #1 SMP PREEMPT Mon Sep 26 03:23:54 UTC 2022
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Machine model: NXP i.MX8MPlus board
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: efi: UEFI not found.
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Reserved memory: created CMA memory pool at 0x0000000058000000, size 512 MiB
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: OF: reserved mem: initialized node linux,cma, compatible id shared-dma-pool
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Reserved memory: created DMA memory pool at 0x0000000079f00000, size 1 MiB
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: OF: reserved mem: initialized node vdev0buffer@79f00000, compatible id shared-dma-pool
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: NUMA: No NUMA configuration found
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: NUMA: Faking a node at [mem 0x0000000040000000-0x00000000bfffffff]
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: NUMA: NODE_DATA [mem 0xbfc48700-0xbfc4afff]
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Zone ranges:
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: DMA [mem 0x0000000040000000-0x00000000bfffffff]
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: DMA32 empty
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Normal empty
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Movable zone start for each node
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Early memory node ranges
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: node 0: [mem 0x0000000040000000-0x0000000077ffffff]
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: node 0: [mem 0x0000000078000000-0x0000000079ffffff]
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: node 0: [mem 0x000000007a000000-0x00000000943fffff]
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: node 0: [mem 0x0000000094400000-0x00000000a43fffff]
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: node 0: [mem 0x00000000a4400000-0x00000000bfffffff]
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Initmem setup node 0 [mem 0x0000000040000000-0x00000000bfffffff]
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: On node 0 totalpages: 524288
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: DMA zone: 8192 pages used for memmap
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: DMA zone: 0 pages reserved
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: DMA zone: 524288 pages, LIFO batch:63
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: psci: probing for conduit method from DT.
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: psci: PSCIv1.1 detected in firmware.
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: psci: Using standard PSCI v0.2 function IDs
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: psci: MIGRATE_INFO_TYPE not supported.
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: psci: SMC Calling Convention v1.2
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: percpu: Embedded 23 pages/cpu s56280 r8192 d29736 u94208
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: pcpu-alloc: s56280 r8192 d29736 u94208 alloc=23*4096
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: pcpu-alloc: [0] 0 [0] 1 [0] 2 [0] 3
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Detected VIPT I-cache on CPU0
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: CPU features: detected: ARM erratum 845719
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: CPU features: detected: GIC system register CPU interface
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Built 1 zonelists, mobility grouping on. Total pages: 516096
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Policy zone: DMA
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Kernel command line: console=ttymxc1,115200 root=/dev/mmcblk2p2 rootwait rw
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes, linear)
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes, linear)
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: mem auto-init: stack:off, heap alloc:off, heap free:off
Mar 24 10:25:19 imx8mp-lpddr4-evk kernel: Memory: 1203184K/2097152K available (15744K kernel code, 1388K rwdata, 6080K rodata, 10752K init, 540K bss, 369680K reserved, 524288K cma-reserved)
When weston crash occurs,
Mar 28 04:38:31 CmaFree: 71240 kB
Mar 28 04:38:32 CmaFree: 70728 kB
Mar 28 04:38:33 CmaFree: 71536 kB
Mar 28 04:38:34 CmaFree: 71672 kB
Mar 28 04:38:36 CmaFree: 70540 kB
Mar 28 04:38:37 CmaFree: 71280 kB
Mar 28 04:38:38 CmaFree: 70936 kB
Mar 28 04:38:39 CmaFree: 200108 kB
Mar 28 04:38:40 CmaFree: 200372 kB
Mar 28 04:38:42 CmaFree: 200456 kB
top - 04:38:37 up 3 days, 18:13, 2 users, load average: 3.43, 4.02, 4.22
Tasks: 121 total, 2 running, 119 sleeping, 0 stopped, 0 zombie
%Cpu(s): 33.8 us, 26.8 sy, 0.0 ni, 35.2 id, 0.0 wa, 2.8 hi, 1.4 si, 0.0 st
MiB Mem : 1697.5 total, 642.0 free, 659.7 used, 395.8 buff/cache
MiB Swap: 0.0 total, 0.0 free, 0.0 used. 882.0 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
496 root 20 0 2290104 242480 118396 R 187.5 13.9 8136:44 ergoai_+
494 root 20 0 227840 2036 1780 S 6.2 0.1 55:49.76 MotorUa+
3620738 root 0 -20 0 0 0 I 6.2 0.0 0:10.21 kworker+
3674367 root 20 0 4836 2324 1984 R 6.2 0.1 0:00.02 top
1 root 20 0 92540 7448 5648 S 0.0 0.4 0:10.88 systemd
2 root 20 0 0 0 0 S 0.0 0.0 0:00.38 kthreadd
3 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 rcu_gp
4 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 rcu_par+
8 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 mm_perc+
top - 04:38:38 up 3 days, 18:13, 2 users, load average: 3.43, 4.02, 4.22
Tasks: 122 total, 2 running, 119 sleeping, 0 stopped, 1 zombie
%Cpu(s): 32.8 us, 29.9 sy, 0.0 ni, 34.3 id, 0.0 wa, 1.5 hi, 1.5 si, 0.0 st
MiB Mem : 1697.5 total, 642.0 free, 659.7 used, 395.8 buff/cache
MiB Swap: 0.0 total, 0.0 free, 0.0 used. 882.0 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
496 root 20 0 2290104 242480 118396 R 188.2 13.9 8136:47 ergoai_+
3620738 root 0 -20 0 0 0 I 5.9 0.0 0:10.24 kworker+
1 root 20 0 92540 7448 5648 S 0.0 0.4 0:10.88 systemd
2 root 20 0 0 0 0 S 0.0 0.0 0:00.38 kthreadd
3 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 rcu_gp
4 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 rcu_par+
8 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 mm_perc+
9 root 20 0 0 0 0 S 0.0 0.0 0:00.00 rcu_tas+
10 root 20 0 0 0 0 S 0.0 0.0 0:45.06 ksoftir+
top - 04:38:39 up 3 days, 18:13, 2 users, load average: 3.24, 3.97, 4.20
Tasks: 118 total, 1 running, 117 sleeping, 0 stopped, 0 zombie
%Cpu(s): 0.0 us, 1.5 sy, 0.0 ni, 98.5 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st
MiB Mem : 1697.5 total, 1109.1 free, 361.3 used, 227.1 buff/cache
MiB Swap: 0.0 total, 0.0 free, 0.0 used. 1246.1 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
1 root 20 0 92540 7448 5648 S 0.0 0.4 0:10.97 systemd
2 root 20 0 0 0 0 S 0.0 0.0 0:00.38 kthreadd
3 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 rcu_gp
4 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 rcu_par+
8 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 mm_perc+
9 root 20 0 0 0 0 S 0.0 0.0 0:00.00 rcu_tas+
10 root 20 0 0 0 0 S 0.0 0.0 0:45.06 ksoftir+
11 root 20 0 0 0 0 I 0.0 0.0 3:41.90 rcu_pre+
12 root rt 0 0 0 0 S 0.0 0.0 0:02.18 migrati+