Re: [PATCH 3/5] perf: Add pmu get/put

2024-10-31 Thread Peter Zijlstra
On Thu, Oct 31, 2024 at 12:07:42AM -0500, Lucas De Marchi wrote: > On Wed, Oct 23, 2024 at 12:07:58AM -0500, Lucas De Marchi wrote: > > On Tue, Oct 22, 2024 at 11:52:10PM +0200, Peter Zijlstra wrote: > > > On Fri, Oct 18, 2024 at 02:46:31PM -0500, Lucas De Marchi wrote: > > > > > > > I will give t

Re: [PATCH 3/5] perf: Add pmu get/put

2024-10-30 Thread Lucas De Marchi
On Wed, Oct 23, 2024 at 12:07:58AM -0500, Lucas De Marchi wrote: On Tue, Oct 22, 2024 at 11:52:10PM +0200, Peter Zijlstra wrote: On Fri, Oct 18, 2024 at 02:46:31PM -0500, Lucas De Marchi wrote: I will give this a try with i915 and/or xe. Less horrible version here: git://git.kernel.org/pub/

Re: [PATCH 3/5] perf: Add pmu get/put

2024-10-22 Thread Lucas De Marchi
On Tue, Oct 22, 2024 at 11:52:10PM +0200, Peter Zijlstra wrote: On Fri, Oct 18, 2024 at 02:46:31PM -0500, Lucas De Marchi wrote: I will give this a try with i915 and/or xe. Less horrible version here: git://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git perf/pmu-unregister I've

Re: [PATCH 3/5] perf: Add pmu get/put

2024-10-22 Thread Peter Zijlstra
On Fri, Oct 18, 2024 at 02:46:31PM -0500, Lucas De Marchi wrote: > I will give this a try with i915 and/or xe. Less horrible version here: git://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git perf/pmu-unregister I've just pushed it out to the robots, but it builds, passes perf test

Re: [PATCH 3/5] perf: Add pmu get/put

2024-10-18 Thread Lucas De Marchi
On Wed, Oct 16, 2024 at 02:03:02PM +0200, Peter Zijlstra wrote: On Mon, Oct 14, 2024 at 09:25:19PM +0200, Peter Zijlstra wrote: Let me ponder that a little bit. So I did the thing on top of the get/put thing that would allow you to get rid of the ->closed thing, and before I was finished I al

Re: [PATCH 3/5] perf: Add pmu get/put

2024-10-16 Thread Peter Zijlstra
On Mon, Oct 14, 2024 at 09:25:19PM +0200, Peter Zijlstra wrote: > Let me ponder that a little bit. So I did the thing on top of the get/put thing that would allow you to get rid of the ->closed thing, and before I was finished I already hated all of it :-( The thing is, if you're going to the ef

Re: [PATCH 3/5] perf: Add pmu get/put

2024-10-14 Thread Lucas De Marchi
On Mon, Oct 14, 2024 at 09:25:19PM +0200, Peter Zijlstra wrote: On Mon, Oct 14, 2024 at 01:20:34PM -0500, Lucas De Marchi wrote: On Mon, Oct 14, 2024 at 07:32:46PM +0200, Peter Zijlstra wrote: > I'm confused.. probably because I still don't have any clue about > drivers and the above isn't re

Re: [PATCH 3/5] perf: Add pmu get/put

2024-10-14 Thread Peter Zijlstra
On Mon, Oct 14, 2024 at 01:20:34PM -0500, Lucas De Marchi wrote: > On Mon, Oct 14, 2024 at 07:32:46PM +0200, Peter Zijlstra wrote: > > I'm confused.. probably because I still don't have any clue about > > drivers and the above isn't really telling me much either. > > > > I don't see how you get r

Re: [PATCH 3/5] perf: Add pmu get/put

2024-10-14 Thread Lucas De Marchi
On Mon, Oct 14, 2024 at 07:32:46PM +0200, Peter Zijlstra wrote: On Tue, Oct 08, 2024 at 01:34:59PM -0500, Lucas De Marchi wrote: If a pmu is unregistered while there's an active event, perf will still access the pmu via event->pmu, even after the event is destroyed. This makes it difficult for d

Re: [PATCH 3/5] perf: Add pmu get/put

2024-10-14 Thread Peter Zijlstra
On Tue, Oct 08, 2024 at 01:34:59PM -0500, Lucas De Marchi wrote: > If a pmu is unregistered while there's an active event, perf will still > access the pmu via event->pmu, even after the event is destroyed. This > makes it difficult for drivers like i915 that can be unbound from the > HW. > >

Re: [PATCH 3/5] perf: Add pmu get/put

2024-10-09 Thread kernel test robot
el.org/pub/scm/linux/kernel/git/perf/perf-tools-next.git perf-tools-next patch link: https://lore.kernel.org/r/20241008183501.1354695-4-lucas.demarchi%40intel.com patch subject: [PATCH 3/5] perf: Add pmu get/put config: x86_64-kexec (https://download.01.org/0day-ci/archive/20241009/20241009184

[PATCH 3/5] perf: Add pmu get/put

2024-10-08 Thread Lucas De Marchi
If a pmu is unregistered while there's an active event, perf will still access the pmu via event->pmu, even after the event is destroyed. This makes it difficult for drivers like i915 that can be unbound from the HW. BUG: KASAN: use-after-free in exclusive_event_destroy+0xd8/0xf0 R