milis/talimatname/genel/k/kernel/vfs-ino.patch

24 lines
589 B
Diff
Raw Normal View History

2018-06-09 00:06:58 +02:00
SPDX-License-Identifier: GPL-2.0
diff --git a/fs/inode.c b/fs/inode.c
2018-08-17 08:35:48 +02:00
index 3b55391..94924d2 100644
2018-06-09 00:06:58 +02:00
--- a/fs/inode.c
+++ b/fs/inode.c
2018-08-17 08:35:48 +02:00
@@ -861,6 +861,8 @@ unsigned int get_next_ino(void)
2018-06-09 00:06:58 +02:00
unsigned int *p = &get_cpu_var(last_ino);
unsigned int res = *p;
+start:
+
#ifdef CONFIG_SMP
if (unlikely((res & (LAST_INO_BATCH-1)) == 0)) {
static atomic_t shared_last_ino;
2018-08-17 08:35:48 +02:00
@@ -873,7 +875,7 @@ unsigned int get_next_ino(void)
2018-06-09 00:06:58 +02:00
res++;
/* get_next_ino should not provide a 0 inode number */
if (unlikely(!res))
- res++;
+ goto start;
*p = res;
put_cpu_var(last_ino);
return res;