Kernel release Linux 6.17

After two months of development, Linus Torvalds released the kernel. Linux 6.17. Among the most notable changes: improved Btrfs performance, file_getattr() and file_setattr() system calls, unification of single-processor and multi-processor configurations in the task scheduler, DAMON_STAT module with memory access statistics, support for Live patches on ARM64 systems, sending core dumps via the AF_UNIX socket, limiting SCHED_EXT via cgroup, simplified configuration of protection against CPU vulnerabilities, building in Clang with initialization of variables on the stack, protection against /proc spoofing, extension of the RV (Runtime Verification) subsystem, limiting AF_UNIX sockets via AppArmor, the TCP DualPI2 congestion control algorithm.

The new version incorporates 14334 fixes from 2118 developers, with a patch size of 46 MB (changes affected 12841 files, adding 646654 lines of code, and removing 398782 lines). The previous release included 15924 fixes from 2145 developers, with a patch size of 50 MB. About 43% of all changes in 6.17 are related to device drivers, approximately 12% of changes are related to updates to code specific to hardware architectures, 14% are related to the network stack, 4% are related to file systems, and 3% are related to internal kernel subsystems.

Main new features in kernel 6.17 (1, 2, 3):

  • Disk Subsystem, I/O and File Systems
    • Btrfs now features experimental support for large folios, which reduces overhead and improves the performance of certain operations. Caching of requests to free space allocation bitmaps has been implemented, increasing the performance of empty file creation by 20%. Read-ahead performance has been improved in systems using data compression. Keys in the XArray structure are now more densely packed, increasing the storage compactness of extent tree nodes and reducing the number of leaf nodes by 50-70%. Additional compression settings have been provided for defragmented extents.
    • The ext4 file system now supports buffered I/O with the RWF_DONTCACHE flag, which causes data to be removed from the page cache immediately after the operation is completed.
    • The EROFS file system now supports metadata compression.
    • The NFS server can now delegate write operations to clients that open files in write-only mode.
    • The FALLOC_FL_WRITE_ZEROES flag has been added to the fallocate() system call. This flag allows zero-filling of a specified range in a file using the WRITE_ZERO command, which is supported by some SSDs and performs zero-filling without I/O operations. This option is currently only available on ext4 file systems.
    • Added file_getattr() and file_setattr() system calls to manipulate the inode attributes of a given file.
    • The "pktcdvd" driver for working with optical media in batch mode, which was marked as obsolete in 2016, has been removed.
    • Bcachefs FS in the kernel Linux Bcachefs has been moved to external maintenance mode, which means changes to Bcachefs will no longer be accepted into the main kernel, while the file system will remain in the kernel codebase. Bcachefs development will be conducted outside the kernel codebase until Kent Overstreet demonstrates his ability to interact correctly with other kernel developers and adhere to established development guidelines.
  • Memory and system services
    • Support for single-processor configurations has been removed from the task scheduler. On systems with a single processor, kernels built for multi-processor (SMP) systems should now be used. The code for single-processor and multi-processor systems has been unified and removed unnecessary dependencies on the CONFIG_SMP kernel parameter.
    • The DAMON_STAT (Data Access Monitoring Results Stat) kernel module has been added. It allows monitoring RAM access using the DAMON (Data Access MONitor) subsystem. The module provides statistics on inactivity (memory_idle_ms_percentiles) and estimated memory bandwidth (estimated_memory_bandwidth).
    • On systems with ARM64 architecture, support for Live patches has been implemented, allowing you to apply fixes to the kernel. Linux on the fly, without rebooting or stopping the system.
    • In the minimalistic C library nolibc, supplied with the kernel source code Linux and provides a wrapper around basic system calls, supporting the SuperH, x32, MIPS n32, and MIPS n34 architectures.
    • The ability to send core dump contents via the AF_UNIX socket has been expanded, allowing for the creation of more secure core dump handlers in user space that do not rely on the kernel invoking privileged processes. The new version adds a protocol for creating servers, capable of managing core dump processing at the task level. For example, core dumps can be ignored for some processes, while being passed through a socket for others. A separate prototype server for core dump management has been developed.
    • Added kernel command line option "crashkernel=size,cma" to reserve memory space via CMA (Contiguous Memory Allocator) for storing kernel crash dumps.
    • The pidfd mechanism has been expanded to allow the use of process-specific identifiers, which, unlike pid, are not reassignable. The ability to bind extended attributes to pidfd from user space has been added. Opening file descriptors for pidfd via the open_by_handle_at() function without binding to the file system is now possible. Internal information created by the kernel with pidfd is now bound to the process, not pidfd, and is preserved between reopenings of the same process.
    • The bpf_cgroup_read_xattr() function for reading extended file attributes has been added to the BPF subsystem. BPF programs now support standard string operations such as bpf_strcmp, bpf_strnchr, bpf_strchrnul, bpf_strlen, and bpf_strspn, which operate in read-only mode. The standard stdout and stderr streams can now be used to interact with user-space components. For systems based on the LoongArch architecture, BPF now supports dynamic code modification, the BPF trampoline mechanism (which reduces call overhead between the kernel and BPF programs), and the launch of programs that use struct_ops to create kernel function handlers via BPF.
    • The timekeeping system now supports auxiliary clocks, which are not connected to the regular system clock and operate at their own rhythm (previously, all clocks operated at the same rhythm and differed only in their offset).
    • Initial support for Proxy Execution has been added to mitigate priority inversion issues. Proxy execution allows a task waiting for a lock to be released to transfer its execution context to the task holding the lock, speeding up the release of that lock.
    • Continued migrating changes from the Rust-for- branchLinux, related to using Rust as a second language for developing drivers and kernel modules (Rust support is not active by default and does not result in Rust being included among the required kernel build dependencies). Abstractions have been added for managing voltage and current regulators, firmware properties, I/O resources, and I/O memory. The "warn_on!()" macro has been implemented. The UserPtr type has been added for user-space pointers. The functionality of the workqueue, uaccess, dma, time, and list modules has been expanded. The 'bits' module has been added with the 'bit' and 'genmask' functions.
    • The code for calculating CRC checksums has been reworked and new calls for generating SHA-1 and SHA-2 hashes have been added. Hardware-specific optimizations have been added. Performance of the crc32c() function has been improved on new x86_64 CPUs that support the VPCLMULQDQ (Vector Carry-Less Multiplication of Quadwords) extension.
    • For S390 systems, support for swapping and migrating large memory pages (transparent huge page) has been implemented.
    • Added the ability to configure the aggressiveness of memory page reclamation (proactive-reclaim) for specific NUMA nodes when memory is insufficient. This allows you to select NUMA nodes for which more aggressive memory reclamation will be applied. For example, "echo "512M swappiness=10" > /sys/devices/system/node/node1/reclaim."
    • The SCHED_EXT mechanism, which enables the use of BPF to create CPU schedulers, now includes the ability to manage throughput via cgroups. For example, the cpu.max parameter can be used to limit CPU load.
    • Automatic mounting of tracefs virtual file system to /sys/kernel/debug/tracing directory has been deprecated; /sys/kernel/tracing should be used instead.
  • Virtualization and Security
    • Added the ability to enable protection against CPU vulnerabilities by selecting blockable attack vectors Instead of specifying specific vulnerabilities in the settings. Blocking methods are selected depending on the type of isolation violation: between the user and the kernel (user-kernel), between the user and another user (user-user), between the guest system and the host environment (guest-host), between different guest systems (guest-guest), and between different threads (cross-thread). The proposed approach allows for activating protection only against those vulnerability classes that are of real concern to the user. For example, cloud environment owners can enable guest-host and guest-guest modes, after which protection methods against the following vulnerabilities will be activated: BHI, GD, L1TF, MDS, MMIO, Retbleed, RFDS, Spectre_v2, SRBDS, SRSO, and TAA.
    • Added support for building with the Clang compiler using stack depth tracking mode, which initializes all variables stored on the stack. This initialization prevents kernel information leaks through uninitialized variables that may contain remnants of previously stored data on the stack. Previously, a similar feature was supported using the STACKLEAK GCC plugin.
    • Added protection against attackers spoofing the /proc filesystem via mounting in "bind" mode. The /proc root inode number is now fixed (PROCFS_ROOT_INO) and can be verified by a user-space process.
    • The RV (Runtime Verification) subsystem, designed to verify the correct operation of highly reliable systems, has been updated with the rtapp (Real-time application monitor) monitoring component for tracking common issues in real-time applications, as well as the rp, sssw, and opid components for testing the task scheduler. The ability to create monitoring components that use linear temporal logic to determine the behavior model instead of a deterministic automaton has been implemented. Verification is performed at runtime by attaching handlers to tracepoints, which compare the actual execution progress with a predefined reference model defining the expected system behavior.
    • The AppArmor system has been updated to support access control for AF_UNIX sockets.
    • The KVM hypervisor on ARM systems implements support for the GICv5 interrupt controller.
    • Added CONFIG_KVM_IOAPIC setting to disable support for APIC, PIC, and PIT emulation in KVM.
    • Added protection against the VMSCAPE vulnerability.
    • Added ioctl command FS_IOC_GETLBMD_CAP to obtain information from user space about the application of integrity protection tools to a file.
    • The /sys/fs/selinux/user interface has been deprecated; accessing it now introduces a five-second delay and prints a warning in the log.
  • Network subsystem
    • The implementation of PSE (Power Sourcing Equipment) technology, used to supply power over Ethernet to devices such as IP cameras and wireless access points, has been enhanced with support for configurable power budgeting strategies (total available power). These strategies allow you to prioritize which ports should be shut down to prevent overload.
    • The MCTP (Management Component Transport Protocol) implementation now supports gateway routing. For example, the following rules route packets to Endpoint ID 10 via device mctpi2c0 using address 0x1d, which is directly assigned to Endpoint ID 9. mctp route add 9 via mctpi2c0 mctp neigh add 9 dev mctpi2c0 lladdr 0x1d mctp route add 10 gw 9
    • For UNIX sockets (AF_UNIX), the SO_INC option is implemented, and for the VSOCK address family, the SIOCINQ option is implemented. These options are similar to the TCP_INQ option for TCP and allow information about the number of bytes available for reading on the socket to be obtained via a control message.
    • TCP now strictly enforces the advertised receive window size, which determines the amount of data allowed to be sent before receiving an ACK from the other end. Previously, the kernel continued to process data arriving beyond the advertised receive window, but will now stop doing so.
    • MPTCP (Multipath TCP) now supports the TCP_MAXSEG socket option to limit the maximum size of sent segments. MPTCP is an extension to the TCP protocol for delivering packets simultaneously along multiple routes through different network interfaces bound to different IP addresses.
    • Added support for the TCP DualPI2 congestion control algorithm (RFC 9332), which enables the use of scalable congestion controllers for traffic with high quality of service requirements (such as TCP-Prague and DCTCP) without causing performance degradation for classic traffic handled by congestion controllers such as Reno and Cubic.
    • Added sysctl "force_forwarding" which can be used to enable traffic forwarding on selected network interfaces with IPv6.
    • Support for the Selective Acknowledgment (SACK) packet loss detection algorithm described in RFC 6675 has been removed. This algorithm was deprecated in 2018. It is recommended to use the RACK-TLP algorithm for detecting TCP packet loss.
  • Equipment
    • Work has continued on the Xe DRM (Direct Rendering Manager) driver for GPUs based on the Intel Xe architecture, which is used in Intel Arc series graphics cards and integrated graphics, starting with Tiger Lake processors. The new version enables support for chips based on the Panthor Lake microarchitecture by default and adds support for the WildCat Lake microarchitecture.
    • The AMDGPU driver for GFX9.x GPUs now supports the Cleaner Shader mechanism, which cleans GPU memory before reusing it to prevent data leaks left over from another process. Support for standby mode has been improved. The ability to enter standby mode in AMD SR-IOV environments has been added. Backlight control has been improved.
    • The i915 driver now supports the drm_panic mechanism, which displays a "blue screen of death"-like error message when a crash occurs. Support for the display controller used in the Wildcat Lake family of chips has been added.
    • Integration of Nova driver components for NVIDIA GPUs equipped with GSP firmware, used starting with the NVIDIA GeForce RTX 2000 series based on the Turing microarchitecture, has continued. The driver is written in Rust. The new version adds an abstraction layer for DMA, implements a VBIOS parser, adds code for configuring the framebuffer, and provides support for accelerated loading in Falcon mode.
    • The adreno driver has been updated to support Qualcomm Adreno x1-45 and x1-85 GPUs.
    • The msm driver now supports Adreno SM8750 GPU and video memory mapping (VM_BIND).
    • The panfrost driver has been updated to support Mali GPUs used in the Mediatek mt8370 SoC.
    • The lima driver has been updated to support GPUs used in the Rockchip RK3528 SoC.
    • Added mtd (Memory Technology Devices) driver for accessing NVM memory integrated into Intel GPUs.
    • Added support for the following sound systems: ASoC IMX WM8524, AMD ACP7.2, SoundWire ACP 7.1, Fairphone 4 & 5, Qualcomm QCS8275, Framework Laptop 13 (AMD Ryzen AI 300), CS35L41 HDA (used in ASUS laptops), Richtek RTQ9124, TI TAS5753, HP EliteBook x360 830 G6, EliteBook 830 G6, LG 16Z90R-A, HP 15-fc000. HD audio code has been reorganized.
    • Added support for ARM boards, SoCs, and devices: NVIDIA Tegra264, Marvell PXA1908 (Marvell's first 64-bit chip for smartphones), CIX P1, Axiado AX3000, Sophgo SG2000 (combines ARM and RISC-V cores), Mediatek mt6572, exynos2200 (used in Samsung Galaxy S22), Renesas R-Car V4M-7, TI am62d2, and Sophgo sg2042, laptops based on Mediatek mt8186 and Qualcomm Snapdragon X1, smartphones and tablets based on mt6572, tegra30, and msm8976 SoCs.

At the same time, the Latin American Free Software Foundation created a version of the completely free kernel 6.17 - Linux-libre 6.17-gnu, cleaned of firmware and driver elements containing non-free components or code sections with restricted scope. Release 6.17 includes updated blob cleanup code in the amdgpu, prueth, iwlwifi, btusb, pci mhi host, adreno a6xx, nova-core, and Intel AVS drivers. Blob names in devicetree (.dts) files for ARM chips and the Intel IPU7 have been cleaned. Blob loading has been disabled in the new pci hda drivers. Blob cleanup has been discontinued in the QLogic infiniband driver, which has been removed from the kernel.

Source: opennet.ru

Buy reliable hosting for sites with DDoS protection, VPS VDS servers 🔥 Buy reliable website hosting with DDoS protection, VPS VDS servers | ProHoster