cancel
Showing results for 
Search instead for 
Did you mean: 

Preempt RT Patch for OpenSTLinux

JSchn.1
Associate III

Has the RT_preempt Patch been tested with OpenSTLinux on a STM32MP1 device? Are there any instructions on how to apply it?

9 REPLIES 9
Fee
Senior

I did patch the 4.19.9 Kernel that the OpenStLinux uses with the PREEMT RT Patch 4.19.10-rt7 (see here: https://mirrors.edge.kernel.org/pub/linux/kernel/projects/rt/4.19/older/) and had no problems using it so far (but I also did not test it fully yet).

How to patch a kernel can be answered by google 😉 (example: https://www.kernel.org/doc/html/v4.10/process/applying-patches.html).

JSchn.1
Associate III

Did you test the Ethernet Port with the RT Patch yet. Did not get that working using the patch-4.19.50. Might recheck with the one you suggested.

Fee
Senior

With the Patch i suggested i had no problems with the Etherne Port

JSchn.1
Associate III

Using the patch you suggested failed compiling for me (I also got the already applied patch message).

linux-4.19.49/kernel/irq/manage.c:399:33: error: ‘struct irq_affinity_notify’ has no member named ‘work’; did you mean ‘swork’?

Could you kindly outline your steps to compile the kernel?

Fee
Senior

Hi,

I took the provided Kernel by STM (the one you find in the wiki: https://wiki.st.com/stm32mpu/wiki/STM32MP1_Developer_Package_-_Linux_kernel). I patched it with the STM patches and after that with the RT patch. I was following the README.HOW_TO that comes with the STM Kernel (you can also find it here:https://wiki.st.com/stm32mpu/nsfr_img_auth.php/b/b9/Linux.README.HOW_TO.txt). Step 3 is the patching process. Following the other steps to build the kernel was successful for me.

I am using the STM SDK Release 1.1.0 and Ubuntu 18.04.

Hope it helps you & good luck!

mishuk
Associate III

I am also interested in RT patch running on STM32MP1 device. So, I duplicate question : has the RT_preempt Patch been tested with OpenSTLinux on a STM32MP1 device? I mean current available OpenSTLinux kernel 5.4.31. Can ST support answer this question ?

Hi @mishuk​,

I asked this question and a ST employee answered the following: "Actually we have sanity checked OpenSTLinux with kernel5.10 and PREEMPT_RT kernel config. But NOT with the full Linux RT patches on top." and then "I remind you that STM32MP15 has been design with a M4 coprocessor precisely to host real-time process and avoid need of Linux-RT in most case."

Hope it helps

Hi @Lukas Brückner​,

I'm following your suggestions but, instead of using the developer package, I'm accessing with "screen" command on Linux. When applying the patch, this error appears:

root@stm32mp1:# patch -p1 < patch-4.19.94-rt38.patch 
patching file arch/Kconfig
patch: can't open 'arch/Kconfig': No such file or directory

Do you know how to solve it?

Hi @Óscar Baselga​ ,

you cannot patch a running kernel. You have to apply the patches to the source code of the kernel and rebuild it then on your own.

For building the kernel you find information in the developer package in the file README.HOW_TO.txt which you can find here too.