Patch "ice: avoid IRQ collision to fix init failure on ACPI S3 resume" has been added to the 6.6-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    ice: avoid IRQ collision to fix init failure on ACPI S3 resume

to the 6.6-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     ice-avoid-irq-collision-to-fix-init-failure-on-acpi-.patch
and it can be found in the queue-6.6 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit a744d13ef6d3c7c68e16265e704821d63d3ecf10
Author: En-Wei Wu <en-wei.wu@xxxxxxxxxxxxx>
Date:   Thu May 30 22:21:31 2024 +0800

    ice: avoid IRQ collision to fix init failure on ACPI S3 resume
    
    [ Upstream commit bc69ad74867dba1377abe14356c94a946d9837a3 ]
    
    A bug in https://bugzilla.kernel.org/show_bug.cgi?id=218906 describes
    that irdma would break and report hardware initialization failed after
    suspend/resume with Intel E810 NIC (tested on 6.9.0-rc5).
    
    The problem is caused due to the collision between the irq numbers
    requested in irdma and the irq numbers requested in other drivers
    after suspend/resume.
    
    The irq numbers used by irdma are derived from ice's ice_pf->msix_entries
    which stores mappings between MSI-X index and Linux interrupt number.
    It's supposed to be cleaned up when suspend and rebuilt in resume but
    it's not, causing irdma using the old irq numbers stored in the old
    ice_pf->msix_entries to request_irq() when resume. And eventually
    collide with other drivers.
    
    This patch fixes this problem. On suspend, we call ice_deinit_rdma() to
    clean up the ice_pf->msix_entries (and free the MSI-X vectors used by
    irdma if we've dynamically allocated them). On resume, we call
    ice_init_rdma() to rebuild the ice_pf->msix_entries (and allocate the
    MSI-X vectors if we would like to dynamically allocate them).
    
    Fixes: f9f5301e7e2d ("ice: Register auxiliary device to provide RDMA")
    Tested-by: Cyrus Lien <cyrus.lien@xxxxxxxxxxxxx>
    Signed-off-by: En-Wei Wu <en-wei.wu@xxxxxxxxxxxxx>
    Reviewed-by: Wojciech Drewek <wojciech.drewek@xxxxxxxxx>
    Tested-by: Pucha Himasekhar Reddy <himasekharx.reddy.pucha@xxxxxxxxx> (A Contingent worker at Intel)
    Signed-off-by: Tony Nguyen <anthony.l.nguyen@xxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/net/ethernet/intel/ice/ice_main.c b/drivers/net/ethernet/intel/ice/ice_main.c
index 5d71febdcd4dd..26ef8aec4cfdf 100644
--- a/drivers/net/ethernet/intel/ice/ice_main.c
+++ b/drivers/net/ethernet/intel/ice/ice_main.c
@@ -5348,7 +5348,7 @@ static int __maybe_unused ice_suspend(struct device *dev)
 	 */
 	disabled = ice_service_task_stop(pf);
 
-	ice_unplug_aux_dev(pf);
+	ice_deinit_rdma(pf);
 
 	/* Already suspended?, then there is nothing to do */
 	if (test_and_set_bit(ICE_SUSPENDED, pf->state)) {
@@ -5428,6 +5428,11 @@ static int __maybe_unused ice_resume(struct device *dev)
 	if (ret)
 		dev_err(dev, "Cannot restore interrupt scheme: %d\n", ret);
 
+	ret = ice_init_rdma(pf);
+	if (ret)
+		dev_err(dev, "Reinitialize RDMA during resume failed: %d\n",
+			ret);
+
 	clear_bit(ICE_DOWN, pf->state);
 	/* Now perform PF reset and rebuild */
 	reset_type = ICE_RESET_PFR;




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux