mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
* [ptxdist] [PATCH] kernel/perf: Fix host path leakage
@ 2024-05-21 17:14 Uwe Kleine-König
  2024-06-10 19:41 ` [ptxdist] [APPLIED] " Michael Olbrich
  0 siblings, 1 reply; 2+ messages in thread
From: Uwe Kleine-König @ 2024-05-21 17:14 UTC (permalink / raw)
  To: ptxdist

The perf build scripts default to prefix=$HOME, resulting in:

	# perf script -l
	open(/home/ukl/libexec/perf-core/scripts) failed.
	Check "PERF_EXEC_PATH" env to set scripts dir.

when I run ptxdist with HOME=/home/ukl. So set prefix explicitly.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
---
Hello,

this obviously only improves the error message to:

	open(/usr/libexec/perf-core/scripts) failed

only. Actually I'd like to call tools/perf_install. However I fail to
see how I'd do that in the kernel's install stage with the right
variables set and upstream is broken here (as of 6.9) which makes
tools/perf_install fail with:

	/bin/sh: 1: cd: can't cd to $BUILDDIR/tools/perf/tools/perf/

and I fail to see where this happens. So here comes only a partial fix
(which IMHO is worth applying anyhow).

Best regards
Uwe

 rules/kernel.make | 1 +
 1 file changed, 1 insertion(+)

diff --git a/rules/kernel.make b/rules/kernel.make
index 0fe4f1e1b12a..24aa221e1bd0 100644
--- a/rules/kernel.make
+++ b/rules/kernel.make
@@ -207,6 +207,7 @@ KERNEL_TOOL_PERF_OPTS	:= \
 	-C $(KERNEL_DIR)/tools/perf \
 	O=$(KERNEL_BUILD_DIR)/tools/perf \
 	$(KERNEL_BASE_OPT) \
+	prefix=/usr \
 	WERROR=0 \
 	NO_LIBPERL=1 \
 	NO_LIBPYTHON=1 \

base-commit: b114f7eb008dee7fab8140bf51cef436d7d57e60
-- 
2.43.0




^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [ptxdist] [APPLIED] kernel/perf: Fix host path leakage
  2024-05-21 17:14 [ptxdist] [PATCH] kernel/perf: Fix host path leakage Uwe Kleine-König
@ 2024-06-10 19:41 ` Michael Olbrich
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Olbrich @ 2024-06-10 19:41 UTC (permalink / raw)
  To: ptxdist; +Cc: Uwe Kleine-König

Thanks, applied as fc5257435efffd0c1ae15b4fea01458d225e5bca.

Michael

[sent from post-receive hook]

On Mon, 10 Jun 2024 21:41:18 +0200, Uwe Kleine-König <u.kleine-koenig@pengutronix.de> wrote:
> The perf build scripts default to prefix=$HOME, resulting in:
> 
> 	# perf script -l
> 	open(/home/ukl/libexec/perf-core/scripts) failed.
> 	Check "PERF_EXEC_PATH" env to set scripts dir.
> 
> when I run ptxdist with HOME=/home/ukl. So set prefix explicitly.
> 
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
> Message-Id: <20240521171452.96051-2-u.kleine-koenig@pengutronix.de>
> Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
> 
> diff --git a/rules/kernel.make b/rules/kernel.make
> index 0fe4f1e1b12a..24aa221e1bd0 100644
> --- a/rules/kernel.make
> +++ b/rules/kernel.make
> @@ -207,6 +207,7 @@ KERNEL_TOOL_PERF_OPTS	:= \
>  	-C $(KERNEL_DIR)/tools/perf \
>  	O=$(KERNEL_BUILD_DIR)/tools/perf \
>  	$(KERNEL_BASE_OPT) \
> +	prefix=/usr \
>  	WERROR=0 \
>  	NO_LIBPERL=1 \
>  	NO_LIBPYTHON=1 \



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-06-10 19:41 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-05-21 17:14 [ptxdist] [PATCH] kernel/perf: Fix host path leakage Uwe Kleine-König
2024-06-10 19:41 ` [ptxdist] [APPLIED] " Michael Olbrich

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox