From deb271e7bd756abd42cba4a7f42e574cf92de673 Mon Sep 17 00:00:00 2001 From: Li Hua Qian Date: Tue, 3 Dec 2024 11:00:51 +0800 Subject: [PATCH] meta-hailo: Fix the CMA issue when PVU was integrated PVU-based DMA isolation brings SWIO TLB to the table and the maximum allowable number of contiguous slabs to map is 128 by default, but meta-hailo requires more 128. Hence increase it to 256 when meta-hailo is included. Signed-off-by: Li Hua Qian --- kas/opt/meta-hailo.yml | 4 ++++ recipes-kernel/linux/linux-iot2050-6.1.inc | 2 ++ 2 files changed, 6 insertions(+) diff --git a/kas/opt/meta-hailo.yml b/kas/opt/meta-hailo.yml index b7ba9aeeb..56f85a9c8 100644 --- a/kas/opt/meta-hailo.yml +++ b/kas/opt/meta-hailo.yml @@ -11,6 +11,10 @@ header: version: 14 +local_conf_header: + hailo_override: | + OVERRIDES .= ":meta-hailo" + repos: meta-hailo: path: ${TOPDIR}/../meta-hailo diff --git a/recipes-kernel/linux/linux-iot2050-6.1.inc b/recipes-kernel/linux/linux-iot2050-6.1.inc index 613a53a8e..271768d01 100644 --- a/recipes-kernel/linux/linux-iot2050-6.1.inc +++ b/recipes-kernel/linux/linux-iot2050-6.1.inc @@ -26,6 +26,8 @@ def get_extra_configs(d): if re.search("pvu-dma", overrides): append_config.append('CONFIG_TI_PVU=y') + if re.search("meta-hailo", overrides): + append_config.append('CONFIG_SWIOTLB_SEGSIZE=256') if append_config: append_config_file = os.path.join(d.getVar('T'), 'iot2050_append_config.cfg')