lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Wed, 25 Aug 2021 19:40:00 +0200
From:   Paolo Abeni <pabeni@...hat.com>
To:     Willem de Bruijn <willemdebruijn.kernel@...il.com>
Cc:     netdev@...r.kernel.org, "David S. Miller" <davem@...emloft.net>,
        Jakub Kicinski <kuba@...nel.org>,
        Shuah Khan <shuah@...nel.org>, Coco Li <lixiaoyan@...gle.com>
Subject: Re: [PATCH net-next] selftests/net: allow GRO coalesce test on veth

On Wed, 2021-08-25 at 12:17 -0400, Willem de Bruijn wrote:
> On Wed, Aug 25, 2021 at 6:25 AM Paolo Abeni <pabeni@...hat.com> wrote:
> > This change extends the existing GRO coalesce test to
> > allow running on top of a veth pair, so that no H/W dep
> > is required to run them.
> > 
> > By default gro.sh will use the veth backend, and will try
> > to use exiting H/W in loopback mode if a specific device
> > name is provided with the '-i' command line option.
> > 
> > No functional change is intended for the loopback-based
> > tests, just move all the relevant initialization/cleanup
> > code into the related script.
> > 
> > Introduces a new initialization helper script for the
> > veth backend, and plugs the correct helper script according
> > to the provided command line.
> > 
> > Additionally, enable veth-based tests by default.
> 
> Very nice. Thanks for extending the test to be run as part of
> continuous testing over veth, Paolo.
> 
> > +setup_veth_ns() {
> > +       local -r link_dev="$1"
> > +       local -r ns_name="$2"
> > +       local -r ns_dev="$3"
> > +       local -r ns_mac="$4"
> > +       local -r addr="$5"
> > +
> > +       [[ -e /var/run/netns/"${ns_name}" ]] || ip netns add "${ns_name}"
> > +       echo 100000 > "/sys/class/net/${ns_dev}/gro_flush_timeout"
> > +       ip link set dev "${ns_dev}" netns "${ns_name}" mtu 65535
> > +       ip -netns "${ns_name}" link set dev "${ns_dev}" up
> > +       if [[ -n "${addr}" ]]; then
> > +               ip -netns "${ns_name}" addr add dev "${ns_dev}" "${addr}"
> > +       fi
> 
> unused? setup_veth_ns is always called with four arguments.

yep. Too much C&P from esiting code :(

I'll send a v2 after some more testing.

Thanks!

Paolo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ