Re: [PATCH bpf-next v3 11/15] libbpf: struct_ops in SEC("?.struct_ops") and SEC("?.struct_ops.link")

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

 



On Tue, 2024-03-05 at 11:55 -0800, Andrii Nakryiko wrote:
[...]

> > @@ -3688,7 +3699,9 @@ static int bpf_object__elf_collect(struct bpf_object *obj)
> >                                 sec_desc->shdr = sh;
> >                                 sec_desc->data = data;
> >                         } else if (strcmp(name, STRUCT_OPS_SEC) == 0 ||
> > -                                  strcmp(name, STRUCT_OPS_LINK_SEC) == 0) {
> > +                                  strcmp(name, STRUCT_OPS_LINK_SEC) == 0 ||
> > +                                  strcmp(name, OPT_STRUCT_OPS_SEC) == 0 ||
> > +                                  strcmp(name, OPT_STRUCT_OPS_LINK_SEC) == 0) {
> 
> I'd do just
> 
> strcmp(name, "?" STRUCT_OPS_SEC) == 0 ||
> strcmp(name, "?" STRUCT_OPS_LINK_SEC) == 0 ||

This is better, thank you.





[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