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] [thread-next>] [day] [month] [year] [list]
Message-ID: <8b3e437e15bfd7f063b41b17ea32311d084a92bc.camel@kernel.org>
Date:   Tue, 13 Apr 2021 15:40:24 -0700
From:   Saeed Mahameed <saeed@...nel.org>
To:     Jakub Kicinski <kuba@...nel.org>
Cc:     "David S. Miller" <davem@...emloft.net>, netdev@...r.kernel.org,
        Tariq Toukan <tariqt@...dia.com>,
        Parav Pandit <parav@...dia.com>, Roi Dayan <roid@...dia.com>,
        Vu Pham <vuhuong@...dia.com>
Subject: Re: [net-next 01/16] net/mlx5: E-Switch, let user to enable disable
 metadata

On Tue, 2021-04-13 at 13:21 -0700, Jakub Kicinski wrote:
> On Tue, 13 Apr 2021 12:29:51 -0700 Saeed Mahameed wrote:
> > Currently each packet inserted in eswitch is tagged with a internal
> > metadata to indicate source vport. Metadata tagging is not always
> > needed. Metadata insertion is needed for multi-port RoCE, failover
> > between representors and stacked devices. In many other cases,
> > metadata enablement is not needed.
> > 
> > Metadata insertion slows down the packet processing rate.
> 
> Can you share example numbers?

I remember it was substantial, i don't know the exact numbers. it might
depend on the use case: Parav, do you know ?

> 
> > Hence, allow user to disable metadata using driver specific devlink
> > parameter.
> > 
> > Example to show and disable metadata before changing eswitch mode:
> > $ devlink dev param show pci/0000:06:00.0 name esw_port_metadata
> > pci/0000:06:00.0:
> >   name esw_port_metadata type driver-specific
> >     values:
> >       cmode runtime value true
> > 
> > $ devlink dev param set pci/0000:06:00.0 \
> >           name esw_port_metadata value false cmode runtime
> > 
> > $ devlink dev eswitch set pci/0000:06:00.0 mode switchdev
> 
> Is this something that only gets enabled when device is put into
> switchdev mode? That needs to be clarified in the documentation IMO 
> to give peace of mind to all users who don't enable switchdev.

Currently this is always enabled when switchdev is turned on, it
affects the whole operation mode of the FDB and the offloaded flows so
it can't be dynamic, it must be decided before user enables switchdev,
it is needed only to allow LAG use cases, hence we add a disable knob
for those who don't want LAG and could use some more packet rate.

Some documentation was pushed as part of this patch:
please let me know if it needs improvement. (maybe we should add the
benefit of packet rate ?)


 .../device_drivers/ethernet/mellanox/mlx5.rst | 23 +++++++

+esw_port_metadata: Eswitch port metadata state
+----------------------------------------------
+Eswitch port metadata state controls whether to internally tag packet
with metadata or not.
+Metadata tagging must be enabled for multi-port RoCE, failover between
representors and stacked devices.
+By default metadata is enabled on the supported devices. When metadata
usage is not needed,
+user can disable metadata tagging before moving the eswitch to
switchdev mode.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ