PREEMPT RT

Last updated

PREEMPT_RT was a set of patches for the Linux kernel which implement both hard and soft real-time computing capabilities. [1] On September 20, 2024, PREEMPT_RT was fully merged and enabled in mainline Linux on the supported architectures x86, x86_64, RISC-V and ARM64. [2] This will make kernel v6.12 the first release to include baked-in real-time capability. Support for LoongArch is added in v6.13. [3]

Contents

History

The PREEMPT_RT patchset has been in development since 2005. [4] In 2021, the preemption core locking code was merged. [5] [6]

Since February 2023, Canonical has been releasing real-time versions of Ubuntu Pro, free for personal and small-scale commercial use in up to 5 machines. [7] [8] The real-time kernel can be added to various existing Ubuntu releases through an enablement process. [8] These kernels include the PREEMPT_RT patchset and offer long-term support. [8]

MontaVista Software has been releasing a real-time Linux distribution containing the PREEMPT_RT patchset since the early 2000. Montavista's current main embedded Linux product, CGX, contains real-time preemption as a standard feature.

At the Sep. 2024 European Open Source Summit, Linus Torvalds announced that PREEMPT_RT had been accepted into the mainline linux kernel after a protracted development hurdle involving the printk kernel logging facility.

Related Research Articles

<span class="mw-page-title-main">Ingo Molnár</span> Linux kernel programmer

Ingo Molnár, employed by Red Hat as of May 2013, is a Hungarian Linux hacker. He is known for his contributions to the operating system in terms of security and performance.

Computer operating systems based on the Linux kernel are used in embedded systems such as consumer electronics, in-vehicle infotainment (IVI), networking equipment, machine control, industrial automation, navigation equipment, spacecraft flight software, and medical instruments in general.

seccomp is a computer security facility in the Linux kernel. seccomp allows a process to make a one-way transition into a "secure" state where it cannot make any system calls except exit , sigreturn , read and write to already-open file descriptors. Should it attempt any other system calls, the kernel will either just log the event or terminate the process with SIGKILL or SIGSYS. In this sense, it does not virtualize the system's resources but isolates the process from them entirely.

<span class="mw-page-title-main">AppArmor</span> Linux kernel security module

AppArmor is a Linux kernel security module that allows the system administrator to restrict programs' capabilities with per-program profiles. Profiles can allow capabilities like network access, raw socket access, and the permission to read, write, or execute files on matching paths. AppArmor supplements the traditional Unix discretionary access control (DAC) model by providing mandatory access control (MAC). It has been partially included in the mainline Linux kernel since version 2.6.36 and its development has been supported by Canonical since 2009.

<span class="mw-page-title-main">Kernel-based Virtual Machine</span> Virtualization module in the Linux kernel

Kernel-based Virtual Machine (KVM) is a free and open-source virtualization module in the Linux kernel that allows the kernel to function as a hypervisor. It was merged into the mainline Linux kernel in version 2.6.20, which was released on February 5, 2007. KVM requires a processor with hardware virtualization extensions, such as Intel VT or AMD-V. KVM has also been ported to other operating systems such as FreeBSD and illumos in the form of loadable kernel modules.

aufs implements a union mount for Linux file systems. The name originally stood for AnotherUnionFS until version 2.

<span class="mw-page-title-main">Linux kernel</span> Free Unix-like operating system kernel

The Linux kernel is a free and open source, UNIX-like kernel that is used in many computer systems worldwide. The kernel was created by Linus Torvalds in 1991 and was soon adopted as the kernel for the GNU operating system (OS) which was created to be a free replacement for Unix. Since the late 1990s, it has been included in many operating system distributions, many of which are called Linux. One such Linux kernel operating system is Android which is used in many mobile and embedded devices.

<span class="mw-page-title-main">Brain Fuck Scheduler</span> Process scheduler in Linux

The Brain Fuck Scheduler (BFS) is a process scheduler designed for the Linux kernel in August 2009 based on earliest eligible virtual deadline first scheduling (EEVDF), as an alternative to the Completely Fair Scheduler (CFS) and the O(1) scheduler. BFS was created by Con Kolivas.

<span class="mw-page-title-main">LXC</span> Operating system-level virtualization for Linux

Linux Containers (LXC) is an operating system-level virtualization method for running multiple isolated Linux systems (containers) on a control host using a single Linux kernel.

cgroups is a Linux kernel feature that limits, accounts for, and isolates the resource usage of a collection of processes.

SCHED_DEADLINE EDF-based task scheduler in the Linux kernel

SCHED_DEADLINE is a CPU scheduler available in the Linux kernel since version 3.14, based on the earliest deadline first (EDF) and constant bandwidth server (CBS) algorithms, supporting resource reservations: each task scheduled under such policy is associated with a budget Q, and a period P, corresponding to a declaration to the kernel that Q time units are required by that task every P time units, on any processor. This makes SCHED_DEADLINE particularly suitable for real-time applications, like multimedia or industrial control, where P corresponds to the minimum time elapsing between subsequent activations of the task, and Q corresponds to the worst-case execution time needed by each activation of the task.

The x32 ABI is an application binary interface (ABI) and one of the interfaces of the Linux kernel. The x32 ABI provides 32-bit integers, long and pointers (ILP32) on Intel and AMD 64-bit hardware. The ABI allows programs to take advantage of the benefits of x86-64 instruction set while using 32-bit pointers and thus avoiding the overhead of 64-bit pointers.

perf is a performance analyzing tool in Linux, available from Linux kernel version 2.6.31 in 2009. Userspace controlling utility, named perf, is accessed from the command line and provides a number of subcommands; it is capable of statistical profiling of the entire system.

zswap is a Linux kernel feature that provides a compressed write-back cache for swapped pages, as a form of virtual memory compression. Instead of moving memory pages to a swap device when they are to be swapped out, zswap performs their compression and then stores them into a memory pool dynamically allocated in the system RAM. Later writeback to the actual swap device is deferred or even completely avoided, resulting in a significantly reduced I/O for Linux systems that require swapping; the tradeoff is the need for additional CPU cycles to perform the compression.

kGraft is a feature of the Linux kernel that implements live patching of a running kernel, which allows kernel patches to be applied while the kernel is still running. By avoiding the need for rebooting the system with a new kernel that contains the desired patches, kGraft aims to maximize the system uptime and availability. At the same time, kGraft allows kernel-related security updates to be applied without deferring them to scheduled downtimes. Internally, kGraft allows entire functions in a running kernel to be replaced with their patched versions, doing that safely by selectively using original versions of functions to ensure per-process consistency while the live patching is performed.

kpatch is a feature of the Linux kernel that implements live patching of a running kernel, which allows kernel patches to be applied while the kernel is still running. By avoiding the need for rebooting the system with a new kernel that contains the desired patches, kpatch aims to maximize the system uptime and availability. At the same time, kpatch allows kernel-related security updates to be applied without deferring them to scheduled downtimes. Internally, kpatch allows entire functions in a running kernel to be replaced with their patched versions, doing that safely by stopping all running processes while the live patching is performed.

RPMsg is a protocol enabling inter-processor communication inside multi-core processors.

postmarketOS Free and open-source operating system for smartphones, based on Alpine Linux

postmarketOS is an operating system primarily for smartphones, based on the Alpine Linux distribution.

Bcachefs is a copy-on-write (COW) file system for Linux-based operating systems. Its primary developer, Kent Overstreet, first announced it in 2015, and it was added to the Linux kernel beginning with 6.7. It is intended to compete with the modern features of ZFS or Btrfs, and the speed and performance of ext4 or XFS.

This article documents the version history of the Linux kernel.

References

  1. "20 years later, real-time Linux makes it to the kernel - really". zdnet.com . Retrieved 2024-09-19.
  2. "Merge tag 'sched-rt-2024-09-17' - kernel/git/torvalds/linux.git - Linux kernel source tree". git.kernel.org. Retrieved 2024-09-20.
  3. GIT PULL: LoongArch changes for v6.13
  4. Reghenzani, Federico; Massari, Giuseppe; Fornaciari, William (2019-02-21). "The Real-Time Linux Kernel: A Survey on PREEMPT_RT". ACM Computing Surveys. 52 (1): 18:1–18:36. doi:10.1145/3297714. hdl: 11311/1076057 . ISSN   0360-0300.
  5. "Realtime preemption locking core merged [LWN.net]". lwn.net. Retrieved 2023-02-09.
  6. "The future of realtime Linux". LWN.net . Retrieved 2023-02-09.
  7. Proven, Liam. "Real-time Ubuntu 22.04: What you need to know". The Register . Retrieved 2023-02-20.
  8. 1 2 3 "Canonical releases Real-time Ubuntu 24.04 LTS". Ubuntu. Retrieved 2024-07-03.