Re: [PATCH V3] tracing/timerlat: Hotplug support for the user-space interface

From: Steven Rostedt
Date: Tue Oct 03 2023 - 21:02:07 EST


On Fri, 29 Sep 2023 17:02:46 +0200
Daniel Bristot de Oliveira <bristot@xxxxxxxxxx> wrote:

> The osnoise/per_cpu/CPU$/timerlat_fd is create for each possible
> CPU, but it might create confusion if the CPU is not online.
>
> Create the file only for online CPUs, also follow hotplug by
> creating and deleting as CPUs come and go.
>
> Fixes: e88ed227f639 ("tracing/timerlat: Add user-space interface")

Is this a fix that needs to go in now and Cc'd to stable? Or is this
something that can wait till the next merge window?

-- Steve


> Signed-off-by: Daniel Bristot de Oliveira <bristot@xxxxxxxxxx>
> ---
>
> Changes from V2:
> - Better split the code into the generic (per_cpu/cpu$)
> and timerlat (/timerlat_fd) specific function (Daniel)
> - Fixed a cpus_read_lock/unlock() usage (kbuild test)
> Link: https://lore.kernel.org/lkml/6b9a5f306e488bc77bf8521faeade420a0adf3e4.1695224204.git.bristot@xxxxxxxxxx/
>
> Changes from V1:
> - Fix compilation issue when !HOTPLUG
> - Fix init interface | hotplug race
> Link: https://lore.kernel.org/lkml/b619d9fd08a3bb47018cf40afa95783844a3c1fd.1694789910.git.bristot@xxxxxxxxxx/
>
> kernel/trace/trace_osnoise.c | 149 ++++++++++++++++++++++++++++-------
> 1 file changed, 121 insertions(+), 28 deletions(-)
>
>