linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH 0/1] IDR fix for potential id mismatch
@ 2025-11-27  9:27 Jan Sokolowski
  2025-11-27  9:27 ` [RFC PATCH 1/1] idr: do not create idr if new id would be outside given range Jan Sokolowski
  0 siblings, 1 reply; 12+ messages in thread
From: Jan Sokolowski @ 2025-11-27  9:27 UTC (permalink / raw)
  To: linux-kernel
  Cc: Jan Sokolowski, Christian König, Matthew Wilcox,
	Andrew Morton, linux-fsdevel, linux-mm

When debugging an issue found in drm subsystem (link to the
discussion in Link tag), a bug was found in idr library
where requesting id in range would return id outside
requested range. Didn't see in documentation that this is how
idr should behave.

This is an RFC as this library is deprecated but still in use by other
subsystems. Is this fix proper?

Link: https://lists.freedesktop.org/archives/dri-devel/2025-November/538294.html
Cc: "Christian König" <christian.koenig@amd.com>
Cc: Matthew Wilcox <willy@infradead.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-fsdevel@vger.kernel.org
Cc: linux-mm@kvack.org
Cc: linux-kernel@vger.kernel.org

---
Jan Sokolowski (1):
  idr: do not create idr if new id would be outside given range

 lib/idr.c | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

-- 
2.43.0



^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2025-11-28 17:50 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-11-27  9:27 [RFC PATCH 0/1] IDR fix for potential id mismatch Jan Sokolowski
2025-11-27  9:27 ` [RFC PATCH 1/1] idr: do not create idr if new id would be outside given range Jan Sokolowski
2025-11-27 13:38   ` Matthew Wilcox
2025-11-27 13:54   ` Matthew Wilcox
2025-11-27 14:03     ` Christian König
2025-11-27 14:11       ` Matthew Wilcox
2025-11-27 14:55         ` Matthew Wilcox
2025-11-27 15:02           ` Christian König
2025-11-28  9:03           ` Sokolowski, Jan
2025-11-28 15:52             ` Matthew Wilcox
2025-11-28 16:47               ` Sokolowski, Jan
2025-11-28 17:50                 ` Matthew Wilcox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox