diff options
-rw-r--r-- | fs/inotify.c | 2 | ||||
-rw-r--r-- | lib/idr.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/fs/inotify.c b/fs/inotify.c index 868901b..2e4e2a5 100644 --- a/fs/inotify.c +++ b/fs/inotify.c @@ -353,7 +353,7 @@ static int inotify_dev_get_wd(struct inotify_device *dev, do { if (unlikely(!idr_pre_get(&dev->idr, GFP_KERNEL))) return -ENOSPC; - ret = idr_get_new_above(&dev->idr, watch, dev->last_wd, &watch->wd); + ret = idr_get_new_above(&dev->idr, watch, dev->last_wd+1, &watch->wd); } while (ret == -EAGAIN); return ret; @@ -207,7 +207,7 @@ build_up: } /** - * idr_get_new_above - allocate new idr entry above a start id + * idr_get_new_above - allocate new idr entry above or equal to a start id * @idp: idr handle * @ptr: pointer you want associated with the ide * @start_id: id to start search at |