projects
/
platform
/
kernel
/
linux-starfive.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Merge tag 'kvm-s390-master-6.0-1' of git://git.kernel.org/pub/scm/linux/kernel/git...
[platform/kernel/linux-starfive.git]
/
lib
/
lru_cache.c
diff --git
a/lib/lru_cache.c
b/lib/lru_cache.c
index
52313ac
..
dc35464
100644
(file)
--- a/
lib/lru_cache.c
+++ b/
lib/lru_cache.c
@@
-147,8
+147,8
@@
struct lru_cache *lc_create(const char *name, struct kmem_cache *cache,
return lc;
/* else: could not allocate all elements, give up */
-
for (i--; i; i--
) {
- void *p = element[i];
+
while (i
) {
+ void *p = element[
--
i];
kmem_cache_free(cache, p - e_off);
}
kfree(lc);