All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH linux-cr] cr: fs/inode.c: make sure ckpt_obj_register() actually runs
@ 2010-04-13 20:35 Serge E. Hallyn
       [not found] ` <20100413203535.GA9187-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
  0 siblings, 1 reply; 4+ messages in thread
From: Serge E. Hallyn @ 2010-04-13 20:35 UTC (permalink / raw)
  To: Matt Helsley; +Cc: Linux Containers

[ This is against Matt's code-shuffled patchset ]

So put it in its own, explicitly-called init function.

Without this, on my s390x sles11 system CKPT_OBJ_INODE does not,
in fact, get registered.  With, it does, and cr_tests/bashckpt
passes.

Signed-off-by: Serge E. Hallyn <serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
---
 fs/inode.c |   13 +++++++++----
 1 files changed, 9 insertions(+), 4 deletions(-)

diff --git a/fs/inode.c b/fs/inode.c
index 1fcaf64..5121790 100644
--- a/fs/inode.c
+++ b/fs/inode.c
@@ -1582,6 +1582,15 @@ static const struct ckpt_obj_ops ckpt_obj_inode_ops = {
 	.ref_drop = obj_inode_drop,
 	.ref_grab = obj_inode_grab,
 };
+
+static int inode_ckpt_init(void)
+{
+	int ret = ckpt_obj_register(&ckpt_obj_inode_ops);
+	printk(KERN_NOTICE "%s: ckpt_obj_register for inode returned %d\n",
+		__func__, ret);
+	return ret;
+}
+__initcall(inode_ckpt_init);
 #endif
 
 void __init inode_init(void)
@@ -1613,10 +1622,6 @@ void __init inode_init(void)
 
 	for (loop = 0; loop < (1 << i_hash_shift); loop++)
 		INIT_HLIST_HEAD(&inode_hashtable[loop]);
-
-#ifdef CONFIG_CHECKPOINT
-	ckpt_obj_register(&ckpt_obj_inode_ops);
-#endif
 }
 
 void init_special_inode(struct inode *inode, umode_t mode, dev_t rdev)
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2010-04-13 23:07 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-04-13 20:35 [PATCH linux-cr] cr: fs/inode.c: make sure ckpt_obj_register() actually runs Serge E. Hallyn
     [not found] ` <20100413203535.GA9187-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2010-04-13 21:32   ` Matt Helsley
     [not found]     ` <20100413213217.GF25363-52DBMbEzqgQ/wnmkkaCWp/UQ3DHhIser@public.gmane.org>
2010-04-13 22:09       ` Serge E. Hallyn
     [not found]         ` <20100413220931.GB13309-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2010-04-13 23:07           ` Matt Helsley

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.