lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 26 Nov 2019 20:04:08 -0800
From:   Linus Torvalds <torvalds@...ux-foundation.org>
To:     Oleg Nesterov <oleg@...hat.com>
Cc:     Andrew Morton <akpm@...ux-foundation.org>,
        Andy Lutomirski <luto@...nel.org>,
        Borislav Petkov <bp@...en8.de>, Ingo Molnar <mingo@...nel.org>,
        Jan Kratochvil <jan.kratochvil@...hat.com>,
        Pedro Alves <palves@...hat.com>, Peter Anvin <hpa@...or.com>,
        Thomas Gleixner <tglx@...utronix.de>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        "the arch/x86 maintainers" <x86@...nel.org>
Subject: Re: [PATCH] ptrace/x86: introduce TS_COMPAT_RESTART to fix get_nr_restart_syscall()

On Tue, Nov 26, 2019 at 3:08 AM Oleg Nesterov <oleg@...hat.com> wrote:
>
> Alternatively we could add ->compat_restart into struct restart_block,
> logically this is the same thing.

That sounds like the better model to me. That's what the restart_block
is about: it's supposed to contain the restart information.

I'd much rather see the system call number added into the restart
block (or just the "compat bit" - but we have that X32 case too, so
why not put it all there). And then the get_nr_restart_syscall() hack
goes away and is just "set state from the restart block".

How painful would that be? I guess right now we always just set all
the restart_block info manually in all the restart cases, and that
could make it a bit painful to add this kind of architecture-specific
flag, but it _sounds_ conceptually like the right thing to do.

I definitely don't love the "magic sticky bit in thread status" field model.

             Linus

Powered by blists - more mailing lists