<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/include/linux/cpumask.h, branch v6.18.21</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.18.21</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.18.21'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2025-07-31T23:52:32+00:00</updated>
<entry>
<title>Merge tag 'bitmap-for-6.17' of https://github.com/norov/linux</title>
<updated>2025-07-31T23:52:32+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2025-07-31T23:52:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=f2d282e1dfb3d8cb95b5ccdea43f2411f27201db'/>
<id>urn:sha1:f2d282e1dfb3d8cb95b5ccdea43f2411f27201db</id>
<content type='text'>
Pull bitmap updates from Yury Norov:

 - find_random_bit() series (Yury)

 - GENMASK() consolidation (Vincent)

 - random cleanups (Shaopeng, Ben, Yury)

* tag 'bitmap-for-6.17' of https://github.com/norov/linux:
  bitfield: Ensure the return values of helper functions are checked
  test_bits: add tests for __GENMASK() and __GENMASK_ULL()
  bits: unify the non-asm GENMASK*()
  bits: split the definition of the asm and non-asm GENMASK*()
  cpumask: Remove unnecessary cpumask_nth_andnot()
  watchdog: fix opencoded cpumask_next_wrap() in watchdog_next_cpu()
  clocksource: Improve randomness in clocksource_verify_choose_cpus()
  cpumask: introduce cpumask_random()
  bitmap: generalize node_random()
</content>
</entry>
<entry>
<title>cpumask: Remove unnecessary cpumask_nth_andnot()</title>
<updated>2025-07-31T15:28:03+00:00</updated>
<author>
<name>Shaopeng Tan</name>
<email>tan.shaopeng@jp.fujitsu.com</email>
</author>
<published>2025-06-23T07:46:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=b0c85e99458af829c32c225b43f638443bff14e5'/>
<id>urn:sha1:b0c85e99458af829c32c225b43f638443bff14e5</id>
<content type='text'>
Commit 94f753143028("x86/resctrl: Optimize cpumask_any_housekeeping()")
switched the only user of cpumask_nth_andnot() to other cpumask
functions, but left the function cpumask_nth_andnot() unused.
This makes function find_nth_andnot_bit() unused as well. Delete them.

Signed-off-by: Shaopeng Tan &lt;tan.shaopeng@jp.fujitsu.com&gt;
Signed-off-by: Yury Norov [NVIDIA] &lt;yury.norov@gmail.com&gt;
</content>
</entry>
<entry>
<title>cpumask: introduce cpumask_random()</title>
<updated>2025-07-08T23:11:57+00:00</updated>
<author>
<name>Yury Norov [NVIDIA]</name>
<email>yury.norov@gmail.com</email>
</author>
<published>2025-06-19T18:26:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=012b1043420c0bc62e52902499de40b66f37fd6a'/>
<id>urn:sha1:012b1043420c0bc62e52902499de40b66f37fd6a</id>
<content type='text'>
Propagate find_random_bit() to cpumask API.

CC: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: "Yury Norov [NVIDIA]" &lt;yury.norov@gmail.com&gt;
</content>
</entry>
<entry>
<title>cpumask: add cpumask_clear_cpus()</title>
<updated>2025-06-26T09:19:15+00:00</updated>
<author>
<name>Yury Norov [NVIDIA]</name>
<email>yury.norov@gmail.com</email>
</author>
<published>2025-06-04T19:39:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=16e2707cf15e09234445d40ddd76f11240be8767'/>
<id>urn:sha1:16e2707cf15e09234445d40ddd76f11240be8767</id>
<content type='text'>
When user wants to clear a range in cpumask, the only option the API
provides now is a for-loop, like:

	for_each_cpu_from(cpu, mask) {
		if (cpu &gt;= ncpus)
			break;
		__cpumask_clear_cpu(cpu, mask);
	}

In the bitmap API we have bitmap_clear() for that, which is
significantly faster than a for-loop. Propagate it to cpumasks.

Signed-off-by: Yury Norov [NVIDIA] &lt;yury.norov@gmail.com&gt;
Link: https://patch.msgid.link/20250604193947.11834-2-yury.norov@gmail.com
Signed-off-by: Leon Romanovsky &lt;leon@kernel.org&gt;
</content>
</entry>
<entry>
<title>Merge tag 'bitmap-for-6.16-rc1' of https://github.com/norov/linux</title>
<updated>2025-06-03T14:39:23+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2025-06-03T14:39:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=8b2198f03776c5c25f0cafe0ba5c0c60807b554b'/>
<id>urn:sha1:8b2198f03776c5c25f0cafe0ba5c0c60807b554b</id>
<content type='text'>
Pull bitmap updates from Yury Norov:

 - dead code cleanups for cpumasks and nodemasks (me)

 - fixed-width flavors of GENMASK() and BIT() (Vincent, Lucas and me)

 - FIELD_MODIFY() helper (Luo)

 - for_each_node_with_cpus() optimization (me)

 - bitmap-str fixes (Andy)

* tag 'bitmap-for-6.16-rc1' of https://github.com/norov/linux:
  topology: make for_each_node_with_cpus() O(N)
  bitfield: Add FIELD_MODIFY() helper
  bitmap-str: Add missing header(s)
  bitmap-str: Get rid of 'extern' for function prototypes
  build_bug.h: more user friendly error messages in BUILD_BUG_ON_ZERO()
  test_bits: add tests for BIT_U*()
  test_bits: add tests for GENMASK_U*()
  drm/i915: Convert REG_GENMASK*() to fixed-width GENMASK_U*()
  bits: introduce fixed-type BIT_U*()
  bits: introduce fixed-type GENMASK_U*()
  bits: add comments and newlines to #if, #else and #endif directives
  cpumask: drop cpumask_assign_cpu()
  riscv: switch set_icache_stale_mask() to using non-atomic assign_cpu()
  cpumask: add non-atomic __assign_cpu()
  nodemask: drop nodes_shift
</content>
</entry>
<entry>
<title>cpumask: Add cpumask_{first,next}_andnot() API</title>
<updated>2025-05-15T18:28:12+00:00</updated>
<author>
<name>Yury Norov [NVIDIA]</name>
<email>yury.norov@gmail.com</email>
</author>
<published>2025-05-15T16:58:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=5da703ef4e4a82b2f9a00f2b3a1eae5657e68a92'/>
<id>urn:sha1:5da703ef4e4a82b2f9a00f2b3a1eae5657e68a92</id>
<content type='text'>
With the lack of the functions, client code has to abuse less efficient
cpumask_nth().

Signed-off-by: Yury Norov [NVIDIA] &lt;yury.norov@gmail.com&gt;
Signed-off-by: James Morse &lt;james.morse@arm.com&gt;
Signed-off-by: Borislav Petkov (AMD) &lt;bp@alien8.de&gt;
Reviewed-by: James Morse &lt;james.morse@arm.com&gt;
Reviewed-by: Reinette Chatre &lt;reinette.chatre@intel.com&gt;
Reviewed-by: Fenghua Yu &lt;fenghuay@nvidia.com&gt;
Tested-by: Fenghua Yu &lt;fenghuay@nvidia.com&gt;
Tested-by: James Morse &lt;james.morse@arm.com&gt;
Tested-by: Tony Luck &lt;tony.luck@intel.com&gt;
Link: https://lore.kernel.org/20250515165855.31452-4-james.morse@arm.com
</content>
</entry>
<entry>
<title>cpumask: Relax cpumask_any_but()</title>
<updated>2025-05-15T18:24:22+00:00</updated>
<author>
<name>Yury Norov [NVIDIA]</name>
<email>yury.norov@gmail.com</email>
</author>
<published>2025-05-15T16:58:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=189572bf4e005431051319def435ac4b7e4489ca'/>
<id>urn:sha1:189572bf4e005431051319def435ac4b7e4489ca</id>
<content type='text'>
Similarly to other cpumask search functions, accept -1, and consider it as
'any CPU' hint. This helps users to avoid coding special cases.

Signed-off-by: Yury Norov [NVIDIA] &lt;yury.norov@gmail.com&gt;
Signed-off-by: James Morse &lt;james.morse@arm.com&gt;
Signed-off-by: Borislav Petkov (AMD) &lt;bp@alien8.de&gt;
Reviewed-by: James Morse &lt;james.morse@arm.com&gt;
Reviewed-by: Reinette Chatre &lt;reinette.chatre@intel.com&gt;
Reviewed-by: Fenghua Yu &lt;fenghuay@nvidia.com&gt;
Tested-by: James Morse &lt;james.morse@arm.com&gt;
Tested-by: Tony Luck &lt;tony.luck@intel.com&gt;
Tested-by: Fenghua Yu &lt;fenghuay@nvidia.com&gt;
Link: https://lore.kernel.org/20250515165855.31452-2-james.morse@arm.com
</content>
</entry>
<entry>
<title>cpumask: drop cpumask_assign_cpu()</title>
<updated>2025-04-29T19:58:38+00:00</updated>
<author>
<name>Yury Norov</name>
<email>yury.norov@gmail.com</email>
</author>
<published>2025-03-13T02:19:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=791a9b25ce2e6ecbe404ee32eed8a96a17e52896'/>
<id>urn:sha1:791a9b25ce2e6ecbe404ee32eed8a96a17e52896</id>
<content type='text'>
Commit decde1fa209323c7 ("cpumask: Add assign cpu") was merged bypassing
cpumasks reviewers. It adds atomic and non-atomic cpumask_assign_cpu()
helpers.

In the same merge window, commit 5c563ee90a22d3 ("cpumask: introduce
assign_cpu() macro") added the same functionality. So now we have it
duplicated.

__cpumask_assign_cpu() has never been used since introducing, and because
this series reworks the only user of cpumask_assign_cpu(), both functions
become a dead code.

Signed-off-by: Yury Norov [NVIDIA] &lt;yury.norov@gmail.com&gt;
</content>
</entry>
<entry>
<title>cpumask: add non-atomic __assign_cpu()</title>
<updated>2025-04-29T19:58:37+00:00</updated>
<author>
<name>Yury Norov</name>
<email>yury.norov@gmail.com</email>
</author>
<published>2025-03-13T02:19:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=4923c2c5b66fe8dea1df5e16d61f15c1dbea5ba1'/>
<id>urn:sha1:4923c2c5b66fe8dea1df5e16d61f15c1dbea5ba1</id>
<content type='text'>
Similarly to atomic, add a non-atomic version.

Signed-off-by: Yury Norov [NVIDIA] &lt;yury.norov@gmail.com&gt;
</content>
</entry>
<entry>
<title>cpumask: align text in comment</title>
<updated>2025-03-20T21:33:31+00:00</updated>
<author>
<name>Joel Savitz</name>
<email>jsavitz@redhat.com</email>
</author>
<published>2025-03-19T16:12:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=1cf8e152e8c909c2d6c610b35278a7480af7a156'/>
<id>urn:sha1:1cf8e152e8c909c2d6c610b35278a7480af7a156</id>
<content type='text'>
Since commit 4e1a7df45480 ("cpumask: Add enabled cpumask
for present CPUs that can be brought online") introduced
cpu_enabled_mask, the comment line describing the mask
has been slightly out of alignment with the adjacent
lines.

Fix this by removing a single space character.

Signed-off-by: Joel Savitz &lt;jsavitz@redhat.com&gt;
Signed-off-by: Yury Norov &lt;yury.norov@gmail.com&gt;
</content>
</entry>
</feed>
