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: <YxjBSxtoav7PQVei@nazgul.tnic>
Date:   Wed, 7 Sep 2022 18:05:31 +0200
From:   Borislav Petkov <bp@...en8.de>
To:     Davidlohr Bueso <dave@...olabs.net>
Cc:     dan.j.williams@...el.com, x86@...nel.org, nvdimm@...ts.linux.dev,
        linux-cxl@...r.kernel.org, peterz@...radead.org,
        akpm@...ux-foundation.org, dave.jiang@...el.com,
        Jonathan.Cameron@...wei.com, vishal.l.verma@...el.com,
        ira.weiny@...el.com, a.manzanares@...sung.com,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH -next] memregion: Add arch_flush_memregion() interface

On Mon, Aug 29, 2022 at 02:29:18PM -0700, Davidlohr Bueso wrote:
> diff --git a/arch/x86/mm/pat/set_memory.c b/arch/x86/mm/pat/set_memory.c
> index 1abd5438f126..18463cb704fb 100644
> --- a/arch/x86/mm/pat/set_memory.c
> +++ b/arch/x86/mm/pat/set_memory.c
> @@ -330,6 +330,20 @@ void arch_invalidate_pmem(void *addr, size_t size)
>  EXPORT_SYMBOL_GPL(arch_invalidate_pmem);
>  #endif
>  
> +#ifdef CONFIG_ARCH_HAS_MEMREGION_INVALIDATE
> +bool arch_has_flush_memregion(void)
> +{
> +	return !cpu_feature_enabled(X86_FEATURE_HYPERVISOR);

This looks really weird. Why does this need to care about HV at all?

Does that nfit stuff even run in guests?

> +EXPORT_SYMBOL(arch_has_flush_memregion);

...

> +EXPORT_SYMBOL(arch_flush_memregion);

Why aren't those exports _GPL?

Thx.

-- 
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ