diff options
Diffstat (limited to 'fs/9p')
-rw-r--r-- | fs/9p/v9fs.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/fs/9p/v9fs.c b/fs/9p/v9fs.c index 58e6cbc..08f2e1e 100644 --- a/fs/9p/v9fs.c +++ b/fs/9p/v9fs.c @@ -603,10 +603,11 @@ static int v9fs_cache_register(void) if (ret < 0) return ret; #ifdef CONFIG_9P_FSCACHE - return fscache_register_netfs(&v9fs_cache_netfs); -#else - return ret; + ret = fscache_register_netfs(&v9fs_cache_netfs); + if (ret < 0) + v9fs_destroy_inode_cache(); #endif + return ret; } static void v9fs_cache_unregister(void) |