Skip to contentSkip to conversation

9p: hide cachetag option for non-CONFIG_9P_FSCACHE

PATCH In review Arnd Bergmann 2 participants 2 messages Jul 10, 2017 – Jul 11, 2017 9P file system

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 9p: hide cachetag option for non-CONFIG_9P_FSCACHE

show_options cannot print this option when it is disabled in Kconfig:

fs/9p/v9fs.c: In function 'v9fs_show_options':
fs/9p/v9fs.c:140:13: error: 'struct v9fs_session_info' has no member named 'cachetag'; did you mean 'cache'?

Fixes ccb0055985b9 ("9p: Implement show_options")
---
 fs/9p/v9fs.c | 2 ++
 1 file changed, 2 insertions(+)
fs/9p/v9fs.c +2 -0
index d69046650a36..8fb89ddc6cc7 100644
@@ -137,8 +137,10 @@ int v9fs_show_options(struct seq_file *m, struct dentry *root)
 		seq_puts(m, ",nodevmap");
 	if (v9ses->cache)
 		seq_printf(m, ",%s", v9fs_cache_modes[v9ses->cache]);
+#ifdef CONFIG_9P_FSCACHE
 	if (v9ses->cachetag && v9ses->cache == CACHE_FSCACHE)
 		seq_printf(m, ",cachetag=%s", v9ses->cachetag);
+#endif
 
 	switch (v9ses->flags & V9FS_ACCESS_MASK) {
 	case V9FS_ACCESS_USER:
Signature · 1 line
2.9.0
Acked-by on v1 1/1
#1 lore raw
Quoted 7 lines · Arnd Bergmann

show_options cannot print this option when it is disabled in Kconfig:

fs/9p/v9fs.c: In function 'v9fs_show_options':
fs/9p/v9fs.c:140:13: error: 'struct v9fs_session_info' has no member named 'cachetag'; did you mean 'cache'?

Fixes ccb0055985b9 ("9p: Implement show_options")