Anyone have any issues with this patch? Should I take it in my tree?

-- Steve


On Thu, 12 Jun 2025 10:12:59 -0400
Steven Rostedt <rost...@goodmis.org> wrote:

> From: Steven Rostedt <rost...@goodmis.org>
> 
> The events hugepage_set_pmd, hugepage_set_pud, hugepage_update_pmd and
> hugepage_update_pud are only called when CONFIG_PPC_BOOK3S_64 is defined.
> As each event can take up to 5K regardless if they are used or not, it's
> best not to define them when they are not used. Add #ifdef around these
> events when they are not used.
> 
> Signed-off-by: Steven Rostedt (Google) <rost...@goodmis.org>
> ---
> Note, I will be adding code soon that will make unused events cause a warning.
> 
>  include/trace/events/thp.h | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/include/trace/events/thp.h b/include/trace/events/thp.h
> index f50048af5fcc..c8fe879d5828 100644
> --- a/include/trace/events/thp.h
> +++ b/include/trace/events/thp.h
> @@ -8,6 +8,7 @@
>  #include <linux/types.h>
>  #include <linux/tracepoint.h>
>  
> +#ifdef CONFIG_PPC_BOOK3S_64
>  DECLARE_EVENT_CLASS(hugepage_set,
>  
>           TP_PROTO(unsigned long addr, unsigned long pte),
> @@ -66,6 +67,7 @@ DEFINE_EVENT(hugepage_update, hugepage_update_pud,
>           TP_PROTO(unsigned long addr, unsigned long pud, unsigned long clr, 
> unsigned long set),
>           TP_ARGS(addr, pud, clr, set)

>  );
> +#endif /* CONFIG_PPC_BOOK3S_64 */
>  
>  DECLARE_EVENT_CLASS(migration_pmd,
>  


Reply via email to