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: <ZS+x3oi0N6d3MZ8b@gmail.com>
Date:   Wed, 18 Oct 2023 12:22:22 +0200
From:   Ingo Molnar <mingo@...nel.org>
To:     Thomas Gleixner <tglx@...utronix.de>
Cc:     Hou Wenlong <houwenlong.hwl@...group.com>,
        linux-kernel@...r.kernel.org, Ingo Molnar <mingo@...hat.com>,
        Borislav Petkov <bp@...en8.de>,
        Dave Hansen <dave.hansen@...ux.intel.com>,
        "maintainer:X86 ARCHITECTURE 32-BIT AND 64-BIT" <x86@...nel.org>,
        "H. Peter Anvin" <hpa@...or.com>,
        Andy Lutomirski <luto@...nel.org>,
        Peter Zijlstra <peterz@...radead.org>,
        Tom Lendacky <thomas.lendacky@....com>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Steve Rutherford <srutherford@...gle.com>,
        Michael Kelley <mikelley@...rosoft.com>,
        Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
        Arnd Bergmann <arnd@...db.de>
Subject: Re: [PATCH 2/2] x86/sme: Mark the code as __head in
 mem_encrypt_identity.c


* Thomas Gleixner <tglx@...utronix.de> wrote:

> On Tue, Oct 17 2023 at 14:52, Ingo Molnar wrote:
> > * Hou Wenlong <houwenlong.hwl@...group.com> wrote:
> >> -static inline void __init sme_encrypt_kernel(struct boot_params *bp) { }
> >> -static inline void __init sme_enable(struct boot_params *bp) { }
> >> +static inline void sme_encrypt_kernel(struct boot_params *bp) { }
> >> +static inline void sme_enable(struct boot_params *bp) { }
> >
> > So I think we should preserve the previous convention of marking functions 
> > __init in the header-declaration and at the definition site as well, and do 
> > the same with __head as well?
> 
> I'm not convinced about the value of prototype annotations, but have no
> strong preference either.

So it has some minor documentation purpose: when someone looks up a 
function via the header only (I do that frequently), __init-alike 
annotations really show the intended boot-only limitations of the API.

But that's a really minor Nth order benefit, I have no strong preference 
either.

Thanks,

	Ingo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ