[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 08/24] bsd-user/arm/target_arch_cpu.h: Implement data abort e
From: |
Kyle Evans |
Subject: |
Re: [PATCH 08/24] bsd-user/arm/target_arch_cpu.h: Implement data abort exceptions |
Date: |
Tue, 26 Oct 2021 00:47:24 -0500 |
On Tue, Oct 19, 2021 at 11:45 AM Warner Losh <imp@bsdimp.com> wrote:
>
> Implement EXCP_PREFETCH_ABORT AND EXCP_DATA_ABORT. Both of these data
> exceptions cause a SIGSEGV.
>
> Signed-off-by: Klye Evans <kevans@FreeBSD.org>
> Signed-off-by: Olivier Houchard <cognet@ci0.org>
> Signed-off-by: Stacey Son <sson@FreeBSD.org>
> Signed-off-by: Warner Losh <imp@bsdimp.com>
> ---
> bsd-user/arm/target_arch_cpu.h | 11 +++++++++++
> 1 file changed, 11 insertions(+)
>
> diff --git a/bsd-user/arm/target_arch_cpu.h b/bsd-user/arm/target_arch_cpu.h
> index f22384676a..62d6ee89b6 100644
> --- a/bsd-user/arm/target_arch_cpu.h
> +++ b/bsd-user/arm/target_arch_cpu.h
> @@ -60,6 +60,17 @@ static inline void target_cpu_loop(CPUARMState *env)
> case EXCP_INTERRUPT:
> /* just indicate that signals should be handled asap */
> break;
> + case EXCP_PREFETCH_ABORT:
> + /* See arm/arm/trap.c prefetch_abort_handler() */
> + case EXCP_DATA_ABORT:
> + /* See arm/arm/trap.c data_abort_handler() */
> + info.si_signo = TARGET_SIGSEGV;
> + info.si_errno = 0;
> + /* XXX: check env->error_code */
> + info.si_code = 0;
> + info.si_addr = env->exception.vaddress;
> + queue_signal(env, info.si_signo, &info);
> + break;
> case EXCP_DEBUG:
> {
>
> --
> 2.32.0
>
Reviewed-by: Kyle Evans <kevans@FreeBSD.org>
- [PATCH 01/24] bsd-user/arm/target_arch_sysarch.h: Use consistent include guards, (continued)
- [PATCH 01/24] bsd-user/arm/target_arch_sysarch.h: Use consistent include guards, Warner Losh, 2021/10/19
- [PATCH 05/24] bsd-user/arm/target_arch_cpu.h: Implement target_cpu_clone_regs, Warner Losh, 2021/10/19
- [PATCH 07/24] bsd-user/arm/target_arch_cpu.h: Implment trivial EXCP exceptions, Warner Losh, 2021/10/19
- [PATCH 08/24] bsd-user/arm/target_arch_cpu.h: Implement data abort exceptions, Warner Losh, 2021/10/19
- [PATCH 09/24] bsd-user/arm/target_arch_cpu.h: Implement system call dispatch, Warner Losh, 2021/10/19
- [PATCH 12/24] bsd-user/arm/target_arch_sigtramp.h: Signal Trampoline for arm, Warner Losh, 2021/10/19