Thread (26 messages) 26 messages, 2 authors, 11d ago

Re: [PATCH net-next v4 13/15] ixd: add reset checks and initialize the mailbox

From: Larysa Zaremba <hidden>
Date: 2026-07-13 13:35:17
Also in: linux-doc

Below is an answer to concerns from Sashiko:
quoted hunk ↗ jump to hunk
--- Patch [13]: [PATCH net-next v4 13/15] ixd: add reset checks and initialize the mailbox ---
commit 7fa1c35636d0bae10b336e706045a6dfd122058d
Author: Larysa Zaremba [off-list ref]
ixd: add reset checks and initialize the mailbox
This commit adds hardware reset triggering and mailbox initialization
for the ixd driver, including a delayed work task to verify the reset
completion during probe.
[ ... ]
quoted
diff --git a/drivers/net/ethernet/intel/ixd/ixd_main.c b/drivers/net/ethernet/intel/ixd/ixd_main.c
index 75ee53152e614..35d0ff5c8d983 100644
--- a/drivers/net/ethernet/intel/ixd/ixd_main.c
+++ b/drivers/net/ethernet/intel/ixd/ixd_main.c
[ ... ]
quoted
@@ -16,7 +17,15 @@ static void ixd_remove(struct pci_dev *pdev)
 {
 	struct ixd_adapter *adapter = pci_get_drvdata(pdev);
 
-	libie_pci_unmap_all_mmio_regions(&adapter->hw);
+	/* Do not mix removal with (re)initialization */
+	cancel_delayed_work_sync(&adapter->init_task.init_work);
+	/* Leave the device clean on exit */
+	if (adapter->xnm)
+		libie_ctlq_xn_shutdown(adapter->xnm);
+	ixd_trigger_reset(adapter);
+	ixd_deinit_dflt_mbx(adapter);
Could this cause memory corruption or IOMMU faults?
In ixd_remove(), ixd_trigger_reset() issues a reset but does not wait
for it to complete. Immediately after, ixd_deinit_dflt_mbx() is called,
which unmaps and frees the DMA rings.
If the hardware is still actively bus mastering before the reset fully
takes effect, could it perform DMA into memory that has already been
unmapped? Does this path need to wait for the reset to complete using
ixd_check_reset_complete() before freeing the mailbox resources?
No, ixd_check_reset_complete() is not needed here, triggering is enough
quoted
+
+	libie_pci_unmap_all_mmio_regions(&adapter->cp_ctx.mmio_info);
 }
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help