diff options
author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2006-03-20 13:44:48 -0500 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2006-03-20 13:44:48 -0500 |
commit | 01d0ae8beaee75d954900109619b700fe68707d9 (patch) | |
tree | 06180b83f10e0008db9f6bfa6a5fa420bf568ebe /fs/nfs/iostat.h | |
parent | d9f6eb75d4900782a095b98470decfe98971f920 (diff) |
NFSv4: Fix an oops in nfs4_fill_super
The mount statistics patches introduced a call to nfs_free_iostats that is
not only redundant, but actually causes an oops.
Also fix a memory leak due to the lack of a call to nfs_free_iostats on
unmount.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs/iostat.h')
-rw-r--r-- | fs/nfs/iostat.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/nfs/iostat.h b/fs/nfs/iostat.h index 7a7495153317..6350ecbde589 100644 --- a/fs/nfs/iostat.h +++ b/fs/nfs/iostat.h | |||
@@ -156,7 +156,8 @@ static inline struct nfs_iostats *nfs_alloc_iostats(void) | |||
156 | 156 | ||
157 | static inline void nfs_free_iostats(struct nfs_iostats *stats) | 157 | static inline void nfs_free_iostats(struct nfs_iostats *stats) |
158 | { | 158 | { |
159 | free_percpu(stats); | 159 | if (stats != NULL) |
160 | free_percpu(stats); | ||
160 | } | 161 | } |
161 | 162 | ||
162 | #endif | 163 | #endif |