gounthar Posted November 29, 2019 Posted November 29, 2019 I went up to step 19, but the board does not boot. I suppose I failed around the copy of the files. sudo cp linux-4.20.17/arch/arm/boot/zImage /media/techforum/1868e640-9660-423a-8dd3-de560bfb2298/boot/zImage-4.20.17 sudo cp linux-4.20.17/arch/arm/boot/dts/sun8i-h2-plus-orangepi-zero.dtb /media/techforum/1868e640-9660-423a-8dd3-de560bfb2298/boot/ sudo cp sunxi-cedar-mainline/boot.scr /media/techforum/1868e640-9660-423a-8dd3-de560bfb2298/boot/ sudo cp sunxi-cedar-mainline/sunxi_cedar.ko /media/techforum/1868e640-9660-423a-8dd3-de560bfb2298/lib/modules/ sudo cp -R modules/lib/modules/4.20.17 /media/techforum/1868e640-9660-423a-8dd3-de560bfb2298/lib/modules/ sudo cp linux-4.20.17/arch/arm/boot/zImage /media/techforum/1868e640-9660-423a-8dd3-de560bfb2298/boot/zImage-4.20.17 sudo cp linux-4.20.17/arch/arm/boot/dts/sun8i-h2-plus-orangepi-zero.dtb /media/techforum/1868e640-9660-423a-8dd3-de560bfb2298/boot/ sudo cp sunxi-cedar-mainline/boot.scr /media/techforum/1868e640-9660-423a-8dd3-de560bfb2298/boot/ sudo cp sunxi-cedar-mainline/sunxi_cedar.ko /media/techforum/1868e640-9660-423a-8dd3-de560bfb2298/lib/modules/ sudo cp -R modules/lib/modules/4.20.17 /media/techforum/1868e640-9660-423a-8dd3-de560bfb2298/lib/modules/ 0 Quote
ubobrov Posted December 5, 2019 Posted December 5, 2019 check what u-boot prints on boot, check your boot.cmd content from which you've made boot.scr 1 Quote
johnty Posted February 8, 2020 Posted February 8, 2020 @ubobrov, Thanks for the work on https://github.com/uboborov/sunxi-cedar-mainline it works pretty good on 4.20.17. To install it on mainline Armbian ( 5.4.16+), follow the dts patch, when the kernel module installed, it showed "could not assign reserved memory" in dmesg. This message comes from "of_reserved_mem_device_init" do you have any clue ? 0 Quote
ubobrov Posted February 8, 2020 Posted February 8, 2020 that happens because of the kernel you're using. be careful with the node: reserved-memory { #address-cells = <1>; #size-cells = <1>; ranges; cma_pool: cma@43c00000 { compatible = "shared-dma-pool"; reusable; reg = <0x43c00000 0x6000000>; linux,cma-default; }; }; it should look like above. to check everything is alright with the CMA, you should check CMA on kernel boot: dmesg | grep CMA [ 0.000000] Reserved memory: created CMA memory pool at 0x43c00000, size 96 MiB it must look like above good luck 0 Quote
johnty Posted February 9, 2020 Posted February 9, 2020 Thanks @ubobrov, tried but did not see dmesg reporting CMA, do you think there is anything conflicted with the built-in Cedrus driver in menuconfig ? my platform is nanopi-duo2 of 512M. --- Media staging drivers │ │ │ │ [*] Allwinner sunXi family Video Devices │ │ │ │ <M> Allwinner Cedrus VPU driver │ │ │ │ *** soc_camera sensor drivers *** Also, may I know the reason cma change from cma@4a000000 to cma@43c00000 at kernel 5.4. 0 Quote
johnty Posted February 13, 2020 Posted February 13, 2020 response my post , also to @ubobrov, I found that node reserved-memory should be outside of SOC, after fixing it , the CMA creating works now. But when installing the sunxi_cedar.ko, it reports "sunxi-cedar 1c0e000.video-engine: syscon failed..." I found the syscon entry is different inside sun8i-h3.dtsi at kernel 5.4.16. 1 Quote
ubobrov Posted February 13, 2020 Posted February 13, 2020 i can't tell you anything about 5x kernel. i haven't tested it yet. 0 Quote
andydj Posted April 22, 2020 Posted April 22, 2020 Hi , hardware encoding is possible on a H6 board whit mainline kernel ? My board is an orange pi one plus 0 Quote
Werner Posted April 22, 2020 Posted April 22, 2020 1 minute ago, andydj said: Hi , hardware encoding is possible on a H6 board whit mainline kernel ? My board is an orange pi one plus Well the module is enabled in sunxi-dev. Just give it a try. 0 Quote
andydj Posted April 22, 2020 Posted April 22, 2020 2 hours ago, Werner said: Well the module is enabled in sunxi-dev. Just give it a try. What I really have to do ? I'm really noob of this board orange pi one plus 0 Quote
Werner Posted April 23, 2020 Posted April 23, 2020 I think you can use armbian-config to switch kernel branch to dev and you should get an Linux 5.6.5 kernel which should have cedrus module shipped with. 0 Quote
ubobrov Posted April 23, 2020 Posted April 23, 2020 Decoding H264 and X11 rendering using vdpau_sunxi, libcedrus, kernel 4.20.17, mpv, vncserver and Armbian Bionic on Orange PI Zero libvdpau: https://github.com/uboborov/libvdpau-sunxi-H3.git libcedrus: https://github.com/uboborov/libcedrus-H3.git cedar_dev: https://github.com/uboborov/sunxi-cedar-mainline.git mpv, ffmpeg, x11 installed using apt It works extremely slow but it's just a beginning ) video: https://www.youtube.com/watch?v=9O7L_kaEDdk UPD: video on Orange PI One 1280x720 HDMI (works pretty fine) https://www.youtube.com/watch?v=8qPyOG-yJIw 1 Quote
gounthar Posted April 23, 2020 Posted April 23, 2020 Super cool, ubobrov! I unfortunately have to address other issues, but I sure will come back one of these days to try H264 encoding on Orange Pi Zero running mainline. 0 Quote
andydj Posted April 24, 2020 Posted April 24, 2020 On 4/23/2020 at 5:46 AM, Werner said: I think you can use armbian-config to switch kernel branch to dev and you should get an Linux 5.6.5 kernel which should have cedrus module shipped with. When i try ti update kernel , i got this message Test install failed. Can't change firmware 0 Quote
Werner Posted April 24, 2020 Posted April 24, 2020 9 minutes ago, andydj said: When i try ti update kernel , i got this message Test install failed. Can't change firmware I just noticed you don't even have to go to dev branch. In current it is enabled already. If your 5.4.x-current kernel is halfway up-to-date you should be able to modprobe cedrus. 1 Quote
ning Posted April 24, 2020 Posted April 24, 2020 15 hours ago, ubobrov said: Decoding H264 and X11 rendering using vdpau_sunxi, libcedrus, kernel 4.20.17, mpv, vncserver and Armbian Bionic on Orange PI Zero libvdpau: https://github.com/uboborov/libvdpau-sunxi-H3.git libcedrus: https://github.com/uboborov/libcedrus-H3.git cedar_dev: https://github.com/uboborov/sunxi-cedar-mainline.git mpv, ffmpeg, x11 installed using apt It works extremely slow but it's just a beginning ) video: https://www.youtube.com/watch?v=9O7L_kaEDdk you enable legacy driver in mainline kernel... great job. 0 Quote
andydj Posted April 24, 2020 Posted April 24, 2020 30 minutes ago, Werner said: I just noticed you don't even have to go to dev branch. In current it is enabled already. If your 5.4.x-current kernel is halfway up-to-date you should be able to modprobe cedrus. Modulo cedrus not found in ...../5.4.28-sunxi64 I think i have to move in h6 board forum 0 Quote
Werner Posted April 24, 2020 Posted April 24, 2020 5 minutes ago, andydj said: Modulo cedrus not found in ...../5.4.28-sunxi64 Check apt-cache search linux-image | grep sunxi I think there should be a newer image available. It is definitly enabled:https://github.com/armbian/build/blob/887ef462fc18a6b91050a1bb1dd46b0e6114087f/config/kernel/linux-sunxi-current.config#L5602 Quote I think i have to move in h6 board forum Not sure how the H6 forums would help in this case since the the OPi Lite is based on the H3. 0 Quote
andydj Posted April 24, 2020 Posted April 24, 2020 My board Is an Opi One + , i'm offtopic here 0 Quote
gafoo Posted April 30, 2020 Posted April 30, 2020 Hi there! Im not familiar with linux systems, but can someone explain me - why libreelec build for orangepi works fine on opi lite even with 1080 videos, when kodi on last armbian lags and uses only cpu time? 0 Quote
jernej Posted April 30, 2020 Posted April 30, 2020 Simple, LibreELEC heavily patches kernel and ffmpeg for better experience. Patches are slowly getting in kernel but ffmpeg patches will need far more time to be accepted (kernel must first declare this API stable which won't happen anytime soon). You also need Kodi master (e.g. Kodi 19 pre-alpha), because it has a lot of important improvements. Last but not least, only Kodi GBM (e.g no desktop environment) version really works well (zero copy playback) and soon wayland. X11 has no chances to work well. TL;DR: LibreELEC uses features which are in development and not present in any stable version yet. BTW, also 4K HEVC videos work well. 1 Quote
gafoo Posted May 1, 2020 Posted May 1, 2020 16 hours ago, jernej said: Simple, LibreELEC heavily patches kernel and ffmpeg for better experience. 16 hours ago, jernej said: Last but not least, only Kodi GBM (e.g no desktop environment) version really works well (zero copy playback) and soon wayland. X11 has no chances to work well. sounds too hard for me lol. but thanks for explanation anyway! 0 Quote
herclogon Posted June 4, 2020 Posted June 4, 2020 @ubobrov Really big thanks, I have spend a lot of time to force Orange Pi Zero encode video with no luck. With you instruction I got a chance to make it works. Tried to do the same as you wrote step-by-step carefully, but kernel module fails with the error in `dmesg`: ``` [ 0.000000] Reserved memory: created CMA memory pool at 0x4a000000, size 96 MiB ... [ 1948.521206] sunxi_cedar: loading out-of-tree module taints kernel. [ 1948.522324] sunxi cedar version 0.1 [ 1948.522598] [cedar]: install start!!! [ 1948.522768] cedar_ve: cedar-ve the get irq is 40 [ 1948.522798] sunxi-cedar 1c0e000.video-engine: assigned reserved memory node cma@4a000000 [ 1949.529005] alloc_contig_range: [4a100, 4f100) PFNs busy [ 1949.531714] alloc_contig_range: [4a200, 4f200) PFNs busy [ 1949.533825] alloc_contig_range: [4a200, 4f300) PFNs busy [ 1949.535770] alloc_contig_range: [4a400, 4f400) PFNs busy [ 1949.537915] alloc_contig_range: [4a400, 4f500) PFNs busy [ 1949.540066] alloc_contig_range: [4a400, 4f600) PFNs busy [ 1949.542753] alloc_contig_range: [4a400, 4f700) PFNs busy [ 1949.544955] alloc_contig_range: [4a800, 4f800) PFNs busy [ 1949.547059] alloc_contig_range: [4a800, 4f900) PFNs busy [ 1949.549338] alloc_contig_range: [4a800, 4fa00) PFNs busy [ 1949.563811] cma: cma_alloc: alloc failed, req-size: 20480 pages, ret: -16 [ 1949.563843] sunxi-cedar 1c0e000.video-engine: cedar: failed to allocate memory buffer ``` Could you please tell the direction in which to dig? Thanks. 0 Quote
ubobrov Posted June 4, 2020 Posted June 4, 2020 Your problem is in Pi Zero's memory. To make driver loaded without errors you should load it on startup. #! /bin/sh ### BEGIN INIT INFO # Provides: cedrus # Required-Start: $syslog # Required-Stop: $syslog # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start daemon at boot time # Description: Enable service provided by daemon. ### END INIT INFO /sbin/insmod /lib/modules/sunxi_cedar.ko exit 0 0 Quote
marine1988 Posted August 15, 2020 Posted August 15, 2020 Hi there for a noob guy is it possible to install the armbian witth hw deconding working on kodi just like on raspberry or i need to do all this stuff? Im don´t know how to compile! 0 Quote
P.P.A. Posted August 16, 2020 Posted August 16, 2020 On 8/15/2020 at 4:19 AM, marine1988 said: Hi there for a noob guy is it possible to install the armbian witth hw deconding working on kodi just like on raspberry or i need to do all this stuff? Im don´t know how to compile! If you only want to use Kodi, take a look at LibreElec: https://forum.libreelec.tv/thread/17565-nightly-images-for-a20-a64-h3-h5-and-h6-boards/ It's got more hardware decoding features than mainline or Armbian thanks to various custom patches for both the kernel and Kodi, but it doesn't do anything other than run Kodi. 0 Quote
Werner Posted August 16, 2020 Posted August 16, 2020 Armbian adopted most of their patches but it seems we are still missing stuff :/ 0 Quote
jernej Posted August 16, 2020 Posted August 16, 2020 Note that ffmpeg patches for request API are important - without patched ffmpeg, all kernel patches have no meaning. Second important thing is that LibreELEC runs Kodi without X11 for ARM boards - this allows to use display more efficiently. On X11 it would be needed to render video through GPU which is less efficient. Note that I never actually tried that. 1 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.