Initilization error for Z7a core

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Initilization error for Z7a core

ソリューションへジャンプ
4,238件の閲覧回数
burak_
Contributor II

 when called Z7CoresInit() inside main() of Z4 cannot build the project. 

getting a error : real-ld.exe: ./SDK/middleware/rsdk/platform_setup/src/PPC/gen_sdk/platform_setup_sdk_sa.o: the target (C1_CODE_START_ADDR) of a R_PPC_VLE_SDA21 relocation is in the wrong output section (*ABS*)

but when using a address location instead of  'C1_CODE_START_ADDR', not getting any error.

void Z7CoresInit(uint8_t coreId)
{
uint32_t mctl = MC_ME->MCTL;
//C1_CODE_START_ADDR = 0x1080000;

switch (coreId)
{
case 1:
// enable core 1 in all modes
MC_ME->CCTL2 = 0x00FE;
// Set Start address for core 1: Will reset and start
MC_ME->CADDR2 = ((uint32_t)&C1_CODE_START_ADDR) | 0x1;
break;

 

Thanks in Advance,

ラベル(1)
0 件の賞賛
1 解決策
4,061件の閲覧回数
burak_
Contributor II

I solved the problem with your guidance. 

this is my flags after adding disable SDA : 

-c -fmessage-length=0 -fstrict-volatile-bitfields -mlra -msdata=eabi -mno-sdata

I removed last 2 command (-msdata=eabi -mno-sdata) and not getting any error. BTW, it  also builded with -mno-sdata.

Thanks for your helping,

 

 

元の投稿で解決策を見る

0 件の賞賛
8 返答(返信)
4,065件の閲覧回数
stanish
NXP Employee
NXP Employee

Hi burak_,

What version of S32DS are you using?

Could you possibly try to add the option to disable Small Data Sections (-mno-sdata) -> basically disable creation of SDA21 relocation as a workaround? Please note that this should have some impact on speed performance.

 

stanish_0-1629822990941.png

Regards,

Stan

0 件の賞賛
4,062件の閲覧回数
burak_
Contributor II

I solved the problem with your guidance. 

this is my flags after adding disable SDA : 

-c -fmessage-length=0 -fstrict-volatile-bitfields -mlra -msdata=eabi -mno-sdata

I removed last 2 command (-msdata=eabi -mno-sdata) and not getting any error. BTW, it  also builded with -mno-sdata.

Thanks for your helping,

 

 

0 件の賞賛
4,170件の閲覧回数
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

could you share the linker file? Is C1_CODE_START_ADDR label defined in the file?

Regards,

Lukas

0 件の賞賛
4,166件の閲覧回数
burak_
Contributor II

Actually, C1_CODE_START_ADDR defined in the SDK linker files. I added project and SDK linker files.

0 件の賞賛
4,149件の閲覧回数
lukaszadrapa
NXP TechSupport
NXP TechSupport

Well, it's not a problem of the linker files in this case. Is it possible to share your project? I was discussing this also with S32DS team but they have no idea based on provided information.

Thanks,

Lukas

0 件の賞賛
4,145件の閲覧回数
burak_
Contributor II

uploaded a example project that getting same error.

Thanks,

0 件の賞賛
4,082件の閲覧回数
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

short update only - I haven't found the root cause yet, so I asked our S32DS experts for help.

Regards,

Lukas

0 件の賞賛
4,193件の閲覧回数
burak_
Contributor II

Anyone have any idea ? I reviewed the RSDK_Demo example, Z7 core also initialize inside the main of z4 like what i try.

0 件の賞賛