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: <CAA8ajJ=UYjqVkvxKDTQNpSWpz7+p0+0Ckavpotkh5qUzd1qc0w@mail.gmail.com>
Date: Tue, 10 Dec 2024 22:12:36 -0800
From: Andrew Strohman <andrew@...rewstrohman.com>
To: Jiri Pirko <jiri@...nulli.us>
Cc: Andrew Lunn <andrew+netdev@...n.ch>, "David S. Miller" <davem@...emloft.net>, 
	Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>, 
	Vladimir Oltean <olteanv@...il.com>, Simon Horman <horms@...nel.org>, netdev@...r.kernel.org, 
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH net-next] dsa: Make offloading optional on per port basis

Hi Jiri,

 Thanks for the review.

> Why is this DSA specific?

I can make this more general. I'm not aware of potential
users outside of switchdev and dsa. Are you anticipating
additional users outside of switchdev?

I could make this more general, and just implement
for dsa for now. Then later, if someone else wants
this functionality for switchdev, or something else,
they could implement that part.


> Plus, you say you want to disable offloading
> in general (DSA_FLAG_OFFLOADING_DISABLED), but you check the flag only
> when joining bridge.

I think it's only required for joining a bridge because
that's where dp->bridge gets assigned. All the other
offloading related code paths check dp->bridge
either directly or indirectly, to determine if the port
is offloaded or not before continuing. If you see
an offloading related code path that does not
consider dp->bridge before moving forward,
please let me know.


> I mean, shouldn't this be rather something exposed
> by some common UAPI?
>
> Btw, isn't NETIF_F_HW_L2FW_DOFFLOAD what you are looking for?

It sounds like Vladimir doesn't like this suggestion. So,
I considered introducing another netdev feature for this, but
I noticed that we are currently maxed out since
netdev_features_t is u64 and NETDEV_FEATURE_COUNT
is 64.

I considered changing netdev_features_t to a bitmap,
so that we can keep adding additional features, but
there are users doing bitwise operations directly on
instances of netdev_features_t, so that seems difficult
to untangle.

Do you have a suggestion about how to proceed?
How should I signal that offloading should be disabled?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ