On 03/18, Andrii Nakryiko wrote: > > > + "syscall\n" > > oh, btw, do we need to save flags register as well or it's handled > somehow? I think according to manual syscall instruction does > something to rflags register. So do we need pushfq before syscall? The comment above entry_SYSCALL_64() says 64-bit SYSCALL saves rip to rcx, clears rflags.RF, then saves rflags to r11 then entry_SYSCALL_64 does pushq %r11 /* pt_regs->flags */ which should be restored on return to userspace. So I think that only X86_EFLAGS_RF can be lost, we probably do not care. Oleg.