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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240506125847.GTZjjUB6D_cClwghMc@fat_crate.local>
Date: Mon, 6 May 2024 14:58:47 +0200
From: Borislav Petkov <bp@...en8.de>
To: Ravi Bangoria <ravi.bangoria@....com>
Cc: tglx@...utronix.de, mingo@...hat.com, dave.hansen@...ux.intel.com,
	seanjc@...gle.com, pbonzini@...hat.com, thomas.lendacky@....com,
	hpa@...or.com, rmk+kernel@...linux.org.uk, peterz@...radead.org,
	james.morse@....com, lukas.bulwahn@...il.com, arjan@...ux.intel.com,
	j.granados@...sung.com, sibs@...natelecom.cn, nik.borisov@...e.com,
	michael.roth@....com, nikunj.dadhania@....com, babu.moger@....com,
	x86@...nel.org, kvm@...r.kernel.org, linux-kernel@...r.kernel.org,
	santosh.shukla@....com, ananth.narayan@....com,
	sandipan.das@....com
Subject: Re: [PATCH 1/3] x86/split_lock: Move Split and Bus lock code to a
 dedicated file

On Mon, Apr 29, 2024 at 11:36:41AM +0530, Ravi Bangoria wrote:
> Upcoming AMD uarch will support Bus Lock Detect, which functionally works
> identical to Intel. Move split_lock and bus_lock specific code from
> intel.c to a dedicated file so that it can be compiled and supported on
> non-intel platforms.
> 
> Signed-off-by: Ravi Bangoria <ravi.bangoria@....com>
> ---
>  arch/x86/include/asm/cpu.h           |   4 +
>  arch/x86/kernel/cpu/Makefile         |   1 +
>  arch/x86/kernel/cpu/intel.c          | 407 ---------------------------
>  arch/x86/kernel/cpu/split-bus-lock.c | 406 ++++++++++++++++++++++++++
>  4 files changed, 411 insertions(+), 407 deletions(-)
>  create mode 100644 arch/x86/kernel/cpu/split-bus-lock.c
> 
> diff --git a/arch/x86/include/asm/cpu.h b/arch/x86/include/asm/cpu.h
> index aa30fd8cad7f..4b5c31dc8112 100644
> --- a/arch/x86/include/asm/cpu.h
> +++ b/arch/x86/include/asm/cpu.h
> @@ -51,6 +51,10 @@ static inline u8 get_this_hybrid_cpu_type(void)
>  	return 0;
>  }
>  #endif
> +
> +void split_lock_init(void);
> +void bus_lock_init(void);
> +
>  #ifdef CONFIG_IA32_FEAT_CTL
>  void init_ia32_feat_ctl(struct cpuinfo_x86 *c);
>  #else
> diff --git a/arch/x86/kernel/cpu/Makefile b/arch/x86/kernel/cpu/Makefile
> index eb4dbcdf41f1..86a10472ad1d 100644
> --- a/arch/x86/kernel/cpu/Makefile
> +++ b/arch/x86/kernel/cpu/Makefile
> @@ -27,6 +27,7 @@ obj-y			+= aperfmperf.o
>  obj-y			+= cpuid-deps.o
>  obj-y			+= umwait.o
>  obj-y 			+= capflags.o powerflags.o
> +obj-y 			+= split-bus-lock.o

Too fine-grained a name and those "-" should be "_".

Perhaps bus_lock.c only...

-- 
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