PREEMPT_RT patch version for current Debian 12 v6.1 kernel

More
30 Dec 2023 03:02 #289354 by sky_1
Hello,

I'm setting up a fresh Debian 12 machine, and have downloaded the kernel source onto the target machine to build it there.
uname -r indicates that the version is 6.1.0-16-amd64
I checked out the kernel source version v6.1 since I could see that tag existed.
When I search for the RT patch, on cdn.kernel.org/pub/linux/kernel/projects/rt/6.1/older/
I cannot see a version with a matching number, such as patch-6.1.0.patch.xz 
I don't understand the naming convention. Would the following one be the correct one to select?
patch-6.1-rc7-rt5.patch.xz 
Apologies if this is a basic question. I have searched around and couldn't find an answer.
(I cannot use a pre-built kernel, because I need to patch some extra stuff as well).
Many thanks!
 

Please Log in or Create an account to join the conversation.

More
30 Dec 2023 03:10 #289355 by cornholio
Why not leave the hard work behind and go for this

forum.linuxcnc.org/9-installing-linuxcnc...nly?start=100#289353

If you do want to build your own I'd base it on 6.1.69 kernel

rc7 would point to it being release candidate 7
The following user(s) said Thank You: sky_1

Please Log in or Create an account to join the conversation.

More
30 Dec 2023 05:27 - 30 Dec 2023 05:28 #289358 by sky_1
Hi,
Unfortunately I cannot use a pre-built version, because I need to patch some extra stuff in the kernel (my particular machine requires patches to get some particular hardware to work).
Since my current kernel is 6.1.0-16-amd64 I checked out the v6.1 linux source, with the assumption that if I didn't stray too far ahead in release number then it wouldn't break anything unexpectedly.
What RT patch file should be applied to the v6.1 tagged linux source?
Last edit: 30 Dec 2023 05:28 by sky_1.

Please Log in or Create an account to join the conversation.

More
30 Dec 2023 23:21 - 30 Dec 2023 23:23 #289396 by rodw
The key is to ensure the base kernel source matches exactly with the RT Patch.

Here is an example for the 6.3 kernel but its easy to adapt to other kernels. I'd probably go with the 6.6 kernel today.

Warning: Spoiler!
Last edit: 30 Dec 2023 23:23 by rodw.
The following user(s) said Thank You: sky_1

Please Log in or Create an account to join the conversation.

More
01 Jan 2024 06:12 #289461 by sky_1
Hi Rod,
Thank you for sharing your notes! I had already switched to 6.1.69 and installed some other patches that I needed before I saw your comments. However, I followed the steps you wrote, just making changes to reflect 6.1.69 instead of 6.3, and it worked! I now have the kernel running (I checked with uname -v), and it has both the RT patch, plus the extra unrelated patch I needed. This is the first time I've done a successful kernel build, so I was not looking forward to it, but your instructions were perfectly detailed.
Next step for me will be to install or build LinuxCNC, I'll give that a shot in the next day or two. Thanks again Rod, and je_dois_partir for the fast responses at this time of the year! Happy New Year : )
The following user(s) said Thank You: rodw

Please Log in or Create an account to join the conversation.

Time to create page: 0.536 seconds
Powered by Kunena Forum