Commit 574fe356 authored by Dmitry Safonov's avatar Dmitry Safonov Committed by Andrei Vagin

compel/compat: fixup for head_start addr

Resolves merge conflict with commit 71abfb84e158 ("compel: simplify
usage wrt ids").
Sets start ip for parasite blob according to app mode: native/compat.

travis-ci: success for Rectify 32-bit compatible C/R on x86
Signed-off-by: 's avatarDmitry Safonov <dsafonov@virtuozzo.com>
Signed-off-by: 's avatarPavel Emelyanov <xemul@virtuozzo.com>
Signed-off-by: 's avatarAndrei Vagin <avagin@virtuozzo.com>
parent dc633d86
......@@ -593,8 +593,14 @@ int __handle_elf(void *mem, size_t size)
pr_out("\tpbd->hdr.bsize = sizeof(%s_blob);\n",
opts.prefix);
pr_out("\tpbd->hdr.nr_gotpcrel = %s_nr_gotpcrel;\n", opts.prefix);
pr_out("\tpbd->hdr.parasite_ip_off = "
"%s_sym__export_parasite_head_start;\n", opts.prefix);
pr_out("\tif (compel_mode_native(ctl))\n");
pr_out("\t\tpbd->hdr.parasite_ip_off = "
"%s_sym__export_parasite_head_start;\n", opts.prefix);
pr_out("#ifdef CONFIG_COMPAT\n");
pr_out("\telse\n");
pr_out("\t\tpbd->hdr.parasite_ip_off = "
"%s_sym__export_parasite_head_start_compat;\n", opts.prefix);
pr_out("#endif /* CONFIG_COMPAT */\n");
pr_out("\tpbd->hdr.addr_cmd_off = "
"%s_sym__export_parasite_cmd;\n", opts.prefix);
pr_out("\tpbd->hdr.addr_arg_off = "
......
......@@ -22,7 +22,6 @@ static int do_infection(int pid)
int state;
struct parasite_ctl *ctl;
struct infect_ctx *ictx;
struct parasite_blob_desc *pbd;
int *arg;
compel_log_init(print_vmsg, LOG_DEBUG);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment