diff options
Diffstat (limited to 'lib/idr.c')
-rw-r--r-- | lib/idr.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -814,10 +814,10 @@ void *idr_replace(struct idr *idp, void *ptr, int id) p = idp->top; if (!p) - return ERR_PTR(-EINVAL); + return ERR_PTR(-ENOENT); if (id > idr_max(p->layer + 1)) - return ERR_PTR(-EINVAL); + return ERR_PTR(-ENOENT); n = p->layer * IDR_BITS; while ((n > 0) && p) { |