Re: [PATCH v17 06/15] arm64: syscall: Rework the syscall exit path in el0_svc_common()
From: Linus Walleij
Date: Tue Jul 21 2026 - 04:50:05 EST
On Tue, Jul 21, 2026 at 10:43 AM Linus Walleij <linusw@xxxxxxxxxx> wrote:
> On Tue, Jul 21, 2026 at 10:19 AM Jinjie Ruan <ruanjinjie@xxxxxxxxxx> wrote:
>
>
> > In preparation for moving arm64 over to the generic entry,
> > invert the nested conditional flags check within el0_svc_common().
> >
> > No functional changes.
> (...)
> > if (!has_syscall_work(flags) && !IS_ENABLED(CONFIG_DEBUG_RSEQ)) {
> > flags = read_thread_flags();
> > - if (!has_syscall_work(flags) && !(flags & _TIF_SINGLESTEP))
> > - return;
> > + if (has_syscall_work(flags) || flags & _TIF_SINGLESTEP)
> > + syscall_trace_exit(regs);
> > + return;
>
> What about just:
>
> if (...)
> goto trace_exit;
>
> This is easier to follow IMO.
>
> With that:
> Reviewed-by: Linus Walleij <linusw@xxxxxxxxxx>
Aha I see you refactor it again in patch 8, no big deal then.
This is fine, add the Reviewed-by.
Yours,
Linus Walleij