Dear friends, about hardware platform s32g399a, I used kernel 5.10.158-rt77 from
s32cc_defconfig, but failed to run sample module and got kernel crash with 2 ways,
#1 Method build without poll
step 1 insmod ipc-shm-dev.ko
step 2 insmod ipc-shm-sample.ko ==> crash !
#2 Method build with poll
step 1 insmod ipc-shm-dev.ko
step 2 insmod ipc-shm-sample.ko ==> crash !
--------------------
root@s32g274ardb2:~/release0511/poll# insmod ../ipc-shm-dev.ko
root@s32[ 23.991908] ipc_shm_dev: loading out-of-tree module taints kernel.
g274ardb2:~/release0511/poll# ls
ipc-shm-sample.elf ipc-shm-sample.ko ipc-shm-sample_multi-instance.ko
root@s32g274ardb2:~/release0511/poll# lsmod
Module Size Used by
ipc_shm_dev 40960 0
root@s32g274ardb2:~/release0511/poll# ./ipc-shm-sample.elf
ipc-shm-us-lib: ipc_os_init(): Can't open /home/eric/myspace/nxp/s32g3/modulesinstall/lib/modules/5.10.158-rt77/kernel/extra/ipc-shm-uio.ko module
root@s32g274ardb2:~/release0511/poll# mkdir -p /home/eric/myspace/nxp/s32g3/modulesinstall/lib/modules/5.10.158-rt77/kernel/extra/
root@s32g274ardb2:~/release0511/poll# cp ../ipc-shm-uio.ko /home/eric/myspace/nxp/s32g3/modulesinstall/lib/modules/5.10.158-rt77/kernel/extra/
root@s32g274ardb2:~/release0511/poll# ./ipc-shm-sample.elf
[ 65.459695] ipc-shm-uio 40198000.mscm: GIC Rx IRQ = 24
[ 65.459959] ipc-shm-uio 40198000.mscm: device ready
[ 65.460850] SError Interrupt on CPU7, code 0xbf000002 -- SError
[ 65.460861] CPU: 7 PID: 415 Comm: ipc-shm-sample. Tainted: G O 5.10.158-rt77 #13
[ 65.460867] Hardware name: NXP S32G399A-RDB3 (DT)
[ 65.460872] pstate: 60000000 (nZCv daif -PAN -UAO -TCO BTYPE=--)
[ 65.460878] pc : 000000000040299c
[ 65.460880] lr : 0000000000402900
[ 65.460882] sp : 0000007feb637380
[ 65.460884] x29: 0000007feb637380 x28: 0000000000000000
[ 65.460894] x27: 0000000000000000 x26: 0000000000000000
[ 65.460901] x25: 0000000000000000 x24: 0000000000000000
[ 65.460906] x23: 0000000000000000 x22: 0000000000000000
[ 65.460912] x21: 0000000000401210 x20: 0000000000000000
[ 65.460917] x19: 0000000000404810 x18: 0000000000000000
[ 65.460924] x17: 0000007fb2fc9f40 x16: 0000007fb30a9f18
[ 65.460930] x15: 0000000000000000 x14: 0000000000000120
[ 65.460936] x13: 0000007fb3066108 x12: 0000007fb2cf8150
[ 65.460942] x11: 00000000003d0f00 x10: 0000007fb3086e24
[ 65.460948] x9 : 0000000001798470 x8 : 0000000000000087
[ 65.460953] x7 : 0000000000000000 x6 : 0000007fb2cf8220
[ 65.460959] x5 : 0000007fb2cf88e0 x4 : 00000000004161c8
[ 65.460964] x3 : 0000007fb2cf9008 x2 : 0000000000000000
[ 65.460971] x1 : 0000000000000000 x0 : 0000000000000048
[ 65.460978] Kernel panic - not syncing:
[ 65.460980] Asynchronous SError Interrupt
[ 66.461104] SMP: stopping secondary CPUs
[ 66.596970] Kernel Offset: disabled
[ 66.600436] CPU features: 0x00040022,2000200c
[ 66.604777] Memory Limit: none
[ 66.607819] ---[ end Kernel panic - not syncing: Asynchronous SError Interrupt ]---
Solved! Go to Solution.
Hi,
How are you setting your "project_parameters.mk" file? You are seeing that the specific file is not included under the include path.
Also, are you setting the flag to let EBT copy the project into its workspace?
If so, the generated files are not located at the IPCF example folder, but at the EB tresos folder. You can copy the generated files into the example folder (from EB/tresos/generate to Ipcf_TS_T40D11M40I0R0/examples/EBT/S32G3/Ipcf_Example_S32G399A_M7/generate), since the makefile of the project is configured to search in here, where the file that you are looking is located.
If you do not set the copy flag (as shown above), then your generate/include folder should look as follows:
Which, again, has the file that you are looking for.
Please, let us know.
HI,
Thanks for your feedback.
The Single Instance IPCF 4.8.0 example has a bug, which a patch was provided before.
Once the patch is implemented under the M7 application, you should be able to see it working no problem.
Please, let us know.
Now I am prepared for switching tresos studio method and not sure yet for compilation.
Hi,
How are you setting your "project_parameters.mk" file? You are seeing that the specific file is not included under the include path.
Also, are you setting the flag to let EBT copy the project into its workspace?
If so, the generated files are not located at the IPCF example folder, but at the EB tresos folder. You can copy the generated files into the example folder (from EB/tresos/generate to Ipcf_TS_T40D11M40I0R0/examples/EBT/S32G3/Ipcf_Example_S32G399A_M7/generate), since the makefile of the project is configured to search in here, where the file that you are looking is located.
If you do not set the copy flag (as shown above), then your generate/include folder should look as follows:
Which, again, has the file that you are looking for.
Please, let us know.
Hi,
Thanks for your feedback.
Since "Mcal.h" file is provided under the Base plugin, it seems the problem is the configuration you provided to the makefile. Image below shows the location of the "Mcal.h" file:
How are you configuring the "project_parameters.mk" file?
Please, let us know.
Plus question: could you tell what it will influence by different compilation (ds/tresos), thanks