On 8/7/21 11:42 AM, Warner Losh wrote:
@@ -459,21 +435,11 @@ int main(int argc, char **argv)
qemu_log("entry 0x" TARGET_ABI_FMT_lx "\n", info->entry);
}
- target_set_brk(info->brk);
- syscall_init();
- signal_init();
-
- /*
- * Now that we've loaded the binary, GUEST_BASE is fixed. Delay
- * generating the prologue until now so that the prologue can take
- * the real value of GUEST_BASE into account.
- */
- tcg_prologue_init(tcg_ctx);
-
/* build Task State */
- memset(ts, 0, sizeof(TaskState));
+ ts = g_new0(TaskState, 1);
init_task_state(ts);
ts->info = info;
+ ts->bprm = &bprm;
cpu->opaque = ts;
target_set_brk(info->brk);
It looks like some of this damage occurs in patch 22
("bsd-user: Move per-cpu code into target_arch_cpu.h")
and could reasonably be squashed back.
Otherwise,
Reviewed-by: Richard Henderson <richard.hender...@linaro.org>
r~