Announcements

Help us improve the Power & Sensing Selection Guide. Share feedback

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Ralphance
Level 3
Level 3
25 sign-ins 5 likes given First like received

Hello:

    

    When I was debugging code, I encountered syscall # 0 and then jumped to MK while continuing execution_ Exception6_ Syscall.

    I would like to know how these serial numbers correspond to syscall # 0, and what each represents, such as syscall # 1, syscall # 2, and so on.

And then there's how the syscall system functions interact with MK_ Exception6_ Syscall corresponding.

 

Thanks!!!

0 Likes
1 Solution
Di_W
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 250 solutions authored

Syscall #0 still refers to the "exit" system call, which is used to terminate a program or process.Without any specific context or additional information about "MK_Exception6_Syscall" it is difficult to provide a precise explanation. You can refer to https://community.infineon.com/t5/AURIX/about-syscall-0/td-p/316116 for the info on the trap of SYSCALL.

View solution in original post

0 Likes
4 Replies
Di_W
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 250 solutions authored

Syscall #0 still refers to the "exit" system call, which is used to terminate a program or process.Without any specific context or additional information about "MK_Exception6_Syscall" it is difficult to provide a precise explanation. You can refer to https://community.infineon.com/t5/AURIX/about-syscall-0/td-p/316116 for the info on the trap of SYSCALL.

0 Likes
Ralphance
Level 3
Level 3
25 sign-ins 5 likes given First like received

hello:

    Thank you very much for your reply.

    I would like to further understand that I am using syscall # X for input. What values are available for X, the maximum and maximum values, and what do they mean? Is there a detailed document description for this?

 

Thanks!!!

0 Likes
Ralphance
Level 3
Level 3
25 sign-ins 5 likes given First like received

hello:

    Thank you very much for your reply.

    I would also like to further understand syscall # X, which specific X can be, what are the maximum and minimum values, and what each instruction means. Is there a detailed documentation introduction.

 

Thanks!!!

0 Likes
ThNo
Level 4
Level 4
First like given 25 sign-ins 5 solutions authored

Hi Ralphance,

From the naming of the identifiers, this might be related to EB tresos Safety OS / Microkernel?

When the SYSCALL instruction is executed, the TriCore raises Trap Class 6.
The microkernel uses MK_Exception6_Syscall for handling Trap Class 6 (i.e. SYSCALL instructions).

The immediate value used in the SYSCALL identifies the specific SYSCALL/OS service request  (#0 corresponds to “TerminateSelf”, #1 to “ActivateTask”, …  definitions are available in a file named Mk_syscallindex.h).
Since the OS is providing C-callable APIs (which basically perform the corresponding SYSCALL with specific immediate values), there is basically no need from user perspective to “know” the actual coding (also user should not make any specific assumption on it).

Best regards,
ThNo

0 Likes