Kernel Compatibility
The aes-stream-drivers codebase targets Linux kernels from 3.10 through the current 6.8+ series.
This range spans major kernel API changes: the /proc interface was restructured, DMA mapping APIs
evolved, and several subsystem function signatures changed across that period. Rather than
requiring a specific kernel version, the driver uses LINUX_VERSION_CODE compile-time guards
to select the correct API call for each kernel generation.
How the Guards Work
The standard Linux kernel macros LINUX_VERSION_CODE and KERNEL_VERSION(major, minor,
patch) are used throughout the common driver source. A typical guard looks like:
#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 6, 0)
/* use old file_operations.proc_fops pattern */
#else
/* use proc_ops struct (introduced in 5.6) */
#endif
No custom abstraction layer wraps these guards. Each guard is local to the file and function where the API difference appears.
Compatibility Matrix
The following guards are present in the driver source. All were verified by direct inspection of the source files listed.
< KERNEL_VERSION(2, 6, 25)—dma_common.cioremap_nocacheis used in place ofioremapfor non-cacheable register mapping. Thenocachevariant was removed in 2.6.25.< KERNEL_VERSION(3, 10, 0)—dma_common.cOld /proc API:
PDE(inode)->datais used to retrieve the private pointer from a /proc inode. This was replaced byPDE_DATA()in 3.10.< KERNEL_VERSION(4, 16, 0)—dma_common.hThe
__poll_ttype did not exist before 4.16. The driver provides a manualtypedef unsigned int __poll_tfor older kernels.< KERNEL_VERSION(5, 6, 0)—dma_common.cThe
proc_opsstruct was introduced in 5.6 to replace embedding function pointers directly infile_operationsfor /proc entries.< KERNEL_VERSION(5, 15, 0)—dma_buffer.cDMA mapping API changes in 5.15 affected how streaming DMA buffers are managed.
>= KERNEL_VERSION(5, 15, 0)—rce_top.cAn RCE-specific compatibility change for the same DMA API evolution.
>= KERNEL_VERSION(5, 17, 0)or RHEL 9.3 —dma_common.cpde_data()(lowercase) replaces the olderPDE_DATA()macro. Red Hat backported this change into RHEL 9.3 with an older kernel version number, requiring explicitRHEL_RELEASE_CODEdetection.>= KERNEL_VERSION(6, 0, 0)— Yoctoaxistreamdma.cCoherent DMA memory allocation is configured via the device tree
dma-coherentattribute instead of a build-time define.>= KERNEL_VERSION(6, 4, 0)or RHEL 9.4 —dma_common.c,aximemorymapclass_create()dropped its first argument (THIS_MODULE) in 6.4. Red Hat backported this change in RHEL 9.4.
RHEL Backport Detection
Red Hat Enterprise Linux backports upstream API changes into kernel versions whose
LINUX_VERSION_CODE predates the upstream introduction. For example, RHEL 9.3 ships with a
5.14.x-based kernel but includes the pde_data() change from upstream 5.17. The driver
detects this using the RHEL_RELEASE_CODE macro alongside LINUX_VERSION_CODE guards.
This means the driver’s compatibility range is not simply “kernels 3.10–6.8” but more accurately “any kernel whose symbol set matches the guards above, including RHEL backport variants.”
Minimum and Maximum Tested Kernels
The minimum supported kernel is 3.10 — this is the version that introduced the PDE_DATA()
macro used in the /proc interface code. Kernels older than 3.10 are not supported. The driver is
tested in CI through kernel 6.8+ (current as of this writing). Kernels beyond 6.8 may
require new guards if further API changes occur.
Further Reading
Driver architecture and hardware abstraction: Driver Architecture
Yocto integration (where the 6.0+ guard appears): Integrate into a Yocto Project