]> git.baikalelectronics.ru Git - kernel.git/commit
idr: Fix idr_alloc_u32 on 32-bit systems
authorMatthew Wilcox (Oracle) <willy@infradead.org>
Sat, 2 Nov 2019 04:25:08 +0000 (00:25 -0400)
committerMatthew Wilcox (Oracle) <willy@infradead.org>
Sun, 3 Nov 2019 11:36:50 +0000 (06:36 -0500)
commitb301bd96513da0de796cb090f0cf6a57f60d7891
tree15be71399abd81c6661f5cac4c79b79ec3fdf07e
parent6fbcb1eb02a044047b5b1fc26b2a85b29cd1c9d7
idr: Fix idr_alloc_u32 on 32-bit systems

Attempting to allocate an entry at 0xffffffff when one is already
present would succeed in allocating one at 2^32, which would confuse
everything.  Return -ENOSPC in this case, as expected.

Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
lib/radix-tree.c