diff mbox series

[v2] configs: ls1021a: Append CMA configuration to bootargs

Message ID 20200423143734.39305-1-alison.wang@nxp.com
State Accepted
Commit 33c3dfd2976e0752e69c36b27b88809c9b4ada12
Headers show
Series [v2] configs: ls1021a: Append CMA configuration to bootargs | expand

Commit Message

Alison Wang April 23, 2020, 2:37 p.m. UTC
The default reserved memory for CMA is high memory. If LPAE is enabled,
highmem pages are non-remapped and can not be used with
dma_alloc_coherent. Reserving low memory for CMA is needed for LS1021A.
This patch appends the related CMA configuration to bootargs.

Signed-off-by: Shengzhou Liu <Shengzhou.Liu at nxp.com>
Signed-off-by: Alison Wang <alison.wang at nxp.com>
---
Change in v2:
   - Update the comment.

 include/configs/ls1021atwr.h | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

Comments

Priyanka Jain (OSS) April 24, 2020, 7:42 a.m. UTC | #1
>-----Original Message-----
>From: U-Boot <u-boot-bounces at lists.denx.de> On Behalf Of Alison Wang
>Sent: Thursday, April 23, 2020 8:08 PM
>To: u-boot at lists.denx.de; Priyanka Jain <priyanka.jain at nxp.com>; Jagdish
>Gediya <jagdish.gediya at nxp.com>
>Cc: Shengzhou Liu <shengzhou.liu at nxp.com>
>Subject: [PATCH v2] configs: ls1021a: Append CMA configuration to bootargs
>
>The default reserved memory for CMA is high memory. If LPAE is enabled,
>highmem pages are non-remapped and can not be used with
>dma_alloc_coherent. Reserving low memory for CMA is needed for LS1021A.
>This patch appends the related CMA configuration to bootargs.
>
>Signed-off-by: Shengzhou Liu <Shengzhou.Liu at nxp.com>
>Signed-off-by: Alison Wang <alison.wang at nxp.com>
>---
>Change in v2:
>   - Update the comment.
>
> include/configs/ls1021atwr.h | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
>diff --git a/include/configs/ls1021atwr.h b/include/configs/ls1021atwr.h index
>a6289850ca..45ce460dca 100644
>--- a/include/configs/ls1021atwr.h
>+++ b/include/configs/ls1021atwr.h
>@@ -297,7 +297,8 @@
>
> #ifdef CONFIG_LPUART
> #define CONFIG_EXTRA_ENV_SETTINGS       \
>-	"bootargs=root=/dev/ram0 rw console=ttyLP0,115200
>$othbootargs\0" \
>+	"bootargs=root=/dev/ram0 rw console=ttyLP0,115200 "	\
>+		"cma=64M at 0x0-0xb0000000\0" \
> 	"initrd_high=0xffffffff\0"      \
> 	"fdt_addr=0x64f00000\0"		\
> 	"kernel_addr=0x65000000\0"	\
>@@ -353,7 +354,8 @@
> 		"$kernel_size && bootm $load_addr#$board\0"
> #else
> #define CONFIG_EXTRA_ENV_SETTINGS	\
>-	"bootargs=root=/dev/ram0 rw console=ttyS0,115200 $othbootargs\0"
>\
>+	"bootargs=root=/dev/ram0 rw console=ttyS0,115200 "	\
>+		"cma=64M at 0x0-0xb0000000\0" \
> 	"initrd_high=0xffffffff\0"      \
> 	"fdt_addr=0x64f00000\0"		\
> 	"kernel_addr=0x61000000\0"	\
>--
>2.17.1
Reviewed-by: Priyanka Jain <priyanka.jain at nxp.com>
Priyanka Jain (OSS) April 30, 2020, 12:34 p.m. UTC | #2
>-----Original Message-----
>From: U-Boot <u-boot-bounces at lists.denx.de> On Behalf Of Alison Wang
>Sent: Thursday, April 23, 2020 8:08 PM
>To: u-boot at lists.denx.de; Priyanka Jain <priyanka.jain at nxp.com>; Jagdish
>Gediya <jagdish.gediya at nxp.com>
>Cc: Shengzhou Liu <shengzhou.liu at nxp.com>
>Subject: [PATCH v2] configs: ls1021a: Append CMA configuration to bootargs
>
>The default reserved memory for CMA is high memory. If LPAE is enabled,
>highmem pages are non-remapped and can not be used with
>dma_alloc_coherent. Reserving low memory for CMA is needed for LS1021A.
>This patch appends the related CMA configuration to bootargs.
>
>Signed-off-by: Shengzhou Liu <Shengzhou.Liu at nxp.com>
>Signed-off-by: Alison Wang <alison.wang at nxp.com>
>---
Applied to fsl-qoriq. Awaiting upstream

Thanks
Priyanka
diff mbox series

Patch

diff --git a/include/configs/ls1021atwr.h b/include/configs/ls1021atwr.h
index a6289850ca..45ce460dca 100644
--- a/include/configs/ls1021atwr.h
+++ b/include/configs/ls1021atwr.h
@@ -297,7 +297,8 @@ 
 
 #ifdef CONFIG_LPUART
 #define CONFIG_EXTRA_ENV_SETTINGS       \
-	"bootargs=root=/dev/ram0 rw console=ttyLP0,115200 $othbootargs\0" \
+	"bootargs=root=/dev/ram0 rw console=ttyLP0,115200 "	\
+		"cma=64M at 0x0-0xb0000000\0" \
 	"initrd_high=0xffffffff\0"      \
 	"fdt_addr=0x64f00000\0"		\
 	"kernel_addr=0x65000000\0"	\
@@ -353,7 +354,8 @@ 
 		"$kernel_size && bootm $load_addr#$board\0"
 #else
 #define CONFIG_EXTRA_ENV_SETTINGS	\
-	"bootargs=root=/dev/ram0 rw console=ttyS0,115200 $othbootargs\0" \
+	"bootargs=root=/dev/ram0 rw console=ttyS0,115200 "	\
+		"cma=64M at 0x0-0xb0000000\0" \
 	"initrd_high=0xffffffff\0"      \
 	"fdt_addr=0x64f00000\0"		\
 	"kernel_addr=0x61000000\0"	\