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]
Message-ID: <CAK8P3a3xoUJ=aDROkWQ1Awpu0kiciohL7hJNsQ0Zn0K05bWObQ@mail.gmail.com>
Date:   Sat, 9 Apr 2022 12:33:18 +0200
From:   Arnd Bergmann <arnd@...db.de>
To:     Peter Zijlstra <peterz@...radead.org>
Cc:     Masahiro Yamada <masahiroy@...nel.org>,
        Josh Poimboeuf <jpoimboe@...hat.com>,
        Michal Marek <michal.lkml@...kovi.net>,
        Nick Desaulniers <ndesaulniers@...gle.com>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Linux Kbuild mailing list <linux-kbuild@...r.kernel.org>,
        Sam Ravnborg <sam@...nborg.org>, X86 ML <x86@...nel.org>,
        Arnd Bergmann <arnd@...db.de>,
        Changbin Du <changbin.du@...il.com>
Subject: Re: [PATCH] kbuild: Remove CONFIG_DEBUG_SECTION_MISMATCH

On Fri, Apr 8, 2022 at 9:14 PM Peter Zijlstra <peterz@...radead.org> wrote:
>
> On Sat, Apr 09, 2022 at 03:29:21AM +0900, Masahiro Yamada wrote:
> > Is [2] caused by dead code that was not optimized out
> > due to the unusual inlining decisions by the compiler ?
>
> The complaint is due to SMAP validation; objtool will scream if there's
> a CALL in between STAC/CLAC. The thinking is that since they open a
> security window, we want tight code between them. We also very much
> don't want tracing and other funnies to happen there. As such, any CALL
> is dis-allowed.
>
> This weird option is having us upgrade quite a few 'inline' to
> '__always_inline'.

There is also __attribute__((flatten)), which you can add to the caller
to tell gcc to inline everything it can into this function, without
having to inline it everywhere else.

Would that work here? It sounds like this is what STAC/CLAC actually
requires.

         Arnd

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ