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: Fri, 29 Mar 2024 08:43:13 +0100
From: Ingo Molnar <mingo@...nel.org>
To: Andrii Nakryiko <andrii@...nel.org>
Cc: x86@...nel.org, peterz@...radead.org, mingo@...hat.com,
	tglx@...utronix.de, bpf@...r.kernel.org,
	linux-kernel@...r.kernel.org, jolsa@...nel.org, song@...nel.org,
	kernel-team@...a.com
Subject: Re: [PATCH v2] perf/x86/amd: support capturing LBR from software
 events


* Andrii Nakryiko <andrii@...nel.org> wrote:

> Now that it's possible to capture LBR on AMD CPU from BPF at arbitrary
> point, there is no reason to artificially limit this feature to sampling
> events. So corresponding check is removed. AFAIU, there is no
> correctness implications of doing this (and it was possible to bypass
> this check by just setting perf_event's sample_period to 1 anyways, so
> it doesn't guard all that much).

> diff --git a/arch/x86/events/amd/lbr.c b/arch/x86/events/amd/lbr.c
> index 4a1e600314d5..75920f895d67 100644
> --- a/arch/x86/events/amd/lbr.c
> +++ b/arch/x86/events/amd/lbr.c
> @@ -310,10 +310,6 @@ int amd_pmu_lbr_hw_config(struct perf_event *event)
>  {
>  	int ret = 0;
>  
> -	/* LBR is not recommended in counting mode */
> -	if (!is_sampling_event(event))
> -		return -EINVAL;
> -

Could you please split out this change into a separate patch?

Thanks,

	Ingo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ