RE: [PATCH v2 net 8/9] net: enetc: fix initialization order to prevent use of uninitialized resources

From: Wei Fang

Date: Tue May 19 2026 - 21:43:00 EST


> > @@ -151,14 +149,17 @@ void enetc_msg_psi_free(struct enetc_pf *pf)
> > struct enetc_si *si = pf->si;
> > int i;
> >
> > + /* disable MR interrupts */
> > + enetc_msg_disable_mr_int(&si->hw);
> > +
> > + /* de-register message passing interrupt handler */
> > + free_irq(pci_irq_vector(si->pdev, ENETC_SI_INT_IDX), si);
> > +
> > cancel_work_sync(&pf->msg_task);
> >
> > - /* disable MR interrupts */
> > + /* MR interrupts may be re-enabled by workqueue */
> > enetc_msg_disable_mr_int(&si->hw);
> >
> > for (i = 0; i < pf->num_vfs; i++)
> > enetc_msg_free_mbx(si, i);
> > -
> > - /* de-register message passing interrupt handler */
> > - free_irq(pci_irq_vector(si->pdev, ENETC_SI_INT_IDX), si);
>
> Code looks good to me but a nit: would be good if the change here in
> enetc_msg_psi_free() is also called out in the commit message.

Thanks, I will update the commit message.

--
pw-bot: cr