Part Number:TMDSEVM572X
硬件:TMDSEVM572X
软件:Processor SDK Linux 06_03_00_106
问题:无法调整OpenCL的global memory
按照Sizing device side heaps,在程序中设置好相关PARAM_HEAP_SIZE和NETWORK_HEAP_SIZE,发现NETWORK_HEAP_SIZE依然未满足要求。
于是按照Insufficient OpenCL global memory进行以下操作:
(1)把prebuilt_image文件夹的am57xx-evm-reva3.dtb转换成am57xx-evm-reva3.dts
(2)修改am57xx-evm-reva3.dts文件,
a) cmem_block_mem@a0000000部分,“reg = <0x0 0xa0000000 0x0 0xc000000>;”改为“reg = <0x0 0xa0000000 0x0 0x18000000>;”,“phandle”部分改为“linux,phandle = <0x13c>;”
b) cmem_block@0部分,“memory-region”部分改为“memory-region = <0x13c>;”,“cmem-buf-pools = <0x1 0x0 0xc000000>;”改为“cmem-buf-pools = <0x1 0x0 0x18000000>;”,其他删去
(3)dts文件转为dtb文件后复制回/boot,重启
注:把dts文件转回dtb文件有附图报错,我是加了-f参数,强行转换的。推测与此有关,dts文件没有正确配置好。
再次运行程序,报同样错误。程序报错:
谢谢帮助!
Nancy Wang:
我咨询相关工程师后再给您回复。
,
user6446474:
你好。
我今天只对dts文件做以下修改:
(1)cmem_block_mem@a0000000部分,“reg = <0x0 0xa0000000 0x0 0xc000000>;”改为“reg = <0x0 0xa0000000 0x0 0x18000000>;”
(2)cmem_block@0部分,“cmem-buf-pools = <0x1 0x0 0xc000000>;”改为“cmem-buf-pools = <0x1 0x0 0x18000000>;”
dts文件转换dtb文件无报错,但是当我重启设备后,CMEM大小依旧没有变化。希望得到对应解决方案。
谢谢!
,
Nancy Wang:
请将您目前设备树中memory部分的配置直接贴上来,谢谢!
,
user6446474:
memory@0 {device_type = "memory";reg = <0x0 0x80000000 0x0 0x80000000>;};reserved-memory {#address-cells = <0x2>;#size-cells = <0x2>;ranges;ipu2-memory@95800000 {compatible = "shared-dma-pool";reg = <0x0 0x95800000 0x0 0x3800000>;reusable;status = "okay";phandle = <0xa0>;};dsp1-memory@99000000 {compatible = "shared-dma-pool";reg = <0x0 0x99000000 0x0 0x4000000>;reusable;status = "okay";phandle = <0xa6>;};ipu1-memory@9d000000 {compatible = "shared-dma-pool";reg = <0x0 0x9d000000 0x0 0x2000000>;status = "okay";no-map;phandle = <0x99>;};dsp2-memory@9f000000 {compatible = "shared-dma-pool";reg = <0x0 0x9f000000 0x0 0x800000>;reusable;status = "okay";phandle = <0xda>;};mmu-early-page-tables@95700000 {reg = <0x0 0x95700000 0x0 0x100000>;no-map;};cmem_block_mem@a0000000 {reg = <0x0 0xa0000000 0x0 0x18000000>;no-map;status = "okay";phandle = <0xed>;};cmem_block_mem@40500000 {reg = <0x0 0x40500000 0x0 0x100000>;no-map;status = "okay";phandle = <0xee>;};};以上修改了cmem_block_mem@a0000000部分。只修改了reg语句。
cmem {compatible = "ti,cmem";#address-cells = <0x1>;#size-cells = <0x0>;#pool-size-cells = <0x2>;status = "okay";cmem_block@0 {reg = <0x0>;memory-region = <0xed>;cmem-buf-pools = <0x1 0x0 0x18000000>;phandle = <0x211>;};cmem_block@1 {reg = <0x1>;memory-region = <0xee>;phandle = <0x212>;};};以上修改了cmem_block@0部分。只修改了cmem-buf-pools语句。
仅修改以上两个语句,则am57xx-evm.dts和am57xx-evm-reva3.dts都可顺利转换为dtb文件。
,
Nancy Wang:
感谢提供信息,我将您的问题升级到了英文论坛,请关注。
https://e2e.ti.com/support/processors-group/processors/f/processors-forum/1035684/am5728-insufficient-opencl-global-memory
,
user6446474:
谢谢帮助。