* [PATCH v2] tools: zynqmp: Fix regex expression around XPm_ConfigObject.
@ 2020-11-24 15:13 Adrian Fiergolski
2020-11-24 15:59 ` Luca Ceresoli
2020-11-25 9:40 ` Michal Simek
0 siblings, 2 replies; 3+ messages in thread
From: Adrian Fiergolski @ 2020-11-24 15:13 UTC (permalink / raw)
To: u-boot
The XPm_ConfigObject array definition generated by Vitis 2020.1 differs from previous Vivado versions (before 2019.2).
-const u32 XPm_ConfigObject[] __attribute__((used, section(".sys_cfg_data"))) = {
+const u32 XPm_ConfigObject[] __attribute__((used, section(".sys_cfg_data"))) =
+#elif defined (__ICCARM__)
+#pragma location = ".sys_cfg_data"
+__root const u32 XPm_ConfigObject[] =
+#endif
+{
Change the matching regex to handle both cases.
Signed-off-by: Adrian Fiergolski <adrian.fiergolski@fastree3d.com>
---
Changes in v2:
Fix the patch tile.
tools/zynqmp_pm_cfg_obj_convert.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/zynqmp_pm_cfg_obj_convert.py b/tools/zynqmp_pm_cfg_obj_convert.py
index dd27f47921..0a44710e1e 100755
--- a/tools/zynqmp_pm_cfg_obj_convert.py
+++ b/tools/zynqmp_pm_cfg_obj_convert.py
@@ -289,7 +289,7 @@ code = in_file.read()
code = re.sub('//.*?\n|/\*.*?\*/', '', code, flags=re.DOTALL)
# remove everything outside the XPm_ConfigObject array definition
-code = re.search('const u32 XPm_ConfigObject.*= {\n(.*)};',
+code = re.search('const u32 XPm_ConfigObject.*=.*{\n(.*)};',
code, flags=re.DOTALL).group(1)
# Process each comma-separated array item
--
2.29.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH v2] tools: zynqmp: Fix regex expression around XPm_ConfigObject.
2020-11-24 15:13 [PATCH v2] tools: zynqmp: Fix regex expression around XPm_ConfigObject Adrian Fiergolski
@ 2020-11-24 15:59 ` Luca Ceresoli
2020-11-25 9:40 ` Michal Simek
1 sibling, 0 replies; 3+ messages in thread
From: Luca Ceresoli @ 2020-11-24 15:59 UTC (permalink / raw)
To: u-boot
Hi,
On 24/11/20 16:13, Adrian Fiergolski wrote:
> The XPm_ConfigObject array definition generated by Vitis 2020.1 differs from previous Vivado versions (before 2019.2).
>
> -const u32 XPm_ConfigObject[] __attribute__((used, section(".sys_cfg_data"))) = {
> +const u32 XPm_ConfigObject[] __attribute__((used, section(".sys_cfg_data"))) =
> +#elif defined (__ICCARM__)
> +#pragma location = ".sys_cfg_data"
> +__root const u32 XPm_ConfigObject[] =
> +#endif
> +{
>
> Change the matching regex to handle both cases.
>
> Signed-off-by: Adrian Fiergolski <adrian.fiergolski@fastree3d.com>
> ---
> Changes in v2:
> Fix the patch tile.
>
> tools/zynqmp_pm_cfg_obj_convert.py | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tools/zynqmp_pm_cfg_obj_convert.py b/tools/zynqmp_pm_cfg_obj_convert.py
> index dd27f47921..0a44710e1e 100755
> --- a/tools/zynqmp_pm_cfg_obj_convert.py
> +++ b/tools/zynqmp_pm_cfg_obj_convert.py
> @@ -289,7 +289,7 @@ code = in_file.read()
> code = re.sub('//.*?\n|/\*.*?\*/', '', code, flags=re.DOTALL)
>
> # remove everything outside the XPm_ConfigObject array definition
> -code = re.search('const u32 XPm_ConfigObject.*= {\n(.*)};',
> +code = re.search('const u32 XPm_ConfigObject.*=.*{\n(.*)};',
> code, flags=re.DOTALL).group(1)
Looks good, thanks.
Reviewed-by: Luca Ceresoli <luca@lucaceresoli.net>
--
Luca
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH v2] tools: zynqmp: Fix regex expression around XPm_ConfigObject.
2020-11-24 15:13 [PATCH v2] tools: zynqmp: Fix regex expression around XPm_ConfigObject Adrian Fiergolski
2020-11-24 15:59 ` Luca Ceresoli
@ 2020-11-25 9:40 ` Michal Simek
1 sibling, 0 replies; 3+ messages in thread
From: Michal Simek @ 2020-11-25 9:40 UTC (permalink / raw)
To: u-boot
On 24. 11. 20 16:13, Adrian Fiergolski wrote:
> The XPm_ConfigObject array definition generated by Vitis 2020.1 differs from previous Vivado versions (before 2019.2).
>
> -const u32 XPm_ConfigObject[] __attribute__((used, section(".sys_cfg_data"))) = {
> +const u32 XPm_ConfigObject[] __attribute__((used, section(".sys_cfg_data"))) =
> +#elif defined (__ICCARM__)
> +#pragma location = ".sys_cfg_data"
> +__root const u32 XPm_ConfigObject[] =
> +#endif
> +{
>
> Change the matching regex to handle both cases.
>
> Signed-off-by: Adrian Fiergolski <adrian.fiergolski@fastree3d.com>
> ---
> Changes in v2:
> Fix the patch tile.
>
> tools/zynqmp_pm_cfg_obj_convert.py | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tools/zynqmp_pm_cfg_obj_convert.py b/tools/zynqmp_pm_cfg_obj_convert.py
> index dd27f47921..0a44710e1e 100755
> --- a/tools/zynqmp_pm_cfg_obj_convert.py
> +++ b/tools/zynqmp_pm_cfg_obj_convert.py
> @@ -289,7 +289,7 @@ code = in_file.read()
> code = re.sub('//.*?\n|/\*.*?\*/', '', code, flags=re.DOTALL)
>
> # remove everything outside the XPm_ConfigObject array definition
> -code = re.search('const u32 XPm_ConfigObject.*= {\n(.*)};',
> +code = re.search('const u32 XPm_ConfigObject.*=.*{\n(.*)};',
> code, flags=re.DOTALL).group(1)
>
> # Process each comma-separated array item
>
Applied for next with two style fixes in commit message.
Thanks,
Michal
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-11-25 9:40 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-24 15:13 [PATCH v2] tools: zynqmp: Fix regex expression around XPm_ConfigObject Adrian Fiergolski
2020-11-24 15:59 ` Luca Ceresoli
2020-11-25 9:40 ` Michal Simek
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.