From: Petr Oros <poros@redhat.com>
To: netdev-bot+sashiko@kernel.org
Cc: netdev@vger.kernel.org, intel-wired-lan@lists.osuosl.org,
linux-kernel@vger.kernel.org,
Tony Nguyen <anthony.l.nguyen@intel.com>,
Przemek Kitszel <przemyslaw.kitszel@intel.com>,
Andrew Lunn <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@kernel.org>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Aleksandr Loktionov <aleksandr.loktionov@intel.com>,
Simon Horman <horms@kernel.org>,
Michal Swiatkowski <michal.swiatkowski@linux.intel.com>,
Grzegorz Nitka <grzegorz.nitka@intel.com>,
Paul Menzel <pmenzel@molgen.mpg.de>,
Wojciech Drewek <wojciech.drewek@intel.com>,
Marcin Szycik <marcin.szycik@linux.intel.com>,
Martyna Szapar-Mudlaw <martyna.szapar-mudlaw@linux.intel.com>,
Ivan Vecera <ivecera@redhat.com>,
Alice Michael <alice.michael@intel.com>,
Jacob Keller <jacob.e.keller@intel.com>,
Jesse Brandeburg <jbrandeb@kernel.org>,
Patryk Holda <patryk.holda@intel.com>,
Rinitha S <sx.rinitha@intel.com>,
Aaron Ma <aaron.ma@canonical.com>
Subject: Re: [PATCH net v7 3/4] ice: resync uplink filters after a switchdev session
Date: Thu, 3 Dec 2026 10:51:08 +0100 [thread overview]
Message-ID: <20261203095109.3289229-1-poros@redhat.com> (raw)
In-Reply-To: <179628491749.3146.14362879400914207891@kernel.org>
On Wed, Dec 03, 2026 at 08:01:57AM +0000, Sashiko wrote:
> Would a per-VSI mutex around the filter and promisc state give the same
> exclusion, with proper acquire/release semantics?
No, it would give none. The state the two new sections touch is the state
ice_vsi_sync_fltr(), ice_vlan_rx_add_vid() and ice_vlan_rx_kill_vid()
already touch under ICE_CFG_BUSY in vsi->state. A fresh mutex taken only
by the eswitch paths would not exclude any of them and the handoff would
stop working, so all of them would have to be converted at once.
ICE_CFG_BUSY also cannot just become a mutex. ice_reset_subtask(),
ice_watchdog_subtask() and ice_update_vsi_stats() only test_bit() it to
decide whether to skip a pass, so it would first have to be split into a
lock and a separate "reconfiguration in flight" flag, across vsi->state
and pf->state both.
That is a driver wide cleanup, and this is a fix for net with four Fixes
tags reaching back to 1a1c40df2e80 ("ice: set and release switchdev
environment") from 2021, headed for stable. The review found no concrete
deadlock among the current holders, so there is nothing incorrect here to
fix, and using the serialization the driver already has is what keeps the
backport small.
> This version had to switch ice_vsi_sync_fltr() to clear_bit_unlock(),
> but other holders of the same bit still release it with a plain
> clear_bit():
Fair, and pre-existing. Both VLAN ndos write current_netdev_flags and
reprogram promisc rules in their section and release with plain
clear_bit(), which is already weak against ice_vsi_sync_fltr() without
this series. v7 tightened the one release the handoff depends on and left
the rest alone on purpose. I will send the ndos, and the full conversion
if people want it, for net-next.
Thanks,
Petr
next prev parent reply other threads:[~2026-12-03 9:51 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-02 7:16 [PATCH net v7 0/4] ice: fix DFLT Rx rule handling for promisc and switchdev Petr Oros
2026-12-02 7:16 ` [PATCH net v7 1/4] ice: stop the service task before the PF is unloaded Petr Oros
2026-12-03 8:01 ` netdev-bot+sashiko
2026-12-02 7:16 ` [PATCH net v7 2/4] ice: do not leave switchdev mode while subfunction ports exist Petr Oros
2026-12-03 8:01 ` netdev-bot+sashiko
2026-12-02 7:16 ` [PATCH net v7 3/4] ice: resync uplink filters after a switchdev session Petr Oros
2026-12-03 8:01 ` netdev-bot+sashiko
2026-12-03 9:51 ` Petr Oros [this message]
2026-12-02 7:16 ` [PATCH net v7 4/4] ice: use a VLAN agnostic multicast promisc rule pair for PF VSIs Petr Oros
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261203095109.3289229-1-poros@redhat.com \
--to=poros@redhat.com \
--cc=aaron.ma@canonical.com \
--cc=aleksandr.loktionov@intel.com \
--cc=alice.michael@intel.com \
--cc=andrew+netdev@lunn.ch \
--cc=anthony.l.nguyen@intel.com \
--cc=davem@davemloft.net \
--cc=edumazet@kernel.org \
--cc=grzegorz.nitka@intel.com \
--cc=horms@kernel.org \
--cc=intel-wired-lan@lists.osuosl.org \
--cc=ivecera@redhat.com \
--cc=jacob.e.keller@intel.com \
--cc=jbrandeb@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=marcin.szycik@linux.intel.com \
--cc=martyna.szapar-mudlaw@linux.intel.com \
--cc=michal.swiatkowski@linux.intel.com \
--cc=netdev-bot+sashiko@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=patryk.holda@intel.com \
--cc=pmenzel@molgen.mpg.de \
--cc=przemyslaw.kitszel@intel.com \
--cc=sx.rinitha@intel.com \
--cc=wojciech.drewek@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox