Re: [PATCH bpf-next] samples: bpf: convert xdp_router_ipv4 to XDP samples helper

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

 



> On Tue, Mar 15, 2022 at 4:06 AM Lorenzo Bianconi <lorenzo@xxxxxxxxxx> wrote:
> >
> > Rely on the libbpf skeleton facility and other utilities provided by XDP
> > sample helpers in xdp_router_ipv4 sample.
> >
> > Signed-off-by: Lorenzo Bianconi <lorenzo@xxxxxxxxxx>
> > ---
> >  samples/bpf/Makefile               |   9 +-
> >  samples/bpf/xdp_router_ipv4.bpf.c  | 180 +++++++++++
> >  samples/bpf/xdp_router_ipv4_kern.c | 186 ------------
> 
> hm... git should be able to record this as a rename and the result
> patch will be much smaller, only showing what really changed. Can you
> check where this went wrong?

I am not so familiar with git internal, but I think it depends on the similarity
between the "old" and "new" files. If they are very different (like in this case),
git will report the "old" file as remove and the creation of the "new" one.
I guess you can try to do "git mv" a given file and overwrite it with a
different one. Am I missing something?

> 
> Please also add libbpf_set_strict_mode(LIBBPF_STRICT_ALL) to enable
> stricter "libbpf 1.0" mode. Thanks!

ack, I will add it in v2.

Regards,
Lorenzo

> 
> >  samples/bpf/xdp_router_ipv4_user.c | 462 ++++++++++++-----------------
> >  4 files changed, 377 insertions(+), 460 deletions(-)
> >  create mode 100644 samples/bpf/xdp_router_ipv4.bpf.c
> >  delete mode 100644 samples/bpf/xdp_router_ipv4_kern.c
> >
> 
> [...]
> 

Attachment: signature.asc
Description: PGP signature


[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