[CRIU] [PATCHv7 1/5] crtools: initial skeleton for cr_service
Ruslan Kuprieiev
kupruser at gmail.com
Fri Sep 13 05:43:56 EDT 2013
Signed-off-by: Ruslan Kuprieiev <kupruser at gmail.com>
-------------- next part --------------
diff --git a/Makefile.crtools b/Makefile.crtools
index 33a9c70..d1c37e8 100644
--- a/Makefile.crtools
+++ b/Makefile.crtools
@@ -53,6 +53,7 @@ obj-y += stats.o
obj-y += string.o
obj-y += sigframe.o
obj-y += arch/$(ARCH)/vdso.o
+obj-y += cr-service.o
ifneq ($(MAKECMDGOALS),clean)
incdeps := y
diff --git a/cr-service.c b/cr-service.c
new file mode 100644
index 0000000..2824d49
--- /dev/null
+++ b/cr-service.c
@@ -0,0 +1,6 @@
+#include "cr-service.h"
+
+int cr_service()
+{
+ return 0;
+}
diff --git a/crtools.c b/crtools.c
index c7bc8b4..788710b 100644
--- a/crtools.c
+++ b/crtools.c
@@ -29,6 +29,7 @@
#include "page-xfer.h"
#include "tty.h"
#include "file-lock.h"
+#include "cr-service.h"
struct cr_options opts;
@@ -334,6 +335,9 @@ int main(int argc, char *argv[])
if (!strcmp(argv[optind], "page-server"))
return cr_page_server(opts.restore_detach);
+ if (!strcmp(argv[optind], "service"))
+ return cr_service();
+
pr_msg("Unknown command \"%s\"\n", argv[optind]);
usage:
pr_msg("\n"
diff --git a/include/cr-service.h b/include/cr-service.h
new file mode 100644
index 0000000..f99d9f1
--- /dev/null
+++ b/include/cr-service.h
@@ -0,0 +1,6 @@
+#ifndef __CR_SERVICE_H__
+#define __CR_SERVICE_H__
+
+int cr_service(void);
+
+#endif
More information about the CRIU
mailing list