From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=34.202.193.197 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1795928186; b=cdNBypGF2b0Byn3dConPJMjTQgiM1Hs68SkI/y8qdoVpX3NkBFHH9sL9tc6GZl0aMNeV je+OLQPKk6KeQJexG5FZFcVr3tFZb5S6Q4jmN9G18MLb0VDIjVdS2oXxhBlwtXHL+0wHp n/pmS3kBcg12j4uPpCvXhu0GiaI71Ct8xXXfM8o1a2ppnXsDh0CgxFqXN0U9bjceZVBIW uGor/a7GvzVO2v46ovSqxNLgmpmrun4jYoTS3puQQHYMjmcygeOXdTY+xzmPwjr212Eff JBBuusnR3jQe6NgTOH4q4qaqK57l6DJz5uYV0DLJxg3hIGJxujn4M0jeFnpNbrZQZ7A== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795928186; h=DMARC-Filter:DKIM-Signature:DKIM-Signature:Feedback-ID: X-Pm-Original-To:Received:From:To:Cc:Subject:Date:Message-ID:X-Mailer: MIME-Version:Content-Transfer-Encoding:X-MIME-Autoconverted: Content-Type; bh=7S/tjyAZjQUhCMqfHXum2qrh/cLXE1ZXgTsxv7VOpiU=; b=hmX0sxnY9upQyiqCUYUgTlr9L1YnLQGrdXUglD4WhnBdYape0a9wbS/NGdyLMTqEHr4S 75pGSuo2ha7EcoeEEwIBq5vKYQkIzjUI8gP8IzbubeLIWM4YMkhwYczBZWkkoV7Fb25JK rL72phq/zcNhrjLPBdmQ1zI2F7a3Qe4/WqEtBq9SOmW5nUsLVcMyqtIsbu7Dp6k/Qle/y Wr+Cuz7UvaWtqDFjZYkOdkPgIyb2oAVjqj6gOKv4N9wirkHCADMG8HAyyiD7i3o5Dvz/K WW3Ez3w9DZFPd+Gfdtu4ftJ56NlSRLpCPf9d330yC6nENDPWJWtcYLkJvTa7wfzLHLA== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=atomlin.com; spf=pass smtp.mailfrom=atomlin.com; dkim=pass header.d=atomlin.com header.i=@atomlin.com header.a=rsa-sha256 header.s=purelymail3 header.b=fIxkVyTr; dkim=pass header.d=purelymail.com header.i=@purelymail.com header.a=rsa-sha256 header.s=purelymail3 header.b="U4/PBA5S"; arc=none smtp.remote-ip=34.202.193.197 Received: from sendmail.purelymail.com (sendmail.purelymail.com [34.202.193.197]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7C16D606A324 for ; Sun, 29 Nov 2026 04:56:20 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 7C16D606A324 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=atomlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=atomlin.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=atomlin.com header.i=@atomlin.com header.a=rsa-sha256 header.s=purelymail3 header.b=fIxkVyTr; dkim=pass (2048-bit key, unprotected) header.d=purelymail.com header.i=@purelymail.com header.a=rsa-sha256 header.s=purelymail3 header.b=U4/PBA5S DKIM-Signature: a=rsa-sha256; b=fIxkVyTrR1iik/fmnyENiP0zstnSVegIH4tg3mh5h3xETPjLO0HqtJpaQSaWFEL3x9LAMCQb0WZ6Twka64VpFLjh6nZbk/kOOG6Lae6ww2Mq2YLtJ5jw65hTD755BWn8VsFOIfA7B4IyYrRjdqbyLW27AiHg9pTbJOIeX2B83Ss/79UDyfnEvYz45yJBK/8hoLwCvzfuPncu1LcBifHGoaLosNk6p0JAE1DTBS8LcfLjypi+9vqDqfEqQNs9U9Ry3oLaRS8u/0nHXrAV4XDm65cR3NVMFw4s5AN49IULrL0aW3rG/hOwlklQxYz8n05eYo5Q7kyjUoBfgdo2UZnfAg==; s=purelymail3; d=atomlin.com; v=1; bh=32Llucxk+HYJHkNALK3L7yqvQWVdlba7jlVbvrgWyVc=; h=Received:From:To:Subject:Date:Message-ID; DKIM-Signature: a=rsa-sha256; b=U4/PBA5SiWi8vjG2I9fofP+z+DFVPIdHghe7C4LV0l1gEMWRuSt0kD/spSaq2uxREMsM6+dS3j1GDiZD2YqyIf6EG0tLXFfk/wz6ZqvYxY5C9X65W0S53jTg+lYrcN0RzwgNaB/5TfB7TUcg1tU+2OmHKrkx159//b1mxxyH6IldM40uaxhBzxJF/MKmVf5f55fUuy+sNi9nuETw7njUby6VJa/EKXsq9FdDntcwM8QlTipTVxsathw/pDyTjaJpRA45TsNZzgVp+xIYstuqpRiVNjt+gQU2X+p534cZe3yOWlNsyqEysh9KbwnPR5OPHim3BsVnaBzXKc3BOKsJ9w==; s=purelymail3; d=purelymail.com; v=1; bh=32Llucxk+HYJHkNALK3L7yqvQWVdlba7jlVbvrgWyVc=; h=Feedback-ID:Received:From:To:Subject:Date:Message-ID; Feedback-ID: 1802931:67223:null:purelymail X-Pm-Original-To: linux-scsi@vger.kernel.org Authentication-Results: purelymail.com; auth=pass Received: by smtp.purelymail.com (Purelymail SMTP) with ESMTPSA id -2023949301; (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384); Sun, 29 Nov 2026 04:54:37 +0000 (UTC) From: Aaron Tomlin To: axboe@kernel.dk, tglx@kernel.org, aacraid@microsemi.com, James.Bottomley@HansenPartnership.com, mkp@kernel.org, frederic@kernel.org, bigeasy@linutronix.de, gmaglione@redhat.com, vgoyal@redhat.com, stefanha@redhat.com, miklos@szeredi.hu Cc: atomlin@atomlin.com, dwagner@suse.de, eperezma@redhat.com, tom.leiming@gmail.com, ionut.nechita@windriver.com, corbet@lwn.net, vincent.guittot@linaro.org, mingo@redhat.com, peterz@infradead.org, radu@rendec.net, akpm@linux-foundation.org, steve@abita.co, sean@ashe.io, chjohnst@gmail.com, neelx@suse.com, mproche@gmail.com, nick.lange@gmail.com, marco.crivellari@suse.com, rishil1999@outlook.com, linux-doc@vger.kernel.org, linux-block@vger.kernel.org, linux-scsi@vger.kernel.org, virtualization@lists.linux.dev, linux-fsdevel@vger.kernel.org, fuse-devel@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH v17 00/10] blk: honor isolcpus configuration Date: Sat, 28 Nov 2026 23:54:24 -0500 Message-ID: <20261129045436.255364-1-atomlin@atomlin.com> X-Mailer: git-send-email 2.55.0 X-Mailing-List: linux-scsi@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-MIME-Autoconverted: from 8bit to quoted-printable by Purelymail Content-Type: text/plain; charset=UTF-8 Hi Thomas, Jens, Sebastian, Frederic, This is version 17 of the series enabling multiqueue devices and managed interrupts to adhere to CPU isolation constraints. The series has been rebased on v7.4-rc1-3893-g946d9ed1aa02. Background and Problem =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D Modern multiqueue storage controllers (e.g. NVMe devices) typically allocate one hardware queue and interrupt vector per possible CPU. When CPU isolation is requested via "isolcpus=3Dmanaged_irq", vector spreading i= n irq_create_affinity_masks() still distributes vectors across all possible CPUs, relying on irq_do_set_affinity() to strip isolated CPUs afterwards. However, that filtering only works when a vector's affinity mask contains both housekeeping and isolated CPUs. When per-CPU queues are allocated, isolated CPUs receive dedicated vectors whose masks contain no housekeeping CPUs; irq_do_set_affinity() then falls back to the unfiltered mask, leaving completion interrupts for I/O submitted on isolated CPUs targeted directly at those isolated cores. Proposed solution and architecture =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D Rather than introducing a separate "isolcpus=3D" sub-parameter as explored = in earlier iterations, this series fixes "isolcpus=3Dmanaged_irq" (HK_TYPE_MANAGED_IRQ) directly in place across the CPU grouping library, generic IRQ affinity allocator, block layer, and virtio-fs: 1. Bounded topological CPU grouping lib/group_cpus introduces group_mask_cpus_evenly(), a bounded counterpart to group_cpus_evenly() that confines NUMA and CPU locality grouping strictly to a caller-supplied cpumask while preserving two-stage (present-first, non-present second) spreading for CPU hotplug safety. 2. Managed and reserved IRQ affinity confinement The genirq/affinity subsystem queries housekeeping_cpumask(HK_TYPE_MANAGED_IRQ) directly and passes it to group_mask_cpus_evenly(), restricting managed interrupt vector calculation and distribution exclusively to housekeeping CPUs. Unmanaged pre and post vectors (e.g. NVMe admin or device configuration queues) are also confined to housekeeping CPUs by default via irq_set_reserved_mask(), while remaining unmanaged so user space can adjust their affinity after probe. 3. Block layer and virtio-fs queue mapping Both blk-mq and virtio-fs bound their queue counts to the HK_TYPE_MANAGED_IRQ housekeeping CPU mask and map housekeeping CPUs to hardware/request queues first. Any remaining possible CPUs (including isolated CPUs) are then distributed evenly across the active housekeeping-backed queues, allowing tasks on isolated CPUs to submit I/O while completion interrupts fire exclusively on housekeeping cores. 4. CPU hotplug protection To prevent I/O stalls, the block layer rejects hotplug requests that attempt to offline the last online housekeeping CPU serving a hardware context (hctx) while any isolated CPU mapped to that hctx remains online (with system suspend and hibernation exempted via cpuhp_tasks_frozen). Please let me know your thoughts. Changes since v16: - Dropped the separate "isolcpus=3Dmanaged_irq_strict" (HK_TYPE_MANAGED_IRQ_STRICT) parameter and upgraded "isolcpus=3Dmanaged_irq" (HK_TYPE_MANAGED_IRQ) directly in place across genirq/affinity, blk-mq, and documentation (Daniel Wagner, Sebastian Andrzej Siewior) - Added patch 7/10 ("virtio-fs: honour isolcpus=3Dmanaged_irq in queue mapping") to cap fs->num_request_queues to the HK_TYPE_MANAGED_IRQ housekeeping CPU weight and spread unmapped isolated CPUs across active VQ_REQUEST queues instead of leaving fs->mq_map[cpu] zero-initialised to VQ_HIPRIO - Added patch 10/10 ("genirq/affinity: Confine pre and post vectors to housekeeping CPUs") introducing irq_set_reserved_mask() so unmanaged pre_vectors and post_vectors default to housekeeping CPUs when isolcpus=3Dmanaged_irq is enabled (Ionut Nechita) - Filtered the initial hardware affinity mapping loop in blk_mq_map_hw_queues() against the housekeeping constraint mask so isolated CPUs present in an affinity mask are not prematurely marked as mapped to an inactive hctx - Added kernel-doc comments for blk_mq_num_queues(), blk_mq_map_fallback(), blk_mq_map_queues(), and blk_mq_hctx_can_offline_hk_cpu() - Collected Tested-by tags from Ionut Nechita - Rebased onto v7.4-rc1-3893-g946d9ed1aa02 - Link to v16: https://lore.kernel.org/all/20260910164237.500196-1-atomlin= @atomlin.com/ Changes since v15: - Migrated feature naming from "isolcpus=3Dio_queue" (HK_TYPE_IO_QUEUE) to "isolcpus=3Dmanaged_irq_strict" (HK_TYPE_MANAGED_IRQ_STRICT), establishi= ng it as the strict, pre-allocation counterpart to "managed_irq" - Specifying "managed_irq_strict" automatically enables HK_FLAG_MANAGED_IRQ so that dependent subsystems continue to function - Cleaned up commit bodies across the series, stripping informal scratchpads and adding Co-developed-by attribution where appropriate - Added new patch 4/9 ("sched/isolation: Prevent out-of-bounds read in isolcpus=3D boot parameter parser"). Incorporated prerequisite bugfix resolving an out-of-bounds read in housekeeping_isolcpus_setup() when sub-parameters lack trailing commas - Defined HK_TYPE_MANAGED_IRQ_STRICT and HK_FLAG_MANAGED_IRQ_STRICT. Ensured HK_FLAG_MANAGED_IRQ is set when managed_irq_strict is enabled - Decoupled queue mapping from dynamic cpu_online_mask; eliminated the blk_mq_validate() check and online cpumask snapshotting to avoid TOCTOU races during concurrent CPU hotplug events - Added cpuhp_tasks_frozen check to ensure suspend, hibernation, and resume transitions are not aborted - Added blk_mq_map_queue_type() check so CPU offline validation only evaluates hardware contexts actively mapped to the CPU being offlined - Enhanced warning message to report the offending CPU ID and queue number - Prioritised affd->calc_sets in irq_calc_affinity_vectors() so multi-set drivers scale vector allocations with requested set sizes to prevent cross-queue contention, while vector spreading remains strictly constrained to housekeeping cores - Documented "managed_irq_strict" in kernel-parameters.txt, detailing its role in blk-mq queue distribution and genirq affinity masking, as well as its superset relationship with legacy "managed_irq" - Link to v15: https://lore.kernel.org/lkml/20260521232956.553287-1-atomli= n@atomlin.com/ Changes since v14: - Fixed a division-by-zero by ensuring group_mask_cpus_evenly() safely frees its allocations and returns NULL instead of an empty array if the provided mask yields zero groups. - Fixed a device probe -ENOSPC regression in blk_mq_num_queues(). If the housekeeping mask intersection evaluated to 0 (e.g., against a localised NUMA node), min_not_zero() would erroneously return the absolute maximum hardware queues. The result is now safely clamped to a minimum of 1. - Added a mapping verification check to prevent unrelated housekeeping CPUs from aborting the global hotplug offline sequence. - Aligned the pr_warn format specifier with the unsigned int declaration of hctx->queue_num in blk_mq_hctx_can_offline_hk_cpu(). - Link to v14: https://lore.kernel.org/lkml/20260520215030.496803-1-atomli= n@atomlin.com/ Changes since v13: - Removed ineffective data_race() annotations around mask and cpu_present_mask pointers. Wrapping the pointers failed to suppress KCSAN warnings for the underlying inline bitmap memory accesses. - Fixed a silent validation bypass in blk_mq_map_hw_queues() caused by overlapping IRQ affinity masks by removing the short-circuiting optimisation and evaluating the active_hctx bitmap in a secondary pass. - Restored topology-aware multi-queue fallback by correctly routing missing IRQ affinity masks to the map_software path instead of the naive map-all fallback. - Dropped hctx->queue->disk->disk_name from warning to avoid a UAF. - Fixed an isolation leak where excess allocated hardware queues were improperly padded with irq_default_affinity. Because these queues are marked as managed, they bypassed user-space IRQ balancing; they are now safely padded with the housekeeping mask. - Enforced the housekeeping vector cap prior to evaluating driver-provided calc_sets() callbacks, preventing modern multi-queue drivers from bypassing the cap and wasting memory on dead queues. - Introduced a safety net to the vector calculation to prevent fatal -ENOSPC device probe aborts on heavily isolated systems where the housekeeping CPU count is lower than the device's structural minimum. - Removed an inaccurate claim stating that the io_queue isolation flag takes precedence over managed_irq. Both flags are parsed, evaluated, and enforced entirely independently by their respective subsystems. - Link to v13: https://lore.kernel.org/lkml/20260513005509.135966-1-atomli= n@atomlin.com/ Changes since v12: - Resolved TOCTOU race conditions against CPU hotplug events in blk_mq_map_queues() and group_mask_cpus_evenly() by taking lockless snapshots of the online CPU mask prior to algorithmic evaluation. - Migrated the active_hctx tracking to a dynamically sized bitmap (bitmap_zalloc), resolving a critical out-of-bounds memory write that occurred when hardware queues exceeded the system CPU count. - Wrapped the disk pointer fetch in blk_mq_hctx_can_offline_hk_cpu() with READ_ONCE() to prevent a TOCTOU NULL pointer dereference against concurrent device teardowns. - Introduced bitmap_empty() checks to prevent the mapping logic from routing unassigned CPUs into unallocated memory when all mapped CPUs are offline, safely forcing a fallback mapping instead. - Implemented a native two-stage distribution logic in group_mask_cpus_evenly() that first prioritises physically present CPUs to prevent I/O starvation before distributing remaining vectors to non-present CPUs for hotplug safety. - Restricted the maximum number of allocated vectors in irq_calc_affinity_vectors() to the weight of the housekeeping mask, preventing drivers from wasting memory on dead hardware queues that physically cannot be routed. - Added padding logic using irq_default_affinity for sets where isolation constraints yield fewer masks than requested vectors, preserving the 1:1 hardware queue mapping sequence for subsequent sets. - Fixed a logic flaw that prematurely rejected valid offline requests by manually iterating over cpu_online_mask and reverse-mapping to accurately detect isolated CPUs, properly permitting the offlining of non-housekeeping CPUs. - Corrected an absolute versus relative queue index calculation bug in blk_mq_map_queues() that was overwriting loop iterations, by iterating directly over the generated masks. - Replaced scoped __free cleanups with traditional goto unwinding in the block layer to align with subsystem styling guidelines. - Refined the io_queue kernel command-line parameter documentation for better clarity and precision. - Link to v12: https://lore.kernel.org/lkml/20260422185215.100929-1-atomli= n@atomlin.com/ Changes since v11: - Removed duplicate paragraph from the commit message in patch 11 (Marco Crivellari) - Ensure ZERO_SIZE_PTR is not returned by group_mask_cpus_evenly() (Marco Crivellari) - Link to v11: https://lore.kernel.org/lkml/20260416192942.1243421-1-atoml= in@atomlin.com/ Changes since v10: - Completely rewrote the isolcpus=3Dio_queue documentation in Documentation/admin-guide/kernel-parameters.txt to clarify its exclusive application to managed IRQs, queue allocation limits, vector exhaustion prevention, and hardware interrupt routing (Ming Lei) - Fixed a stack frame bloat issue by avoiding the on-stack declaration of struct cpumask (Waiman Long) - Link to v10: https://lore.kernel.org/linux-nvme/20260401222312.772334-1-= atomlin@atomlin.com/ Changes since v9: - Fixed a page fault regression encountered when initialising secondary queue maps (e.g. NVMe poll queues). Restored the qmap->queue_offset to the mq_map assignment to ensure CPUs are strictly mapped to absolute hardware indices (Keith Busch) - Corrected the active_hctx tracker to utilise relative queue indices, preventing out-of-bounds mask assignments - Fixed the blk_mq_validate() sanity check to properly evaluate absolute queue indices against the offset-adjusted loop index - Corrected typographical errors within block/blk-mq-cpumap.c (Keith Busch) - Clarified the commit message regarding the removal of the !SMP fallback code, explicitly noting that the core scheduler now mandates SMP unconditionally (Sebastian Andrzej Siewior) - Added missing "Signed-off-by:" tags to properly record the patch series chain of custody - Link to v9: https://lore.kernel.org/lkml/20260330221047.630206-1-atomlin= @atomlin.com/ Changes since v8: - Added "Reviewed-by:" tags - Introduced irq_spread_hk_filter() to safely restrict managed IRQ affinity to housekeeping CPUs (Thomas Gleixner) - Removed the unsafe global static variable blk_hk_online_mask from blk-mq-cpumap.c and blk-mq.c. blk_mq_online_queue_affinity() now returns a stable pointer, delegating safe intersection to the callers to prevent concurrent modification races (Thomas Gleixner, Hannes Reinecke) - Resolved BUG: kernel NULL pointer dereference in __blk_mq_all_tag_iter reported by the kernel test robot during cpuhotplug rcutorture stress testing - Link to v8: https://lore.kernel.org/lkml/20250905-isolcpus-io-queues-v8-= 0-885984c5daca@kernel.org/ Changes since v7: - Added commit 524f5eea4bbe ("lib/group_cpus: remove !SMP code") - Merged the new mapping logic directly into the existing function to avoid special casing - Refined the group_mask_cpus_evenly() implementation with the following updates: - Corrected the function name typo (changed group_masks_cpus_evenly to group_mask_cpus_evenly) - Updated the documentation comment to accurately reflect the function's behavior - Renamed the cpu_mask argument to mask for consistency - Added a new patch for aacraid to include the missing number of queues calculation - Restricted updates to only affect SCSI drivers that support PCI_IRQ_AFFINITY and do not utilise nvme-fabrics - Removed the __free cleanup attribute usage for cpumask_var_t allocations due to compatibility issues - Updated the documentation to explicitly highlight the limitations surrounding CPU offlining - Collected accumulated Reviewed-by and Acked-by tags - Link to v7: https://patch.msgid.link/20250702-isolcpus-io-queues-v7-0-55= 7aa7eacce4@kernel.org Changes since v6: - Sent out the first part of the series independently: https://lore.kernel.org/all/20250617-isolcpus-queue-counters-v1-0-139236= 86b54b@kernel.org/ - Added comprehensive kernel command-line documentation - Added validation logic to ensure the resulting CPU-to-queue mapping is fully operational - Rewrote the isolcpus mapping code to properly account for active hardware contexts (hctx) - Introduced blk_mq_map_hk_irq_queues, which utilizes the mask retrieved from irq_get_affinity() - Refactored blk_mq_map_hk_queues to require the caller to explicitly test for HK_TYPE_MANAGED_IRQ - Link to v6: https://patch.msgid.link/20250424-isolcpus-io-queues-v6-0-9a= 53a870ca1f@kernel.org Changes since v5: - Reintroduced the io_queue type for the isolcpus kernel parameter - Prevented the offlining of a housekeeping CPU if an isolated CPU is still present, upgrading this behavior from a simple warning to a hard restriction - Link to v5: https://lore.kernel.org/r/20250110-isolcpus-io-queues-v5-0-0= e4f118680b0@kernel.org Changes since v4: - Rebased the series onto the latest for-6.14/block branch. - Updated the documentation regarding the managed_irq parameters - Reworded the commit message for "blk-mq: issue warning when offlining hctx with online isolcpus" for better clarity - Split the input and output parameters in the patch "lib/group_cpus: let group_cpu_evenly return number of groups" - Dropped the patch "sched/isolation: document HK_TYPE housekeeping option" - Link to v4: https://lore.kernel.org/r/20241217-isolcpus-io-queues-v4-0-5= d355fbb1e14@kernel.org Changes since v3: - Added the patch "blk-mq: issue warning when offlining hctx with online isolcpus" - Fixed the check in group_cpus_evenly(); the condition now properly uses housekeeping_enabled() instead of cpumask_weight(), as the latter always returns a valid mask - Dropped the Fixes: tag from "lib/group_cpus.c: honor housekeeping config when grouping CPUs" - Fixed an overlong line warning in the patch "scsi: use block layer helpers to calculate num of queues" - Dropped the patch "sched/isolation: Add io_queue housekeeping option" in favor of simply documenting the housekeeping hk_type enum - Added the patch "lib/group_cpus: let group_cpu_evenly return number of groups" - Collected accumulated Reviewed-by and Acked-by tags - Split the patchset by moving foundational changes into a separate preparation series: https://lore.kernel.org/linux-nvme/20241202-refactor-blk-affinity-helper= s-v6-0-27211e9c2cd5@kernel.org/ - Link to v3: https://lore.kernel.org/r/20240806-isolcpus-io-queues-v3-0-d= a0eecfeaf8b@suse.de Changes since v2: - Integrated patches from Ming Lei (https://lore.kernel.org/all/20210709081005.421340-1-ming.lei@redhat.com= /): "virtio: add APIs for retrieving vq affinity" and "blk-mq: introduce blk_mq_dev_map_queues" - Replaced all instances of blk_mq_pci_map_queues and blk_mq_virtio_map_queues with the new unified blk_mq_dev_map_queues - Updated and expanded the helper functions used for calculating the number of queues - Added the CPU-to-hctx mapping function specifically to support the isolcpus=3Dio_queue parameter - Documented the hk_type enum and the newly introduced isolcpus=3Dio_queue parameter - Added the patch "scsi: pm8001: do not overwrite PCI queue mapping" - Link to v2: https://lore.kernel.org/r/20240627-isolcpus-io-queues-v2-0-2= 6a32e3c4f75@suse.de Changes since v1: - Updated the feature documentation for clarity and completeness - Split the blk/nvme-pci patch into smaller, logical commits - Dropped the HK_TYPE_IO_QUEUE macro in favor of reusing HK_TYPE_MANAGED_IRQ - Link to v1: https://lore.kernel.org/r/20240621-isolcpus-io-queues-v1-0-8= b169bf41083@suse.de Aaron Tomlin (3): sched/isolation: Prevent out-of-bounds read in isolcpus=3D boot parameter parser virtio-fs: honour isolcpus=3Dmanaged_irq in queue mapping genirq/affinity: Restrict managed IRQ affinity to housekeeping CPUs Daniel Wagner (6): scsi: aacraid: use block layer helpers to calculate num of queues lib/group_cpus: remove dead !SMP code lib/group_cpus: Add group_mask_cpus_evenly() blk-mq: use hk cpus only when isolcpus=3Dmanaged_irq is enabled blk-mq: prevent offlining hk CPUs with associated online isolated CPUs docs: update isolcpus=3Dmanaged_irq documentation Ionut Nechita (1): genirq/affinity: Confine pre and post vectors to housekeeping CPUs Documentation/admin-guide/cpu-isolation.rst | 3 +- .../admin-guide/kernel-parameters.txt | 55 +++--- Documentation/core-api/housekeeping.rst | 5 +- Documentation/core-api/irq/managed_irq.rst | 59 +++--- block/blk-mq-cpumap.c | 184 ++++++++++++++++-- block/blk-mq.c | 75 +++++++ drivers/scsi/aacraid/comminit.c | 3 +- fs/fuse/virtio_fs.c | 98 +++++++--- include/linux/group_cpus.h | 3 + kernel/irq/affinity.c | 57 +++++- kernel/sched/isolation.c | 2 + lib/group_cpus.c | 112 +++++++++-- 12 files changed, 539 insertions(+), 117 deletions(-) --=20 2.55.0