From: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
To: kuba@kernel.org, anthony.l.nguyen@intel.com
Cc: aleksandr.loktionov@intel.com, andrew+netdev@lunn.ch,
davem@davemloft.net, doruk@0sec.ai, edumazet@google.com,
grzegorz.nitka@intel.com, horms@kernel.org,
marcin.szycik@linux.intel.com,
michal.swiatkowski@linux.intel.com, netdev@vger.kernel.org,
pabeni@redhat.com, przemyslaw.kitszel@intel.com,
stable@vger.kernel.org
Subject: Re: [PATCH net 01/10] iavf: return EBUSY if reset in progress or not ready during MAC change
Date: Wed, 12 Aug 2026 08:56:50 +0200 [thread overview]
Message-ID: <20260812065650.10326-1-jtornosm@redhat.com> (raw)
In-Reply-To: <20260806172032.2935407-1-kuba@kernel.org>
All the comments below fall into pre-existing issues, concerns already
addressed in previous versions, out-of-scope items, or extreme edge
cases. No code changes are considered necessary for a new version.
Details for each comment:
> [Severity: Low]
> Is the placement of the new gate ahead of is_valid_ether_addr()
> intentional?
>
> With this ordering, a request carrying an address that can never be
> accepted (all-zero, multicast, other non-unicast MAC) now reports -EBUSY
> rather than -EADDRNOTAVAIL whenever iavf_is_reset_in_progress(adapter) is
> true or adapter->state < __IAVF_DOWN.
>
> The core does not validate the address itself, so the driver check is the
> only one on the rtnetlink/ioctl/sysfs paths:
>
> net/core/dev.c:netif_set_mac_address() {
> if (!ops->ndo_set_mac_address)
> return -EOPNOTSUPP;
> if (ss->ss_family != dev->type)
> return -EINVAL;
> if (!netif_device_present(dev))
> return -ENODEV;
> ...
> err = ops->ndo_set_mac_address(dev, ss);
> }
>
> Since -EBUSY advertises a transient condition, callers that retry on EBUSY
> would loop on input that can never succeed. Would moving the state gate
> below the is_valid_ether_addr() check work equally well for the stated
> goal?
>
> The ordering is still present at the end of the series, and the commit
> message does not mention the change in returned errno for invalid
> addresses. Could that be noted, or the checks reordered?
The scenario requires passing an invalid MAC address (multicast, all-zero)
while the VF is resetting. -EBUSY is still a correct response, the VF
cannot perform any operation during reset regardless of the address.
If a caller retries on -EBUSY, the reset completes quickly (milliseconds
to seconds) and the next attempt returns -EADDRNOTAVAIL as expected.
This is a transient errno difference, not a functional issue.
next prev parent reply other threads:[~2026-08-12 6:57 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-04 22:21 [PATCH net 00/10][pull request] Intel Wired LAN Driver Updates 2026-08-04 (iavf, i40e, ice, igc) Tony Nguyen
2026-08-04 22:21 ` [PATCH net 01/10] iavf: return EBUSY if reset in progress or not ready during MAC change Tony Nguyen
2026-08-06 17:20 ` Jakub Kicinski
2026-08-12 6:56 ` Jose Ignacio Tornos Martinez [this message]
2026-08-04 22:21 ` [PATCH net 02/10] i40e: skip unnecessary VF reset when setting trust Tony Nguyen
2026-08-06 17:20 ` Jakub Kicinski
2026-08-12 6:59 ` Jose Ignacio Tornos Martinez
2026-08-04 22:21 ` [PATCH net 03/10] iavf: send MAC change request synchronously Tony Nguyen
2026-08-06 17:20 ` Jakub Kicinski
2026-08-12 7:02 ` Jose Ignacio Tornos Martinez
2026-08-04 22:21 ` [PATCH net 04/10] ice: skip unnecessary VF reset when setting trust Tony Nguyen
2026-08-06 17:20 ` Jakub Kicinski
2026-08-12 7:05 ` Jose Ignacio Tornos Martinez
2026-08-04 22:21 ` [PATCH net 05/10] ice: move ice_vsi_realloc_stat_arrays() up Tony Nguyen
2026-08-04 22:21 ` [PATCH net 06/10] ice: fix stats array overflow via proper realloc Tony Nguyen
2026-08-06 17:20 ` Jakub Kicinski
2026-08-04 22:22 ` [PATCH net 07/10] ice: eswitch: fix use-after-free of metadata_dst in repr release Tony Nguyen
2026-08-06 17:20 ` Jakub Kicinski
2026-08-04 22:22 ` [PATCH net 08/10] i40e: fix memcmp of pointer in i40e_hw_set_dcb_config() Tony Nguyen
2026-08-06 17:20 ` Jakub Kicinski
2026-08-04 22:22 ` [PATCH net 09/10] i40e: fix netdev leak in i40e_vsi_setup() error paths Tony Nguyen
2026-08-06 17:20 ` Jakub Kicinski
2026-08-04 22:22 ` [PATCH net 10/10] igc: fix netdev not re-attached after resume if interface is down Tony Nguyen
2026-08-06 17:19 ` [PATCH net 00/10][pull request] Intel Wired LAN Driver Updates 2026-08-04 (iavf, i40e, ice, igc) Jakub Kicinski
2026-08-06 17:30 ` patchwork-bot+netdevbpf
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=20260812065650.10326-1-jtornosm@redhat.com \
--to=jtornosm@redhat.com \
--cc=aleksandr.loktionov@intel.com \
--cc=andrew+netdev@lunn.ch \
--cc=anthony.l.nguyen@intel.com \
--cc=davem@davemloft.net \
--cc=doruk@0sec.ai \
--cc=edumazet@google.com \
--cc=grzegorz.nitka@intel.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=marcin.szycik@linux.intel.com \
--cc=michal.swiatkowski@linux.intel.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=przemyslaw.kitszel@intel.com \
--cc=stable@vger.kernel.org \
/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