From f5ee1f89d03984ed7012810bac3f4ce45edcca58 Mon Sep 17 00:00:00 2001 From: Dmitry Ilyin <6576495+widgetii@users.noreply.github.com> Date: Sun, 17 May 2026 18:35:57 +0300 Subject: [PATCH] =?UTF-8?q?hi3516cv300:=20load=5Fhisilicon=20=E2=80=94=20i?= =?UTF-8?q?nsmod=20hi=5Fosal.ko=20in=20CMA=20branch=20too?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fix issue #2061. insert_osal() picks between the hisi-allocator and the cma-allocator init paths based on whether the kernel cmdline passes mmz=. Both paths are served by the same cv300 OSAL module (open_osal renamed to hi_osal.ko on install by hisilicon-opensdk; mmz_allocator= is a module parameter, not a separate module). The script tried to insmod a cma_osal.ko that no recipe builds: insmod: can't insert 'cma_osal.ko': No such file or directory ******* Error: There's something wrong, please check! ***** Hidden until #2059 / #2060 because load_hisilicon used to bail at the os_mem= guard before ever reaching insert_osal. Post-#2060 the guard is correct and the cma branch runs whenever the bootloader passes mmz=… (qemu-hisilicon, modern U-Boot setups) — zero modules load, majestic comes up with no /dev/mmz. Mirrors how cv500's load_hisilicon already calls the same module on both branches with just the mmz_allocator= arg differing. Closes #2061. --- .../hisilicon-osdrv-hi3516cv300/files/script/load_hisilicon | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/general/package/hisilicon-osdrv-hi3516cv300/files/script/load_hisilicon b/general/package/hisilicon-osdrv-hi3516cv300/files/script/load_hisilicon index 6309731859..5aba07614d 100755 --- a/general/package/hisilicon-osdrv-hi3516cv300/files/script/load_hisilicon +++ b/general/package/hisilicon-osdrv-hi3516cv300/files/script/load_hisilicon @@ -57,7 +57,7 @@ insert_osal() if [ -z "$MMZ" ]; then insmod hi_osal.ko anony=1 mmz_allocator=hisi mmz=anonymous,0,$mmz_start,$mmz_size || report_error else - insmod cma_osal.ko anony=1 mmz_allocator=cma mmz=$MMZ || report_error + insmod hi_osal.ko anony=1 mmz_allocator=cma mmz=$MMZ || report_error fi }