Skip to content
View in the app

A better way to browse. Learn more.

Armbian Community Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Dynamic loading of Overlays in 5.0.y

Featured Replies

I've done a discovery : when using current Armbian overlays in 5.0.y thru dynamic loading (aka : /sys/kernel/config/devices-tree/overlays) , although working, it produced the following warning in "dmesg" :

 

WARNING: memory leak will occur if overlay removed

 

Example, loading i2c overlays produce :

[   80.494728] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /aliases/i2c0
[   80.494745] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /aliases/i2c1
[   80.494752] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /aliases/i2c2
[   80.494789] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /soc/i2c@1c2ac00/status
[   80.494798] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /soc/i2c@1c2b000/clock-frequency
[   80.494805] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /soc/i2c@1c2b000/status
[   80.494813] OF: overlay: WARNING: memory leak will occur if overlay removed, property: /soc/i2c@1c2b400/status

Googling reveal those links, it is all about overlays refactoring :

 

https://lkml.org/lkml/2018/10/5/146

https://elinux.org/images/8/86/Overlay_frank.pdf

 

So, we will have to upgrade those overlays when we get a change ... :unsure:

12 hours ago, Werner said:

4.20 has been archvied https://github.com/armbian/build/releases/tag/sunxi-4.20 so I assume 5.0 can be pushed directly to master. And if it breaks does not matter as it is dev.

 

Fair enough.  I know the branch conversation has happened more than once on the forum, and generally the added complexity hasnt been appealing.   

 

I suppose viewing armbian as a rolling release and embracing next as "mainline stable" supports the model?

1 hour ago, martinayotte said:

I've committed the initial stuff ! :rolleyes:

Now, I will pursue the patch cleaning ...

Let me know if you are unable to build 5.0.y on some Allwinner boards ...

 

Crashed on DTS patches for H6 OpiOnePlus

 

Spoiler

h/arm64/boot/dts/allwinner/overlay/sun50i-a64-spi-jedec-nor.dts:12.13-17.6: Warning (spi_bus_reg): /fragment@0/__overlay__/spiflash: SPI bus unit address format error, expected "0"
arch/arm64/boot/dts/allwinner/overlay/sun50i-a64-spi-jedec-nor.dts:26.13-31.6: Warning (spi_bus_reg): /fragment@1/__overlay__/spiflash: SPI bus unit address format error, expected "0"
  DTC     arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi-one-plus.dtb
  HOSTCC  scripts/selinux/mdp/mdp
  DTC     arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi-lite2.dtb
  DTC     arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dtb
  DTCO    arch/arm64/boot/dts/allwinner/overlay/sun50i-a64-spi-spidev.dtbo
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi:1006.16-1055.4: ERROR (duplicate_node_names): /thermal-zones: Duplicate node name
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi:324.22-333.5: ERROR (duplicate_node_names): /soc/efuse@3006000: Duplicate node name
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi:882.20-892.5: ERROR (duplicate_node_names): /soc/ths@5070400: Duplicate node name
ERROR: Input tree has errors, aborting (use -f to force output)
  DTCO    arch/arm64/boot/dts/allwinner/overlay/sun50i-a64-uart1.dtbo
scripts/Makefile.lib:304: recipe for target 'arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi-one-plus.dtb' failed
make[2]: *** [arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi-one-plus.dtb] Error 2
make[2]: *** Waiting for unfinished jobs....
  DTCO    arch/arm64/boot/dts/allwinner/overlay/sun50i-a64-uart2.dtbo
  DTCO    arch/arm64/boot/dts/allwinner/overlay/sun50i-a64-uart3.dtbo
arch/arm64/boot/dts/allwinner/overlay/sun50i-a64-spi-spidev.dts:20.11-25.6: Warning (spi_bus_reg): /fragment@1/__overlay__/spidev: SPI bus unit address format error, expected "0"
arch/arm64/boot/dts/allwinner/overlay/sun50i-a64-spi-spidev.dts:34.11-39.6: Warning (spi_bus_reg): /fragment@2/__overlay__/spidev: SPI bus unit address format error, expected "0"
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi:1006.16-1055.4: ERROR (duplicate_node_names): /thermal-zones: Duplicate node name
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi:324.22-333.5: ERROR (duplicate_node_names): /soc/efuse@3006000: Duplicate node name
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi:882.20-892.5: ERROR (duplicate_node_names): /soc/ths@5070400: Duplicate node name
  DTCO    arch/arm64/boot/dts/allwinner/overlay/sun50i-a64-uart4.dtbo
ERROR: Input tree has errors, aborting (use -f to force output)
scripts/Makefile.lib:304: recipe for target 'arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi-lite2.dtb' failed
make[2]: *** [arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi-lite2.dtb] Error 2
  HOSTCC  scripts/pnmtologo
 



ill try some other boards.

34 minutes ago, martinayotte said:

Great ! Happy 5.0.y ! :D



totally!

 

Spoiler

lane@orangepioneplus:~$ sudo armbianmonitor -z
[sudo] password for lane: 
Preparing benchmark. Be patient please...

7-Zip (a) [64] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21
p7zip Version 16.02 (locale=C,Utf16=off,HugeFiles=on,64 bits,4 CPUs LE)

LE
CPU Freq:   626  1793  1798  1798  1798  1798  1798  1798  1798

RAM size:     991 MB,  # CPU hardware threads:   4
RAM usage:    882 MB,  # Benchmark threads:      4

                       Compressing  |                  Decompressing
Dict     Speed Usage    R/U Rating  |      Speed Usage    R/U Rating
         KiB/s     %   MIPS   MIPS  |      KiB/s     %   MIPS   MIPS

22:       2759   341    787   2685  |      71940   398   1541   6138
23:       2708   351    787   2760  |      66875   398   1454   5786
24:       2573   358    773   2767  |      64136   396   1421   5630
25:       1668   274    694   1905  |      61379   394   1387   5463
----------------------------------  | ------------------------------
Avr:             331    760   2529  |              397   1451   5754
Tot:             364   1105   4142

Monitoring output recorded while running the benchmark:

Time        CPU    load %cpu %sys %usr %nice %io %irq   CPU  C.St.
03:39:01: 1800MHz  0.03  17%   1%  11%   0%   3%   0% 49.7°C  0/7
03:39:06:  480MHz  0.02   0%   0%   0%   0%   0%   0% 49.9°C  0/7
03:39:11: 1800MHz  0.02   1%   0%   0%   0%   0%   0% 49.7°C  0/7
03:39:16: 1800MHz  0.42  59%   1%  57%   0%   0%   0% 69.3°C  0/7
03:39:21: 1320MHz  0.71  95%   0%  94%   0%   0%   0% 75.9°C  2/7
03:39:26: 1800MHz  0.97  87%   1%  85%   0%   0%   0% 74.0°C  0/7
03:39:32: 1800MHz  1.21  96%   0%  95%   0%   0%   0% 75.8°C  0/7
03:39:37: 1800MHz  1.44  80%   1%  78%   0%   0%   0% 74.2°C  0/7
03:39:42: 1320MHz  1.72  92%   1%  90%   0%   0%   0% 68.7°C  0/7
03:39:48: 1800MHz  1.91  95%   1%  94%   0%   0%   0% 71.1°C  2/7
03:39:54: 1800MHz  2.07  77%   1%  75%   0%   0%   0% 68.9°C  0/7
03:39:59: 1800MHz  2.23  86%   1%  84%   0%   0%   0% 75.5°C  2/7
03:40:04: 1800MHz  2.65  91%   1%  89%   0%   0%   0% 69.6°C  0/7
03:40:09: 1320MHz  2.76  96%   1%  94%   0%   0%   0% 77.0°C  2/7
Time        CPU    load %cpu %sys %usr %nice %io %irq   CPU  C.St.
03:40:27: 1800MHz  3.86  88%  27%  37%   0%  23%   0% 73.8°C  0/7
03:40:33: 1800MHz  3.71  76%   6%  69%   0%   0%   0% 73.4°C  0/7
 


 

20190314_233048.jpg

NanoPi Neo2 (non-LTS) also running here with Kernel 5.0.1
i2c0-overlay doesnt show a memory-leak in dmesg

UTF8-charset doesnt seem to work right (lines around the menu) while using de-utf8

[EDIT] also doesnt work on one of my Neo2 with 4.20.7-sunxi64, but one does show it right.
and I copied the putty-session-settings...so putty shouldnt be the problem :(

NanoPi_Neo2_Kernel_501.jpg

  • Author
14 minutes ago, guidol said:

i2c0-overlay doesnt show a memory-leak in dmesg

The memory-leak issue is not when overlays are loaded by U-boot, but only when loaded dynamically using Overlay-FS, aka via /sys/kernel/config/device-tree/overlays/ from userspace, for example :

mkdir /sys/kernel/config/device-tree/overlays/myoverlay
cat myoverlay.dtbo > /sys/kernel/config/device-tree/overlays/myoverlay/dtbo
cat /sys/kernel/config/device-tree/overlays/myoverlay/status

 

5 minutes ago, martinayotte said:

The memory-leak issue is not when overlays are loaded by U-boot, but only when loaded dynamically using Overlay-FS, aka via /sys/kernel/config/device-tree/overlays/ from userspace,

OK, I was thinking about the (dynamic) i2c0 overlay from armbian-config --> /boot/armbianEnv.txt

Spoiler

root@npi-neo2-24(192.168.6.24):/boot# more armbianEnv.txt
verbosity=1
console=serial
overlay_prefix=sun50i-h5
overlays=analog-codec i2c0 usbhost1 usbhost2
rootdev=UUID=d58b2d2f-75c0-411e-b9b9-f5343f6bf276
rootfstype=ext4
usbstoragequirks=0x2537:0x1066:u,0x2537:0x1068:u
 

 

Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.