Re: [PATCH net v2 1/5] ionic: fix devcmds racing the BAR unmap on PCI reset
From: netdev-bot+sashiko
Date: Sat Dec 05 2026 - 18:06:17 EST
Thank you for your contribution! Sashiko AI review found more severe
issue(s) in other patches of this series. This mail is only an FYI, in case
you want to address the nit picks below when you respin.
Low priority / nit picks for your consideration:
- [Low] ionic: commit message omits ionic_vf_start() fix and misstates
callers
--
> diff --git a/drivers/net/ethernet/pensando/ionic/ionic_dev.c b/drivers/net/ethernet/pensando/ionic/ionic_dev.c
> --- a/drivers/net/ethernet/pensando/ionic/ionic_dev.c
> +++ b/drivers/net/ethernet/pensando/ionic/ionic_dev.c
> @@ -811,8 +813,10 @@ void ionic_vf_start(struct ionic *ionic)
> if (!(ionic->ident.dev.capabilities & cpu_to_le64(IONIC_DEV_CAP_VF_CTRL)))
> return;
>
> + mutex_lock(&ionic->dev_cmd_lock);
> ionic_dev_cmd_go(&ionic->idev, &cmd);
> ionic_dev_cmd_wait(ionic, DEVCMD_TIMEOUT);
> + mutex_unlock(&ionic->dev_cmd_lock);
> }
>
> /* LIF commands */
[Severity: Low]
The ionic_vf_start() hunk does more than apply the new rule. Before
this patch, ionic_vf_start() issued IONIC_CMD_VF_CTRL through
ionic_dev_cmd_go() and ionic_dev_cmd_wait() without dev_cmd_lock.
That let it interleave with any other devcmd, whether or not a reset
was in progress. This is a separate fix, and the commit message does
not mention it. Could you call it out in the changelog? Is the
existing Fixes: list right for it, or does it need its own tag?
The changelog also says the identify and port setup devcmds "run only
from probe and recovery". That is not quite accurate:
ionic_port_identify() is also called from ionic_link_status_check()
on link-up.
If I read it right, that path is still safe. It takes dev_cmd_lock,
and ionic_dev_teardown() destroys ionic->wq before ionic_clear_pci()
runs. Please have the changelog give that reasoning instead of
claiming these devcmds never run outside probe and recovery.
--
Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261204-b4-pr60-v2-0-9e0b5408a68e%40amd.com