Skip to contentSkip to conversation

fat: remove unused parameter

PATCH Applied Lalit Shankar Chowdhury 2 participants 2 messages Dec 1, 2025 VFAT/FAT/msdos filesystem

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 fat: remove unused parameter

Remove unused inode parameter from fat_cache_alloc().

---
 fs/fat/cache.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
fs/fat/cache.c +2 -2
index 2af424e200b3..4cea26ddc161 100644
@@ -59,7 +59,7 @@ void fat_cache_destroy(void)
 	kmem_cache_destroy(fat_cache_cachep);
 }
 
-static inline struct fat_cache *fat_cache_alloc(struct inode *inode)
+static inline struct fat_cache *fat_cache_alloc(void)
 {
 	return kmem_cache_alloc(fat_cache_cachep, GFP_NOFS);
 }
@@ -149,7 +149,7 @@ static void fat_cache_add(struct inode *inode, struct fat_cache_id *new)
 			MSDOS_I(inode)->nr_caches++;
 			spin_unlock(&MSDOS_I(inode)->cache_lru_lock);
 
-			tmp = fat_cache_alloc(inode);
+			tmp = fat_cache_alloc();
 			if (!tmp) {
 				spin_lock(&MSDOS_I(inode)->cache_lru_lock);
 				MSDOS_I(inode)->nr_caches--;
Signature · 1 line
2.52.0
maintainer Acked-by on v1 1/1
#1 lore raw
Quoted 3 lines · Lalit Shankar Chowdhury

Remove unused inode parameter from fat_cache_alloc().

Looks good.

Quoted 26 lines
---
 fs/fat/cache.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
fs/fat/cache.c +2 -2
index 2af424e200b3..4cea26ddc161 100644
@@ -59,7 +59,7 @@ void fat_cache_destroy(void)
 	kmem_cache_destroy(fat_cache_cachep);
 }
 
-static inline struct fat_cache *fat_cache_alloc(struct inode *inode)
+static inline struct fat_cache *fat_cache_alloc(void)
 {
 	return kmem_cache_alloc(fat_cache_cachep, GFP_NOFS);
 }
@@ -149,7 +149,7 @@ static void fat_cache_add(struct inode *inode, struct fat_cache_id *new)
 			MSDOS_I(inode)->nr_caches++;
 			spin_unlock(&MSDOS_I(inode)->cache_lru_lock);
 
-			tmp = fat_cache_alloc(inode);
+			tmp = fat_cache_alloc();
 			if (!tmp) {
 				spin_lock(&MSDOS_I(inode)->cache_lru_lock);
 				MSDOS_I(inode)->nr_caches--;
Signature · 1 line
OGAWA Hirofumi <[email protected]>