Re: [PATCH RFC bpf-next v2 1/4] fprobe: use rhltable for fprobe_ip_table

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jul 29, 2025 at 9:42 AM Masami Hiramatsu <mhiramat@xxxxxxxxxx> wrote:
>
> Hi,
>
> I'll check it deeper, but 2 nits I found.
>
> On Mon, 28 Jul 2025 15:22:50 +0800
> Menglong Dong <menglong8.dong@xxxxxxxxx> wrote:
>
> > diff --git a/kernel/trace/fprobe.c b/kernel/trace/fprobe.c
> > index ba7ff14f5339..640a0c47fc76 100644
> > --- a/kernel/trace/fprobe.c
> > +++ b/kernel/trace/fprobe.c
> > @@ -12,6 +12,7 @@
> >  #include <linux/mutex.h>
> >  #include <linux/slab.h>
> >  #include <linux/sort.h>
> > +#include <linux/rhashtable.h>
>
> nit: Can you sort this alphabetically?

OK!

>
> [...]
> > @@ -249,9 +251,10 @@ static inline int __fprobe_kprobe_handler(unsigned long ip, unsigned long parent
> >  static int fprobe_entry(struct ftrace_graph_ent *trace, struct fgraph_ops *gops,
> >                       struct ftrace_regs *fregs)
> >  {
> > -     struct fprobe_hlist_node *node, *first;
> > +     struct fprobe_hlist_node *node;
> >       unsigned long *fgraph_data = NULL;
> >       unsigned long func = trace->func;
> > +     struct rhlist_head *head, *pos;
>
> nit: Can you sort this as reverse Christmas tree? (like as below)

OK!

>
> >       unsigned long *fgraph_data = NULL;
> >       unsigned long func = trace->func;
> > +     struct fprobe_hlist_node *node;
> > +     struct rhlist_head *head, *pos;
>
>
> >       unsigned long ret_ip;
> >       int reserved_words;
> >       struct fprobe *fp;
>
> Thank you,
>
> --
> Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx>





[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux