* [PATCH 1/5 v4] fs_pin: Initialize value for fs_pin explicitly
@ 2015-06-06 14:41 Kinglong Mee
0 siblings, 0 replies; only message in thread
From: Kinglong Mee @ 2015-06-06 14:41 UTC (permalink / raw)
To: Al Viro, J. Bruce Fields, linux-fsdevel,
linux-nfs@vger.kernel.org
Cc: NeilBrown, Trond Myklebust, kinglongmee
Without initialized, done in fs_pin at stack space may
contains strange value.
v3, v4,
Adds macro for header file
Signed-off-by: Kinglong Mee <kinglongmee@gmail.com>
---
include/linux/fs_pin.h | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/include/linux/fs_pin.h b/include/linux/fs_pin.h
index 3886b3b..0dde7b7 100644
--- a/include/linux/fs_pin.h
+++ b/include/linux/fs_pin.h
@@ -1,3 +1,6 @@
+#ifndef _LINUX_FS_PIN_H
+#define _LINUX_FS_PIN_H
+
#include <linux/wait.h>
struct fs_pin {
@@ -16,9 +19,12 @@ static inline void init_fs_pin(struct fs_pin *p, void (*kill)(struct fs_pin *))
INIT_HLIST_NODE(&p->s_list);
INIT_HLIST_NODE(&p->m_list);
p->kill = kill;
+ p->done = 0;
}
void pin_remove(struct fs_pin *);
void pin_insert_group(struct fs_pin *, struct vfsmount *, struct hlist_head *);
void pin_insert(struct fs_pin *, struct vfsmount *);
void pin_kill(struct fs_pin *);
+
+#endif
--
2.4.2
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2015-06-06 14:41 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-06 14:41 [PATCH 1/5 v4] fs_pin: Initialize value for fs_pin explicitly Kinglong Mee
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).