From: Michal Simek Date: Tue, 24 Nov 2020 14:01:30 +0100 Subject: [PATCH] tools: The XPm_ConfigObject array definition generated by Vitis 2020.1 differs from previous Vivado versions (before 2019.2). In-Reply-To: <20201124124841.99607-1-adrian.fiergolski@fastree3d.com> References: <20201124124841.99607-1-adrian.fiergolski@fastree3d.com> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Adrian, please fix your subject. tools: zynqmp: Fix regex expression around XPm_ConfigObject And commit message is what you have in subject now. On 24. 11. 20 13:48, Adrian Fiergolski wrote: > -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 > --- > 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 > Luca: When subject is fixed I will wait for your ack. Thanks, Michal