On Tue, 8 Mar 2022 at 07:20, Richard Henderson
<richard.hender...@linaro.org> wrote:
>
> The only thing this struct is used for is passing startup values
> from elfload.c to the cpu.  We do not need all registers to be
> represented, we do not need the kernel internal stack slots.
>
> The userland argc, argv, and envp values are passed on
> the stack, so only SP and PC need updating.
>
> Signed-off-by: Richard Henderson <richard.hender...@linaro.org>
> ---
>  linux-user/nios2/target_syscall.h | 25 ++-----------------------
>  linux-user/elfload.c              |  3 +--
>  linux-user/nios2/cpu_loop.c       | 24 +-----------------------
>  3 files changed, 4 insertions(+), 48 deletions(-)

Well, I guess we're not using it for anything else currently,
but if you do this then it's not the target arch's pt_regs
struct any more. And all our other target archs seem to define
the struct to follow the kernel definition even if we don't
happen to use it all.

-- PMM

Reply via email to